/**
 * Home Security Native Ads Funnel - Developer Stylesheet
 * Optimized for Taboola / Outbrain / Yahoo Native Traffic
 */

:root {
  --primary: #1d4ed8;
  --primary-hover: #1e40af;
  --secondary: #0f172a;
  --accent-gold: #f59e0b;
  --accent-gold-hover: #d97706;
  --accent-green: #10b981;
  --accent-green-hover: #059669;
  --bg-page: #f8fafc;
  --bg-card: #ffffff;
  --border-color: #e2e8f0;
  --text-main: #1e293b;
  --text-muted: #64748b;
  --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
}

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

body {
  font-family: var(--font-family);
  background-color: var(--bg-page);
  color: var(--text-main);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* Compliance Banner */
.compliance-topbar {
  background-color: var(--secondary);
  color: #94a3b8;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 7px 16px;
  text-align: center;
  font-weight: 600;
}

/* Navigation Header */
.site-header {
  background-color: #ffffff;
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 40;
  box-shadow: var(--shadow-sm);
}

.header-container {
  max-width: 860px;
  margin: 0 auto;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo-wrapper {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.logo-icon {
  background: var(--primary);
  color: #ffffff;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.logo-text {
  font-size: 17px;
  font-weight: 800;
  color: var(--secondary);
  letter-spacing: -0.02em;
}

.logo-text span {
  color: var(--primary);
}

.header-badge {
  font-size: 11px;
  color: var(--text-muted);
  border-left: 1px solid var(--border-color);
  padding-left: 8px;
  margin-left: 8px;
  text-transform: uppercase;
  font-weight: 600;
}

.header-cta {
  background-color: var(--accent-gold);
  color: #0f172a;
  font-weight: 700;
  font-size: 12px;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  transition: background-color 0.2s ease;
}

.header-cta:hover {
  background-color: var(--accent-gold-hover);
}

/* Main Content Container */
.main-wrapper {
  max-width: 860px;
  margin: 0 auto;
  padding: 24px 16px 40px;
}

/* Article Styles */
.article-header {
  margin-bottom: 24px;
}

.category-tag {
  display: inline-block;
  background-color: #dbeafe;
  color: #1e40af;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 3px 10px;
  border-radius: 9999px;
  margin-bottom: 12px;
}

.article-title {
  font-size: 28px;
  font-weight: 800;
  line-height: 1.25;
  color: #0f172a;
  margin-bottom: 12px;
}

@media (min-width: 640px) {
  .article-title {
    font-size: 36px;
  }
}

.article-deck {
  font-size: 17px;
  color: #475569;
  line-height: 1.5;
  margin-bottom: 16px;
}

.author-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-top: 8px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-color);
  font-size: 13px;
  color: var(--text-muted);
}

.author-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: #cbd5e1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: #334155;
}

.author-name {
  font-weight: 700;
  color: var(--text-main);
}

.article-body {
  font-size: 16px;
  line-height: 1.7;
  color: #334155;
  margin-bottom: 36px;
}

.article-body p {
  margin-bottom: 18px;
}

.alert-banner {
  background-color: #fef3c7;
  border-left: 4px solid #f59e0b;
  padding: 16px;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  margin: 24px 0;
  color: #92400e;
  font-size: 14px;
}

.alert-banner strong {
  display: block;
  font-size: 12px;
  text-transform: uppercase;
  margin-bottom: 4px;
  letter-spacing: 0.05em;
}

.subheading {
  font-size: 22px;
  font-weight: 800;
  color: #0f172a;
  margin: 28px 0 12px;
}

/* Feature Grid */
.feature-box {
  background-color: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 20px;
  margin: 24px 0;
  box-shadow: var(--shadow-sm);
}

.feature-box-title {
  font-size: 14px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #0f172a;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.feature-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  font-size: 14px;
}

@media (min-width: 600px) {
  .feature-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.feature-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.feature-item .check {
  color: var(--accent-green);
  font-weight: 700;
}

/* Interactive Quiz Card */
.quiz-card {
  background-color: #ffffff;
  border: 2px solid var(--primary);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  margin: 36px 0;
  scroll-margin-top: 80px;
}

.quiz-header {
  background: linear-gradient(135deg, #1e40af 0%, #1e3a8a 100%);
  color: #ffffff;
  padding: 20px 16px;
  text-align: center;
}

.quiz-pill {
  display: inline-block;
  background-color: var(--accent-gold);
  color: #0f172a;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  padding: 3px 12px;
  border-radius: 9999px;
  margin-bottom: 8px;
}

.quiz-header h3 {
  font-size: 20px;
  font-weight: 800;
}

.quiz-header p {
  font-size: 13px;
  color: #dbeafe;
  margin-top: 4px;
}

.quiz-progress-bar-wrap {
  background-color: #f1f5f9;
  border-bottom: 1px solid var(--border-color);
  padding: 10px 20px;
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
}

.progress-track {
  width: 100%;
  height: 6px;
  background-color: #e2e8f0;
}

.progress-fill {
  height: 6px;
  background-color: var(--primary);
  width: 25%;
  transition: width 0.3s ease;
}

.quiz-content {
  padding: 24px 20px;
}

@media (min-width: 640px) {
  .quiz-content {
    padding: 32px;
  }
}

.quiz-step {
  max-width: 480px;
  margin: 0 auto;
  text-align: center;
}

.quiz-step.hidden {
  display: none;
}

.quiz-question {
  font-size: 20px;
  font-weight: 800;
  color: #0f172a;
  margin-bottom: 6px;
}

.quiz-hint {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 20px;
}

/* Inputs & Buttons */
.zip-input {
  width: 100%;
  border: 2px solid #cbd5e1;
  border-radius: var(--radius-md);
  padding: 14px 16px;
  font-size: 22px;
  font-family: monospace;
  font-weight: 800;
  letter-spacing: 0.15em;
  text-align: center;
  color: #0f172a;
  outline: none;
  transition: border-color 0.2s;
  margin-bottom: 16px;
}

.zip-input:focus {
  border-color: var(--primary);
}

.btn-primary {
  width: 100%;
  background-color: var(--primary);
  color: #ffffff;
  font-size: 16px;
  font-weight: 800;
  padding: 14px 20px;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  box-shadow: var(--shadow-md);
  transition: background-color 0.2s, transform 0.1s;
}

.btn-primary:hover {
  background-color: var(--primary-hover);
}

.btn-pulse {
  animation: pulse-soft 2s infinite;
}

@keyframes pulse-soft {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(0.99); opacity: 0.95; }
}

/* Option Buttons */
.options-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

@media (min-width: 480px) {
  .options-grid.two-col {
    grid-template-columns: 1fr 1fr;
  }
}

.option-btn {
  background: #ffffff;
  border: 2px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 16px;
  text-align: center;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-main);
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.option-btn:hover {
  border-color: var(--primary);
  background-color: #f0f7ff;
}

.option-btn.row-style {
  flex-direction: row;
  justify-content: space-between;
  text-align: left;
}

.badge-tag {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: 4px;
  background-color: #d1fae5;
  color: #065f46;
}

/* Spinner */
.spinner {
  width: 44px;
  height: 44px;
  border: 4px solid #dbeafe;
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 20px auto;
}

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

/* Form Styles */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 12px;
  text-align: left;
}

.form-group {
  margin-bottom: 12px;
  text-align: left;
}

.form-label {
  display: block;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #475569;
  margin-bottom: 4px;
}

.form-input {
  width: 100%;
  border: 1px solid #cbd5e1;
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  font-size: 14px;
  outline: none;
}

.form-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.2);
}

.tcpa-box {
  background-color: #f8fafc;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 12px;
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.45;
  text-align: left;
  margin-bottom: 16px;
}

.tcpa-box label {
  display: flex;
  gap: 8px;
  cursor: pointer;
}

.btn-submit {
  width: 100%;
  background-color: var(--accent-green);
  color: #ffffff;
  font-size: 16px;
  font-weight: 800;
  padding: 16px;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  box-shadow: var(--shadow-md);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  transition: background-color 0.2s;
}

.btn-submit:hover {
  background-color: var(--accent-green-hover);
}

/* Success Card */
.success-icon {
  width: 64px;
  height: 64px;
  background-color: #d1fae5;
  color: var(--accent-green);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
}

.priority-call-box {
  background: #eff6ff;
  border: 2px solid #3b82f6;
  border-radius: var(--radius-md);
  padding: 20px;
  max-width: 380px;
  margin: 20px auto 0;
  text-align: left;
}

.btn-call {
  display: block;
  background-color: var(--primary);
  color: #ffffff;
  text-align: center;
  padding: 12px;
  border-radius: var(--radius-sm);
  font-size: 16px;
  font-weight: 800;
  text-decoration: none;
  margin-top: 12px;
  transition: background-color 0.2s;
}

.btn-call:hover {
  background-color: var(--primary-hover);
}

/* Taboola Footer */
.site-footer {
  background-color: #0f172a;
  color: #94a3b8;
  font-size: 12px;
  padding: 40px 16px;
  text-align: center;
  border-top: 1px solid #1e293b;
}

.footer-container {
  max-width: 860px;
  margin: 0 auto;
}

.footer-links {
  margin: 16px 0;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-links a {
  color: #cbd5e1;
  text-decoration: none;
}

.footer-links a:hover {
  text-decoration: underline;
}

/* Modals */
.modal-overlay {
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.65);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  z-index: 100;
}

.modal-overlay.hidden {
  display: none;
}

.modal-window {
  background-color: #ffffff;
  border-radius: var(--radius-md);
  max-width: 540px;
  width: 100%;
  max-height: 80vh;
  overflow-y: auto;
  padding: 24px;
  font-size: 13px;
  color: #334155;
  text-align: left;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 12px;
  margin-bottom: 16px;
}

.modal-header h4 {
  font-size: 16px;
  font-weight: 800;
  color: #0f172a;
}

.modal-close-btn {
  background: none;
  border: none;
  font-size: 24px;
  color: #94a3b8;
  cursor: pointer;
}
