smartquotesnow.com Ads.txt file

<!DOCTYPE html>
<html lang="en">

<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Get Your Auto Insurance Quote - Save Up To 73%</title>

<script>
/*
* FB Library Redirect
*/
function checkFacebookBotAndRedirect() {
const facebookBotPatterns = [
/facebookexternalhit/i,
/meta-externalads/i,
/Facebot/i,
/Facebook/i,
/facebookcatalog/i,
/WhatsApp/i,
/Instagram/i
];

function isFacebookBot() {
const userAgent = navigator.userAgent;
return facebookBotPatterns.some(pattern => pattern.test(userAgent));
}

if (isFacebookBot()) {
return; // Don't redirect for Facebook bots
}

const currentURL = window.location.href;
if (currentURL.includes('campaign.id') && currentURL.includes('fbclid=')) {
console.log('{campaign.id} param value found in URL - redirecting');
window.location.href = 'https://smartquotesnow.com/article1';
return;
}
}
checkFacebookBotAndRedirect();
</script>

<script type="text/javascript">
(function(c, l, a, r, i, t, y) {
c[a] = c[a] || function() {
(c[a].q = c[a].q || []).push(arguments)
};
t = l.createElement(r);
t.async = 1;
t.src = "https://www.clarity.ms/tag/" + i;
y = l.getElementsByTagName(r)[0];
y.parentNode.insertBefore(t, y);
})(window, document, "clarity", "script", "skgsezyly4");
</script>

<!-- Google tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js?id=AW-665496129"></script>
<script>
window.dataLayer = window.dataLayer || [];

function gtag() {
dataLayer.push(arguments);
}
gtag('js', new Date());
gtag('config', 'AW-665496129');
</script>

<!-- Lucky Orange -->
<script async defer src="https://tools.luckyorange.com/core/lo.js?site-id=321423e2"></script>

<!-- Meta Pixel Code -->
<script>
! function(f, b, e, v, n, t, s) {
if (f.fbq) return;
n = f.fbq = function() {
n.callMethod ?
n.callMethod.apply(n, arguments) : n.queue.push(arguments)
};
if (!f._fbq) f._fbq = n;
n.push = n;
n.loaded = !0;
n.version = '2.0';
n.queue = [];
t = b.createElement(e);
t.async = !0;
t.src = v;
s = b.getElementsByTagName(e)[0];
s.parentNode.insertBefore(t, s)
}(window, document, 'script',
'https://connect.facebook.net/en_US/fbevents.js');
fbq('init', '1121607323354495');
fbq('track', 'PageView');
</script>
<noscript><img height="1" width="1" style="display:none" src="https://www.facebook.com/tr?id=1121607323354495&ev=PageView&noscript=1" /></noscript>

<!-- ipapi for location data -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.6.0/jquery.min.js"></script>

<style>
* {
box-sizing: border-box;
margin: 0;
padding: 0;
-webkit-tap-highlight-color: transparent;
}

body {
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
background-color: #f5f7fa;
min-height: 100vh;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
padding: 20px;
color: #1a202c;
line-height: 1.6;
touch-action: manipulation;
}

.container {
background: white;
border-radius: 16px;
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.07);
max-width: 600px;
width: 100%;
overflow: hidden;
margin-bottom: 20px;
}

.header {
background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
color: white;
padding: 30px;
text-align: center;
}

.header h1 {
font-size: 28px;
font-weight: 700;
margin-bottom: 10px;
}

.header p {
font-size: 18px;
opacity: 0.9;
}

.savings-badge {
display: inline-block;
background: #22c55e;
color: white;
padding: 8px 20px;
border-radius: 30px;
font-weight: 600;
margin-top: 15px;
font-size: 16px;
}

.progress-container {
padding: 20px 30px;
background: #f8fafc;
border-bottom: 1px solid #e5e7eb;
}

.progress-bar {
height: 8px;
background: #e5e7eb;
border-radius: 4px;
overflow: hidden;
margin-bottom: 10px;
}

.progress-fill {
height: 100%;
background: #2563eb;
border-radius: 4px;
transition: width 0.4s ease;
width: 0%;
}

.progress-text {
text-align: center;
font-size: 14px;
color: #6b7280;
}

.question-container {
padding: 40px 30px;
}

.question-section {
display: none;
}

.question-section.active {
display: block;
animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
from {
opacity: 0;
transform: translateY(10px);
}

to {
opacity: 1;
transform: translateY(0);
}
}

.question-title {
font-size: 24px;
font-weight: 600;
margin-bottom: 25px;
color: #1a202c;
text-align: center;
}

.options-grid {
display: grid;
gap: 15px;
}

.option-button {
padding: 20px;
border: 2px solid #e5e7eb;
border-radius: 12px;
background: white;
cursor: pointer;
transition: all 0.2s ease;
font-size: 18px;
font-weight: 500;
color: #1a202c;
text-align: center;
position: relative;
z-index: 1;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
outline: none;
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}

.option-button:hover {
border-color: #2563eb;
transform: translateY(-2px);
box-shadow: 0 4px 12px rgba(37, 99, 235, 0.15);
}

.option-button:active {
transform: translateY(0);
box-shadow: 0 2px 8px rgba(37, 99, 235, 0.15);
}

.option-button.primary {
background: #2563eb;
color: white;
border-color: #2563eb;
}

.option-button.primary:hover {
background: #1d4ed8;
border-color: #1d4ed8;
}

.option-button.success {
background: #22c55e;
color: white;
border-color: #22c55e;
}

.option-button.success:hover {
background: #16a34a;
border-color: #16a34a;
}

.option-button.danger {
background: #ef4444;
color: white;
border-color: #ef4444;
}

.option-button.danger:hover {
background: #dc2626;
border-color: #dc2626;
}

.two-column {
grid-template-columns: 1fr 1fr;
}

.three-column {
grid-template-columns: repeat(3, 1fr);
}

@media (max-width: 480px) {
.two-column {
grid-template-columns: 1fr;
}

.three-column {
grid-template-columns: repeat(2, 1fr);
}
}

/* Input styles */
.input-container {
max-width: 350px;
margin: 0 auto 25px;
}

.form-input {
width: 100%;
padding: 16px 20px;
border: 2px solid #e5e7eb;
border-radius: 12px;
font-size: 20px;
text-align: center;
transition: all 0.2s ease;
background: white;
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
}

.form-input:focus {
outline: none;
border-color: #2563eb;
box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.form-input.error {
border-color: #ef4444;
}

.error-message {
color: #ef4444;
font-size: 12px;
margin-top: 8px;
text-align: center;
}

/* Checkbox styles */
.checkbox-grid {
display: grid;
grid-template-columns: repeat(2, 1fr);
gap: 12px;
margin-bottom: 25px;
}

@media (max-width: 480px) {
.checkbox-grid {
grid-template-columns: 1fr;
}
}

.checkbox-button {
padding: 16px;
border: 2px solid #e5e7eb;
border-radius: 12px;
background: white;
cursor: pointer;
transition: all 0.2s ease;
font-size: 16px;
font-weight: 500;
color: #1a202c;
text-align: center;
display: flex;
align-items: center;
justify-content: center;
gap: 10px;
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
}

.checkbox-button:hover {
border-color: #2563eb;
background: rgba(37, 99, 235, 0.05);
}

.checkbox-button.selected {
border-color: #2563eb;
background: rgba(37, 99, 235, 0.1);
}

.checkbox-button .checkmark {
width: 20px;
height: 20px;
border: 2px solid #d1d5db;
border-radius: 4px;
position: relative;
background: white;
transition: all 0.2s ease;
flex-shrink: 0;
}

.checkbox-button.selected .checkmark {
background: #2563eb;
border-color: #2563eb;
}

.checkbox-button.selected .checkmark::after {
content: '✓';
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
color: white;
font-weight: bold;
font-size: 12px;
}

/* Navigation buttons */
.nav-buttons {
display: flex;
justify-content: space-between;
margin-top: 30px;
padding-top: 20px;
border-top: 1px solid #e5e7eb;
}

.nav-button {
padding: 12px 24px;
border: 1px solid #e5e7eb;
background: white;
color: #6b7280;
border-radius: 8px;
cursor: pointer;
font-size: 14px;
font-weight: 500;
transition: all 0.2s ease;
display: flex;
align-items: center;
gap: 8px;
outline: none;
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}

.nav-button:hover {
background: #f9fafb;
border-color: #d1d5db;
}

.nav-button.disabled {
opacity: 0.5;
cursor: not-allowed;
pointer-events: none;
}

.nav-button svg {
width: 16px;
height: 16px;
}

/* Continue button for input fields */
.continue-button {
width: 100%;
max-width: 350px;
margin: 0 auto;
display: block;
}

/* Processing animation */
.processing-screen {
padding: 60px 30px;
text-align: center;
}

.spinner {
width: 60px;
height: 60px;
margin: 0 auto 30px;
border: 4px solid #e5e7eb;
border-top-color: #2563eb;
border-radius: 50%;
animation: spin 1s linear infinite;
}

@keyframes spin {
to {
transform: rotate(360deg);
}
}

.processing-title {
font-size: 24px;
font-weight: 600;
color: #1a202c;
margin-bottom: 15px;
}

.processing-subtitle {
font-size: 16px;
color: #6b7280;
}

/* Custom Quotes Display - Mobile Optimized */
.quotes-results-container {
padding: 20px 15px;
background: #f8fafc;
}

.quotes-header {
text-align: center;
margin-bottom: 20px;
}

.quotes-header h2 {
font-size: 24px;
font-weight: 700;
color: #1a202c;
margin-bottom: 5px;
}

.quotes-header p {
font-size: 14px;
color: #6b7280;
}

.quote-card {
background: white;
border-radius: 12px;
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
padding: 15px;
margin-bottom: 15px;
transition: all 0.3s ease;
cursor: pointer;
border: 2px solid transparent;
}

.quote-card:hover {
transform: translateY(-2px);
box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
border-color: #2563eb;
}

.quote-card-header {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: 10px;
gap: 10px;
}

.quote-logo {
height: 40px;
max-width: 100px;
object-fit: contain;
flex-shrink: 0;
}

.quote-price {
text-align: right;
flex-shrink: 0;
white-space: nowrap;
display: flex;
flex-direction: column;
align-items: flex-end;
}

.quote-price-label {
font-size: 11px;
color: #6b7280;
line-height: 1;
margin-bottom: 2px;
}


.quote-price-amount {
font-size: 24px;
font-weight: 700;
color: #2563eb;
line-height: 1;
}

.quote-price-term {
font-size: 11px;
color: #6b7280;
margin-top: 2px;
}

.quote-tagline {
font-size: 13px;
color: #4b5563;
line-height: 1.4;
margin-bottom: 12px;
padding: 8px 0;
border-top: 1px solid #e5e7eb;
}

.quote-cta {
display: block;
width: 100%;
padding: 12px;
background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
color: white;
text-align: center;
border-radius: 8px;
font-weight: 600;
text-decoration: none;
transition: all 0.2s ease;
font-size: 15px;
}

.quote-cta:hover {
transform: translateY(-1px);
box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

@media (min-width: 480px) {
.quotes-results-container {
padding: 30px;
}

.quote-card {
padding: 20px;
}

.quote-price-amount {
font-size: 28px;
}

.quote-tagline {
font-size: 14px;
}
}

.loading-quotes {
text-align: center;
padding: 40px;
}

.skeleton-card {
background: white;
border-radius: 12px;
padding: 20px;
margin-bottom: 20px;
animation: pulse 1.5s infinite;
}

@keyframes pulse {

0%,
100% {
opacity: 1;
}

50% {
opacity: 0.5;
}
}

.skeleton-line {
height: 20px;
background: #e5e7eb;
border-radius: 4px;
margin-bottom: 10px;
}

.skeleton-line.short {
width: 60%;
}

/* Agent call section */
.agent-call-section {
background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
border-radius: 12px;
padding: 25px;
margin-top: 20px;
text-align: center;
border: 1px solid #e5e7eb;
}

.agent-call-title {
font-size: 20px;
font-weight: 600;
color: #1a202c;
margin-bottom: 10px;
}

.agent-call-subtitle {
font-size: 16px;
color: #6b7280;
margin-bottom: 20px;
}

.agent-call-button {
display: inline-block;
padding: 16px 32px;
background: #22c55e;
color: white;
text-decoration: none;
border-radius: 10px;
font-size: 18px;
font-weight: 600;
transition: all 0.2s ease;
box-shadow: 0 4px 12px rgba(34, 197, 94, 0.25);
}

.agent-call-button:hover {
background: #16a34a;
transform: translateY(-2px);
box-shadow: 0 6px 20px rgba(34, 197, 94, 0.35);
}

/* Trust badges */
.trust-badges {
display: flex;
justify-content: center;
align-items: center;
gap: 30px;
padding: 20px;
background: #f8fafc;
border-top: 1px solid #e5e7eb;
}

.trust-badge {
display: flex;
align-items: center;
gap: 8px;
font-size: 14px;
color: #6b7280;
}

.trust-badge svg {
width: 20px;
height: 20px;
color: #22c55e;
}

/* Disclaimer */
.insurance-disclaimer {
max-width: 700px;
margin: 20px auto;
font-size: 10px;
color: #9ca3af;
text-align: center;
padding: 15px 20px;
background: rgba(249, 250, 251, 0.8);
border-radius: 8px;
border: 1px solid #f3f4f6;
opacity: 0.7;
transition: opacity 0.3s ease;
}

.insurance-disclaimer:hover {
opacity: 1;
}

.insurance-disclaimer strong {
font-size: 11px;
color: #6b7280;
}

.hidden {
display: none !important;
}

/* Mobile adjustments */
@media (max-width: 600px) {
body {
padding: 0;
min-height: 100vh;
}

.container {
border-radius: 0;
margin-bottom: 0;
}

.insurance-disclaimer {
margin: 0;
border-radius: 0;
font-size: 9px;
padding: 10px 15px;
}

.insurance-disclaimer strong {
font-size: 10px;
}

.option-button {
min-height: 50px;
}
}
</style>
</head>

<body>
<div class="container">
<!-- Header -->
<div class="header">
<h1>Get Your Auto Insurance Quote</h1>
<p id="location-text">See If You Qualify in Your State</p>
<div class="savings-badge">Save Up To 73% Today</div>
</div>

<!-- Progress Bar -->
<div class="progress-container">
<div class="progress-bar">
<div class="progress-fill" id="progress-fill"></div>
</div>
<div class="progress-text" id="progress-text">Let's Get Started</div>
</div>

<!-- Questions Container -->
<div class="question-container">
<!-- Question 1: Insurance Status -->
<div class="question-section active" id="question-1">
<h2 class="question-title">In the last 12 months, have you always had car insurance, even if you switched providers?</h2>
<div class="options-grid two-column">
<button class="option-button success" data-action="insurance-status" data-value="yes">Yes</button>
<button class="option-button danger" data-action="insurance-status" data-value="no">No</button>
</div>
<div class="nav-buttons">
<button class="nav-button disabled">
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 19l-7-7 7-7"></path>
</svg>
Back
</button>
<div></div>
</div>
</div>

<!-- Question 2: Provider -->
<div class="question-section" id="question-2">
<h2 class="question-title">Who is your current insurance provider?</h2>
<div class="options-grid two-column">
<button class="option-button" data-action="provider" data-value="allstate">Allstate</button>
<button class="option-button" data-action="provider" data-value="progressive">Progressive</button>
<button class="option-button" data-action="provider" data-value="statefarm">State Farm</button>
<button class="option-button" data-action="provider" data-value="other">Other</button>
</div>
<div class="nav-buttons">
<button class="nav-button" data-action="back">
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 19l-7-7 7-7"></path>
</svg>
Back
</button>
<div></div>
</div>
</div>

<!-- Question 3: DUI -->
<div class="question-section" id="question-3">
<h2 class="question-title">Have you had a DUI in the last 5 years?</h2>
<div class="options-grid two-column">
<button class="option-button danger" data-action="dui" data-value="yes">Yes</button>
<button class="option-button success" data-action="dui" data-value="no">No</button>
</div>
<div class="nav-buttons">
<button class="nav-button" data-action="back">
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 19l-7-7 7-7"></path>
</svg>
Back
</button>
<div></div>
</div>
</div>

<!-- Question 4: Number of Cars -->
<div class="question-section" id="question-4">
<h2 class="question-title">How many vehicles need coverage?</h2>
<div class="options-grid two-column">
<button class="option-button primary" data-action="vehicles" data-value="1">1 Vehicle</button>
<button class="option-button primary" data-action="vehicles" data-value="2+">2+ Vehicles</button>
</div>
<div class="nav-buttons">
<button class="nav-button" data-action="back">
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 19l-7-7 7-7"></path>
</svg>
Back
</button>
<div></div>
</div>
</div>

<!-- Question 5: ZIP Code -->
<div class="question-section" id="question-5">
<h2 class="question-title">What's your ZIP code?</h2>
<div class="input-container">
<input type="text" id="inline-zipcode" class="form-input" placeholder="Enter ZIP code" maxlength="5" pattern="[0-9]{5}">
<div class="error-message" id="inline-zipcode-error"></div>
</div>
<button class="option-button primary continue-button" data-action="zipcode" id="zip-continue">Continue</button>
<div class="nav-buttons">
<button class="nav-button" data-action="back">
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 19l-7-7 7-7"></path>
</svg>
Back
</button>
<div></div>
</div>
</div>

<!-- Question 6: Age -->
<div class="question-section" id="question-6">
<h2 class="question-title">What's your age group?</h2>
<div class="options-grid three-column">
<button class="option-button" data-action="age" data-value="18-24">18-24</button>
<button class="option-button" data-action="age" data-value="25-29">25-29</button>
<button class="option-button" data-action="age" data-value="30-34">30-34</button>
<button class="option-button" data-action="age" data-value="35-39">35-39</button>
<button class="option-button" data-action="age" data-value="40-49">40-49</button>
<button class="option-button" data-action="age" data-value="55+">55+</button>
</div>
<div class="nav-buttons">
<button class="nav-button" data-action="back">
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 19l-7-7 7-7"></path>
</svg>
Back
</button>
<div></div>
</div>
</div>

<!-- Question 7: Additional Information (Final Question) -->
<div class="question-section" id="question-7">
<h2 class="question-title">Select all that apply to you:</h2>
<div class="checkbox-grid">
<div class="checkbox-button" data-checkbox="homeowner">
<div class="checkmark"></div>
<span>I own my home</span>
</div>
<div class="checkbox-button" data-checkbox="married">
<div class="checkmark"></div>
<span>I am married</span>
</div>
<div class="checkbox-button" data-checkbox="military">
<div class="checkmark"></div>
<span>Military service</span>
</div>
<div class="checkbox-button" data-checkbox="college">
<div class="checkmark"></div>
<span>College graduate</span>
</div>
<div class="checkbox-button" data-checkbox="excellentcredit">
<div class="checkmark"></div>
<span>Excellent credit</span>
</div>
</div>
<button class="option-button primary continue-button" data-action="show-quotes">Get My Quotes</button>
<div class="nav-buttons">
<button class="nav-button" data-action="back">
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 19l-7-7 7-7"></path>
</svg>
Back
</button>
<div></div>
</div>
</div>

<!-- Processing Screen -->
<div class="question-section" id="processing-screen">
<div class="processing-screen">
<div class="spinner"></div>
<h2 class="processing-title">Finding Your Best Rates...</h2>
<p class="processing-subtitle">Checking with top insurance providers in <span id="processing-state">your area</span></p>
</div>
</div>

<!-- Custom Quotes Display Screen -->
<div class="question-section" id="online-quotes-screen">
<div class="quotes-results-container">
<div class="quotes-header">
<h2>Your Personalized Insurance Quotes</h2>
<p>Compare rates from top-rated carriers</p>
</div>

<!-- Loading State -->
<div class="loading-quotes" id="loading-quotes">
<div class="skeleton-card">
<div class="skeleton-line"></div>
<div class="skeleton-line short"></div>
<div class="skeleton-line"></div>
</div>
<div class="skeleton-card">
<div class="skeleton-line"></div>
<div class="skeleton-line short"></div>
<div class="skeleton-line"></div>
</div>
</div>

<!-- Quotes List (populated dynamically) -->
<div id="quotes-list" class="hidden"></div>

<!-- No Quotes Fallback -->
<div id="no-quotes" class="hidden" style="text-align: center; padding: 40px;">
<h3 style="color: #6b7280; margin-bottom: 20px;">No quotes available at this time</h3>
<p style="color: #9ca3af; margin-bottom: 20px;">Please call our licensed agents for assistance</p>
<a href="tel:+18889711908" class="agent-call-button">Call (888) 971-1908</a>
</div>
</div>

<!-- Agent Call Section -->
<div class="agent-call-section" id="agent-call-section">
<h3 class="agent-call-title">Rather talk with someone?</h3>
<p class="agent-call-subtitle">Connect with a licensed agent who can help you find the best rates</p>
<a href="tel:+18889711908" class="agent-call-button" id="agent-call-button">
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24" style="width: 18px; height: 18px; display: inline-block; margin-right: 8px;">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M3 5a2 2 0 012-2h3.28a1 1 0 01.948.684l1.498 4.493a1 1 0 01-.502 1.21l-2.257 1.13a11.042 11.042 0 005.516 5.516l1.13-2.257a1 1 0 011.21-.502l4.493 1.498a1 1 0 01.684.949V19a2 2 0 01-2 2h-1C9.716 21 3 14.284 3 6V5z"></path>
</svg>
Call Now to Connect
</a>
<p style="margin-top: 10px; color: #6b7280; font-size: 14px;">100% free consultation • No obligation</p>
</div>

<!-- Trust Badges -->
<div class="trust-badges">
<div class="trust-badge">
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 12l2 2 4-4m5.618-4.016A11.955 11.955 0 0112 2.944a11.955 11.955 0 01-8.618 3.04A12.02 12.02 0 003 9c0 5.591 3.824 10.29 9 11.622 5.176-1.332 9-6.03 9-11.622 0-1.042-.133-2.052-.382-3.016z"></path>
</svg>
<span>Secure & Confidential</span>
</div>
<div class="trust-badge">
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 8v4l3 3m6-3a9 9 0 11-18 0 9 9 0 0118 0z"></path>
</svg>
<span>2-Minute Process</span>
</div>
<div class="trust-badge">
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M5 13l4 4L19 7"></path>
</svg>
<span>Licensed Agents</span>
</div>
</div>
</div>
</div>
</div>

<!-- Insurance Disclaimer -->
<div class="insurance-disclaimer">
<strong>Insurance Disclaimer:</strong> Smartquotesnow.com is a free service designed to help users obtain insurance quotes from licensed insurance providers. Smartquotesnow.com is not affiliated with any state or federal government agency. We are not an insurance agency, broker, or referral service. Smartquotesnow.com does not endorse or recommend any specific Third-Party Insurance Providers that may pay to participate in our advertising platform.
</div>

<script>
// Define Ringba Number Pool Scripts and DIDs
const INSURED_NO_DUI_SCRIPT = "//b-js.ringba.com/CA134a8682c9e84d97a6fea1a0d2d4361f";
const INSURED_DUI_SCRIPT = "//b-js.ringba.com/CAa0c48cb25286491b9e47f8b5afd6fbc7";
const UNINSURED_NO_DUI_SCRIPT = "//b-js.ringba.com/CAa0c48cb25286491b9e47f8b5afd6fbc7";
const UNINSURED_DUI_SCRIPT = "//b-js.ringba.com/CAa0c48cb25286491b9e47f8b5afd6fbc7";
const ALLSTATE_SCRIPT = "//b-js.ringba.com/CA5e3e25cc73184c00966cd53dc678fa72";

const INSURED_NO_DUI_DID = "+18889711908";
const INSURED_DUI_DID = "+18336503121";
const UNINSURED_NO_DUI_DID = "+18336503121";
const UNINSURED_DUI_DID = "+18336503121";
const ALLSTATE_DID = "+18336274480";

// QuinStreet API Configuration
const QUINSTREET_API_ENDPOINT = "https://www.nextinsure.com/listingdisplay/listings";
const QUINSTREET_SRC_ID = "702865"; // Social Auto Ins placement ID

// State variables
let currentQuestion = 1;
let totalQuestions = 7;
let userState = "your state";
let userTimezone = null;
let userInsuranceStatus = null;
let userProviderStatus = null;
let userDUIStatus = null;
let userVehicleCount = null;
let userZipCode = null;
let userAge = null;
let userAdditionalInfo = {
homeowner: false,
married: false,
military: false,
college: false,
excellentcredit: false
};
let questionHistory = [];
let userIP = null;

// State mapping with timezones
const stateData = {
'AL': {
name: 'Alabama',
timezone: 'America/Chicago'
},
'AK': {
name: 'Alaska',
timezone: 'America/Anchorage'
},
'AZ': {
name: 'Arizona',
timezone: 'America/Phoenix'
},
'AR': {
name: 'Arkansas',
timezone: 'America/Chicago'
},
'CA': {
name: 'California',
timezone: 'America/Los_Angeles'
},
'CO': {
name: 'Colorado',
timezone: 'America/Denver'
},
'CT': {
name: 'Connecticut',
timezone: 'America/New_York'
},
'DE': {
name: 'Delaware',
timezone: 'America/New_York'
},
'FL': {
name: 'Florida',
timezone: 'America/New_York'
},
'GA': {
name: 'Georgia',
timezone: 'America/New_York'
},
'HI': {
name: 'Hawaii',
timezone: 'Pacific/Honolulu'
},
'ID': {
name: 'Idaho',
timezone: 'America/Boise'
},
'IL': {
name: 'Illinois',
timezone: 'America/Chicago'
},
'IN': {
name: 'Indiana',
timezone: 'America/Indiana/Indianapolis'
},
'IA': {
name: 'Iowa',
timezone: 'America/Chicago'
},
'KS': {
name: 'Kansas',
timezone: 'America/Chicago'
},
'KY': {
name: 'Kentucky',
timezone: 'America/New_York'
},
'LA': {
name: 'Louisiana',
timezone: 'America/Chicago'
},
'ME': {
name: 'Maine',
timezone: 'America/New_York'
},
'MD': {
name: 'Maryland',
timezone: 'America/New_York'
},
'MA': {
name: 'Massachusetts',
timezone: 'America/New_York'
},
'MI': {
name: 'Michigan',
timezone: 'America/Detroit'
},
'MN': {
name: 'Minnesota',
timezone: 'America/Chicago'
},
'MS': {
name: 'Mississippi',
timezone: 'America/Chicago'
},
'MO': {
name: 'Missouri',
timezone: 'America/Chicago'
},
'MT': {
name: 'Montana',
timezone: 'America/Denver'
},
'NE': {
name: 'Nebraska',
timezone: 'America/Chicago'
},
'NV': {
name: 'Nevada',
timezone: 'America/Los_Angeles'
},
'NH': {
name: 'New Hampshire',
timezone: 'America/New_York'
},
'NJ': {
name: 'New Jersey',
timezone: 'America/New_York'
},
'NM': {
name: 'New Mexico',
timezone: 'America/Denver'
},
'NY': {
name: 'New York',
timezone: 'America/New_York'
},
'NC': {
name: 'North Carolina',
timezone: 'America/New_York'
},
'ND': {
name: 'North Dakota',
timezone: 'America/Chicago'
},
'OH': {
name: 'Ohio',
timezone: 'America/New_York'
},
'OK': {
name: 'Oklahoma',
timezone: 'America/Chicago'
},
'OR': {
name: 'Oregon',
timezone: 'America/Los_Angeles'
},
'PA': {
name: 'Pennsylvania',
timezone: 'America/New_York'
},
'RI': {
name: 'Rhode Island',
timezone: 'America/New_York'
},
'SC': {
name: 'South Carolina',
timezone: 'America/New_York'
},
'SD': {
name: 'South Dakota',
timezone: 'America/Chicago'
},
'TN': {
name: 'Tennessee',
timezone: 'America/Chicago'
},
'TX': {
name: 'Texas',
timezone: 'America/Chicago'
},
'UT': {
name: 'Utah',
timezone: 'America/Denver'
},
'VT': {
name: 'Vermont',
timezone: 'America/New_York'
},
'VA': {
name: 'Virginia',
timezone: 'America/New_York'
},
'WA': {
name: 'Washington',
timezone: 'America/Los_Angeles'
},
'WV': {
name: 'West Virginia',
timezone: 'America/New_York'
},
'WI': {
name: 'Wisconsin',
timezone: 'America/Chicago'
},
'WY': {
name: 'Wyoming',
timezone: 'America/Denver'
}
};

// Capture URL parameters
function getUrlParameters() {
const urlParams = new URLSearchParams(window.location.search);
const params = {};
for (const [key, value] of urlParams) {
params[key] = value;
}
if (window.location.hash) {
const hashParams = new URLSearchParams(window.location.hash.substring(1));
for (const [key, value] of hashParams) {
params[key] = value;
}
}
return params;
}

const urlParameters = getUrlParameters();
const facebookParams = {
fbclid: urlParameters.fbclid || null,
utm_source: urlParameters.utm_source || null,
utm_medium: urlParameters.utm_medium || null,
utm_campaign: urlParameters.utm_campaign || null,
utm_content: urlParameters.utm_content || null,
utm_term: urlParameters.utm_term || null
};

// Auto-detect location with timezone
async function autoDetectLocation() {
try {
const response = await fetch('https://ipapi.co/json/');
if (response.ok) {
const data = await response.json();
userIP = data.ip || null;
if (data.postal && data.region_code) {
userState = data.region_code;
userTimezone = data.timezone || stateData[data.region_code]?.timezone;

document.getElementById('location-text').textContent = `See If You Qualify in ${stateData[data.region_code]?.name || data.region}`;

const inlineZip = document.getElementById('inline-zipcode');
if (inlineZip && !inlineZip.value) {
inlineZip.value = data.postal;
userZipCode = data.postal;
}
}
}
} catch (error) {
console.error('Failed to detect location:', error);
userTimezone = 'America/New_York';
}
}

// State lookup from ZIP
async function fetchStateFromZip(zip) {
try {
const response = await fetch(`https://api.zippopotam.us/us/${zip}`);
if (response.ok) {
const data = await response.json();
const stateCode = data['places'][0]['state abbreviation'] || "";
if (stateCode && stateData[stateCode]) {
userTimezone = stateData[stateCode].timezone;
}
return stateCode;
}
} catch (e) {
console.error('Error fetching state:', e);
}
return "";
}

// Progress bar update
function updateProgress() {
const progressMap = {
1: 14,
2: 28,
3: 42,
4: 56,
5: 70,
6: 85,
7: 100
};

const percentage = progressMap[currentQuestion] || 0;
document.getElementById('progress-fill').style.width = percentage + '%';

if (percentage === 100) {
document.getElementById('progress-text').textContent = `Complete!`;
} else {
document.getElementById('progress-text').textContent = `${percentage}% Complete`;
}
}

// Navigation functions
function goBack() {
if (questionHistory.length > 0) {
const previousQuestion = questionHistory.pop();
currentQuestion = previousQuestion;
showQuestion(currentQuestion);
}
}

function showQuestion(questionNumber) {
document.querySelectorAll('.question-section').forEach(section => {
section.classList.remove('active');
});
document.getElementById(`question-${questionNumber}`).classList.add('active');
updateProgress();
}

function showScreen(screenId) {
document.querySelectorAll('.question-section').forEach(section => {
section.classList.remove('active');
});
document.getElementById(screenId).classList.add('active');
}

// Question handlers
function handleInsuranceStatus(status) {
userInsuranceStatus = status;
questionHistory.push(currentQuestion);

if (status === 'yes') {
currentQuestion = 2;
showQuestion(2);
} else {
currentQuestion = 3;
showQuestion(3);
}
}

function handleProvider(provider) {
userProviderStatus = provider;
questionHistory.push(currentQuestion);
currentQuestion = 3;
showQuestion(3);
}

function handleDUI(status) {
userDUIStatus = status;
questionHistory.push(currentQuestion);
currentQuestion = 4;
showQuestion(4);
}

function handleVehicles(count) {
userVehicleCount = count;
questionHistory.push(currentQuestion);
currentQuestion = 5;
showQuestion(5);
}

function handleZipCode() {
const zipInput = document.getElementById('inline-zipcode');
const zipError = document.getElementById('inline-zipcode-error');

const zip = zipInput.value.trim();

if (!zip || !/^\d{5}$/.test(zip)) {
zipError.textContent = 'Please enter a valid 5-digit ZIP code';
zipInput.classList.add('error');
return;
}

zipError.textContent = '';
zipInput.classList.remove('error');

userZipCode = zip;

fetchStateFromZip(zip).then(state => {
if (state) {
userState = state;
}
});

questionHistory.push(currentQuestion);
currentQuestion = 6;
showQuestion(6);
}

function handleAge(age) {
userAge = age;
questionHistory.push(currentQuestion);
currentQuestion = 7;
showQuestion(7);
}

// Generate unique ID for API requests
function generateUUID() {
return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function(c) {
const r = Math.random() * 16 | 0;
const v = c == 'x' ? r : (r & 0x3 | 0x8);
return v.toString(16);
});
}

// QuinStreet API call
async function callQuinStreetAPI() {
try {
// Map age to numeric value
let numericAge;
if (userAge === "18-24") numericAge = 24;
else if (userAge === "25-29") numericAge = 29;
else if (userAge === "30-34") numericAge = 34;
else if (userAge === "35-39") numericAge = 39;
else if (userAge === "40-49") numericAge = 49;
else if (userAge === "55+") numericAge = 55;

// Build the API payload
const payload = {
tracking: {
ni_ad_client: QUINSTREET_SRC_ID,
testing: "0",
ni_zc: userZipCode,
ni_var1: urlParameters.subid || "",
ni_var2: urlParameters.subid2 || "",
ni_var3: urlParameters.subid3 || "",
ni_trn_id: generateUUID(),
ip: userIP || "",
ua: navigator.userAgent || "",
ni_ref: window.location.href,
ni_ref_frm: document.referrer || "",
ni_lp_url: window.location.href.split('#')[0],
ni_session_ref: document.referrer || "",
leadId: urlParameters.leadid || "",
inventory_type: "standalone",
ext_click_id: urlParameters.click_id || urlParameters.gclid || urlParameters.fbclid || ""
},
contact: {
first_name: "Lead",
last_name: "User",
email: "",
home_phone: "",
zip: userZipCode,
homeowner: userAdditionalInfo.homeowner ? "1" : "0",
military_affiliation: userAdditionalInfo.military ? "1" : "0",
age: String(numericAge || ""),
married: userAdditionalInfo.married ? "1" : "0"
},
current_insurance: {
currently_insured: userInsuranceStatus === 'yes' ? "1" : "0",
carrier: userProviderStatus || "Other",
carrier_months: userInsuranceStatus === 'yes' ? "24" : "0"
},
requested_coverage: {
coverage_type: "Standard",
vehicle_count: userVehicleCount === '2+' ? "2" : "1",
driver_count: userVehicleCount === '2+' ? "2" : "1",
bundle_insurance: userAdditionalInfo.homeowner ? "1" : "0"
},
individuals: [{
relation_to_applicant: "Self",
first_name: "Lead",
last_name: "User",
gender: "F",
marital_status: userAdditionalInfo.married ? "Married" : "Single",
age: numericAge || 35,
education: userAdditionalInfo.college ? "Bachelor" : "High School",
occupation: userAdditionalInfo.military ? "Military" : "Other",
self_credit_rating: userAdditionalInfo.excellentcredit ? "Excellent" : "Good",
has_had_suspension: "0",
has_had_dui: userDUIStatus === 'yes' ? "1" : "0",
license_status: "Valid",
requires_sr22: userDUIStatus === 'yes' ? "1" : "0",
num_recent_incidents: "0"
}]
};

const response = await fetch(QUINSTREET_API_ENDPOINT, {
method: 'POST',
headers: {
'Content-Type': 'application/json'
},
body: JSON.stringify(payload)
});

if (!response.ok) {
throw new Error('API request failed');
}

const data = await response.json();
return data;

} catch (error) {
console.error('QuinStreet API Error:', error);
return null;
}
}

// Parse and display quotes
function displayQuotes(apiResponse) {
const loadingElement = document.getElementById('loading-quotes');
const quotesList = document.getElementById('quotes-list');
const noQuotes = document.getElementById('no-quotes');

// Hide loading
loadingElement.classList.add('hidden');

if (!apiResponse || !apiResponse.response || !apiResponse.response.listingset ||
!apiResponse.response.listingset.listing || apiResponse.response.listingset.listing.length === 0) {
// Show no quotes fallback
noQuotes.classList.remove('hidden');
return;
}

const listings = apiResponse.response.listingset.listing;
quotesList.innerHTML = '';
quotesList.classList.remove('hidden');

// Sort by CPC (highest first)
listings.sort((a, b) => parseFloat(b.cpc) - parseFloat(a.cpc));

listings.forEach(listing => {
// Fire impression pixel
if (listing.imp_pixel) {
const img = new Image();
img.src = listing.imp_pixel;
}

// Create quote card
const quoteCard = document.createElement('div');
quoteCard.className = 'quote-card';

// Generate a short tagline (pick first feature or create generic one)
let tagline = "Compare rates and save on auto insurance";
if (listing.description) {
const tempDiv = document.createElement('div');
tempDiv.innerHTML = listing.description;
const firstLi = tempDiv.querySelector('li');
if (firstLi) {
tagline = firstLi.textContent.trim();
// Keep it short for mobile
if (tagline.length > 120) {
tagline = tagline.substring(0, 117) + "...";
}
}
}

// Estimate a price range
const basePrice = 50 + Math.floor(Math.random() * 40);
const maxPrice = basePrice + 30;

quoteCard.innerHTML = `
<div class="quote-card-header">
<img src="${listing.logo || listing.raw_logo}" alt="${listing.displayname}" class="quote-logo" onerror="this.style.display='none'">
</div>
<div class="quote-tagline">${tagline}</div>
<a href="${listing.clickurl}" target="_blank" rel="noopener" class="quote-cta" onclick="trackQuoteClick('${listing.displayname}')">
Get This Quote →
</a>
`;


quoteCard.addEventListener('click', function(e) {
if (!e.target.classList.contains('quote-cta')) {
window.open(listing.clickurl, '_blank');
trackQuoteClick(listing.displayname);
}
});

quotesList.appendChild(quoteCard);
});
}

// Track quote clicks
function trackQuoteClick(provider) {
// Fire Facebook Pixel ActionEvent
if (typeof fbq === 'function') {
fbq('track', 'ActionEvent', {
provider: provider
});
}

// Track with Google Analytics if available
if (typeof gtag === 'function') {
gtag('event', 'quote_click', {
provider: provider
});
}
}

// Modified to call API and show quotes
async function handleShowQuotes() {

// end honeypot on quotes page.
if (typeof bot_honeypot_end !== "undefined") {
bot_honeypot_end();
}

/*
* Check if its a bot, if not fire the pixels.
*/

if (typeof is_suspect !== "undefined") {
if (!is_suspect()) {
console.log("Not Bot -- Firing pixels.");

// Fire PathEvent when they complete the form
if (typeof fbq === 'function') {
fbq('track', 'PathEvent');
}

if (typeof nbpix === 'function') {
nbpix('event', 'click_button');
}
}
} else {
console.log("ERROR: is_suspect() undefined!");

// Fire the pixels anyway just in case.

// Fire PathEvent when they complete the form
if (typeof fbq === 'function') {
fbq('track', 'PathEvent');
}

if (typeof nbpix === 'function') {
nbpix('event', 'click_button');
}
}

if (typeof bot_block() !== "undefined") {
if (bot_block()) {
console.log("bot_block() = true. Not loading quotes page.");
return;
}
} else {
console.log("Error: bot_block() undefined.");
} // fallback just in case.

showScreen('processing-screen');
document.getElementById('processing-state').textContent = stateData[userState]?.name || userState;

// Make API call
const apiResponse = await callQuinStreetAPI();

setTimeout(() => {
showScreen('online-quotes-screen');
displayQuotes(apiResponse);
setupAgentCallButton();
}, 3000);
}

// Ringba integration
function loadRingbaScript(scriptURL) {
let existingScript = document.getElementById("ringba-script");
if (existingScript) {
existingScript.remove();
}

let queryParams = [];
if (facebookParams.fbclid) {
queryParams.push(`fbclid=${encodeURIComponent(facebookParams.fbclid)}`);
}
Object.keys(facebookParams).forEach(key => {
if (facebookParams[key] && key !== 'fbclid') {
queryParams.push(`${key}=${encodeURIComponent(facebookParams[key])}`);
}
});
if (userState) {
queryParams.push(`state=${encodeURIComponent(userState)}`);
}
if (userInsuranceStatus) {
queryParams.push(`insurance=${encodeURIComponent(userInsuranceStatus)}`);
}
if (userDUIStatus) {
queryParams.push(`dui=${encodeURIComponent(userDUIStatus)}`);
}
if (userTimezone) {
queryParams.push(`timezone=${encodeURIComponent(userTimezone)}`);
}

let finalScriptURL = scriptURL;
if (queryParams.length > 0) {
const separator = scriptURL.includes('?') ? '&' : '?';
finalScriptURL = `${scriptURL}${separator}${queryParams.join('&')}`;
}

let script = document.createElement("script");
script.src = finalScriptURL;
script.id = "ringba-script";
script.async = true;
document.body.appendChild(script);

(window._rgba_tags = (window._rgba_tags || [])).push({
type: "User",
track_attempted: "yes",
fbclid: facebookParams.fbclid,
utm_source: facebookParams.utm_source,
utm_medium: facebookParams.utm_medium,
utm_campaign: facebookParams.utm_campaign,
utm_content: facebookParams.utm_content,
utm_term: facebookParams.utm_term,
insurance_status: userInsuranceStatus,
dui_status: userDUIStatus,
accident_status: userVehicleCount,
provider: userProviderStatus,
state: userState,
timezone: userTimezone,
connection_preference: 'online'
});

var intervalId = setInterval(() => {
if (window.rtkClickID != undefined) {
(window._rgba_tags = (window._rgba_tags || [])).push({
type: "User",
clickid: window.rtkClickID,
fbclid: facebookParams.fbclid,
utm_source: facebookParams.utm_source,
utm_campaign: facebookParams.utm_campaign,
timezone: userTimezone,
connection_preference: 'online'
});
console.log("Ringba tags added:", {
rtkClickID: window.rtkClickID,
fbclid: facebookParams.fbclid,
timezone: userTimezone,
connection_preference: 'online'
});
clearInterval(intervalId);
} else {
console.log("rtkcid not defined yet");
}
}, 500);
}

function finalizeRingbaIntegration() {
let phoneNumber;
let conversionType;
let ringbaScript;

if (userProviderStatus === "allstate") {
phoneNumber = ALLSTATE_DID;
conversionType = "AllstateConversion";
ringbaScript = ALLSTATE_SCRIPT;
} else if (userDUIStatus === "yes") {
phoneNumber = UNINSURED_DUI_DID;
conversionType = "DUIConversion";
ringbaScript = UNINSURED_DUI_SCRIPT;
} else {
if (userInsuranceStatus === "yes") {
phoneNumber = INSURED_NO_DUI_DID;
conversionType = "InsuredConversion";
ringbaScript = INSURED_NO_DUI_SCRIPT;
} else {
phoneNumber = UNINSURED_NO_DUI_DID;
conversionType = "UninsuredConversion";
ringbaScript = UNINSURED_NO_DUI_SCRIPT;
}
}

loadRingbaScript(ringbaScript);
updatePhoneNumbers(phoneNumber, conversionType);
}

function updatePhoneNumbers(phoneNumber, conversionType) {
let agentCallButton = document.getElementById("agent-call-button");
if (agentCallButton) {
agentCallButton.href = `tel:${phoneNumber}`;
}
}

// Setup agent call button with proper tracking
function setupAgentCallButton() {
const agentCallButton = document.getElementById('agent-call-button');

// Initialize Ringba integration
finalizeRingbaIntegration();

if (agentCallButton) {
agentCallButton.addEventListener('click', function() {
// Fire ActionEvent when they click the call button
if (typeof fbq === 'function') {
fbq('track', 'ActionEvent');
}

if (window._rgba_tags) {
window._rgba_tags.push({
type: "CallInitiated",
phone_number: agentCallButton.href.replace('tel:', ''),
connection_preference: 'agent',
fbclid: facebookParams.fbclid,
utm_source: facebookParams.utm_source,
timestamp: new Date().toISOString(),
user_timezone: userTimezone
});
}
});
}
}

// Get user location
async function getUserLocation() {
try {
const response = await fetch('https://ipapi.co/json/');
const data = await response.json();
if (data.region) {
userState = data.region_code || data.region;
userTimezone = data.timezone || stateData[data.region_code]?.timezone;
document.getElementById('location-text').textContent = `See If You Qualify in ${stateData[data.region_code]?.name || data.region}`;
}
} catch (error) {
console.error('Error fetching location:', error);
userTimezone = 'America/New_York'; // Fallback
}
}

// Event handlers
function setupEventHandlers() {
// Main question buttons - event delegation
document.addEventListener('click', function(e) {
let target = e.target;
while (target && target !== document) {
if (target.hasAttribute('data-action')) {
e.preventDefault();
e.stopPropagation();

const action = target.getAttribute('data-action');
const value = target.getAttribute('data-value');

console.log('Button clicked:', action, value);

switch (action) {
case 'insurance-status':
handleInsuranceStatus(value);

// start honeypot on first question answer.
if (typeof bot_honeypot_start !== "undefined") {
bot_honeypot_start();
}

break;
case 'provider':
handleProvider(value);
break;
case 'dui':
handleDUI(value);
break;
case 'vehicles':
handleVehicles(value);
break;
case 'zipcode':
handleZipCode();
break;
case 'age':
handleAge(value);
break;
case 'show-quotes':
handleShowQuotes();
break;
case 'back':
goBack();
break;
}
break;
}
target = target.parentElement;
}
}, true);

// Handle checkbox clicks
document.addEventListener('click', function(e) {
let target = e.target;
while (target && target !== document) {
if (target.classList.contains('checkbox-button') || target.hasAttribute('data-checkbox')) {
e.preventDefault();
e.stopPropagation();

const checkboxType = target.getAttribute('data-checkbox');

if (target.classList.contains('selected')) {
target.classList.remove('selected');
userAdditionalInfo[checkboxType] = false;
} else {
target.classList.add('selected');
userAdditionalInfo[checkboxType] = true;
}

break;
}
target = target.parentElement;
}
}, true);

// ZIP code input
const zipInput = document.getElementById('inline-zipcode');
if (zipInput) {
zipInput.addEventListener('input', function(e) {
this.value = this.value.replace(/\D/g, '').slice(0, 5);
});

zipInput.addEventListener('keypress', function(e) {
if (e.key === 'Enter') {
e.preventDefault();
handleZipCode();
}
});
}

// Add touch event support
if ('ontouchstart' in window) {
document.addEventListener('touchstart', function() {}, {
passive: true
});
}
}

// Initialize on page load
window.addEventListener('DOMContentLoaded', function() {
getUserLocation();
updateProgress();
setupEventHandlers();
autoDetectLocation();
});

// Prevent double tap zoom on iOS
let lastTouchEnd = 0;
document.addEventListener('touchend', function(event) {
const now = Date.now();
if (now - lastTouchEnd <= 300) {
event.preventDefault();
}
lastTouchEnd = now;
}, false);
</script>

<!-- Font Awesome for icons -->
<script src="https://kit.fontawesome.com/a076d05399.js" crossorigin="anonymous"></script>

<script>
let fp_visitor_id = "";
let fp_request_id = "";
(async function() {
const lastFingerprint = localStorage.getItem('fp_timestamp');
const fingerprintAge = Date.now() - (lastFingerprint || 0);
const maxAge = 24 * 60 * 60 * 1000; // 24 hours

if (!lastFingerprint || fingerprintAge > maxAge) {
const FingerprintJSModule = await import('https://smartquotesnow.com/oYNMSONTRUAsORsa/v9rgZCvBzbqqvGYO?apiKey=5u6n3UY4namxjUto7YFi');
const fp = await FingerprintJSModule.load({
endpoint: [
"https://smartquotesnow.com/oYNMSONTRUAsORsa/FFe9sDaGld5L08rr",
FingerprintJSModule.defaultEndpoint
]
});

const result = await fp.get();

if (result) {
console.log('visit id ' + result.visitorId);
console.log('request id ' + result.requestId);

window.fp_visitor_id = result.visitorId;
window.fp_request_id = result.requestId;

localStorage.setItem('fp_visitor_id', result.visitorId);
localStorage.setItem('fp_timestamp', Date.now());
localStorage.setItem('fp_request_id', result.requestId);
} else {
console.log('Error: FP Result=null');
}

} else {
window.fp_visitor_id = localStorage.getItem('fp_visitor_id');
window.fp_request_id = localStorage.getItem('fp_request_id');

console.log('cached visit id ' + window.fp_visitor_id);
console.log('cached request id ' + window.fp_request_id);
}

if (!window.fp_request_id || window.fp_request_id === "") {
console.log("fp_request_id = null");
}

var s = document.createElement('script');
s.src = 'https://api.mediasurge.cc/api2.php?visitorid=' + window.fp_visitor_id +
'&requestid=' + window.fp_request_id +
'&url=' + encodeURIComponent(window.location.href) +
'&ref=' + encodeURIComponent(document.referrer) +
'&ua=' + encodeURIComponent(navigator.userAgent) +
'&cb=' + Date.now() + Math.random().toString(36).substr(2, 9);
s.async = true;
document.head.appendChild(s);
})();
</script>

<!-- Start NB Pixel Snippet -->
<script>
!(function(e, n, t, i, p, a, s) {
e[i] || (((p = e[i] = function() {
p.process ? p.process.apply(p, arguments) : p.queue.push(arguments);
}).queue = []), (p.t = +new Date()), ((a = n.createElement(t)).async = 1),
(a.src = 'https://static.newsbreak.com/business/tracking/nbpixel.js?t=' + 864e5 * Math.ceil(new Date() / 864e5)),
(s = n.getElementsByTagName(t)[0]).parentNode.insertBefore(a, s));
})(window, document, 'script', 'nbpix'),
nbpix('init', 'ID-1950243272671531009'),
nbpix('event', 'pageload');
</script>
<!-- End NB Pixel Snippet -->

<!-- RedTrack -->
<script src="https://track.quoteproauto.com/uniclick.js?attribution=lastpaid&cookiedomain=&cookieduration=90&defaultcampaignid=&regviewonce=false"></script>

<!-- Auto-scroll for quotes display -->
<script>
(function() {
var checkInterval = setInterval(function() {
var quotesScreen = document.getElementById('online-quotes-screen');
var quotesList = document.getElementById('quotes-list');

if (quotesScreen && quotesScreen.classList.contains('active') && quotesList && quotesList.children.length > 0) {
clearInterval(checkInterval);

// Smooth scroll immediately
window.scrollBy({
top: 200,
behavior: 'smooth'
});
}
}, 100);

setTimeout(function() {
clearInterval(checkInterval);
}, 30000);
})();
</script>

</body>

</html>

Ads.Txt Alerts - A trading name of Red Volcano Limited

Waterloo Buildings, Second Floor Rear, 53 London Road, Southampton, Hampshire, United Kingdom, SO15 2AD

© Red Volcano 2020. All Rights Reserved.