/* =========================================
   LeadBridge Audit Tool Styles
   Audit section, modal, form, responsive
   ========================================= */

/* ---- Audit Section ---- */
.audit {
  padding: 100px 40px;
  background: var(--bg);
  border-top: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}
.audit-bg-glow {
  position: absolute;
  bottom: -200px;
  left: -200px;
  width: 700px;
  height: 700px;
  background: radial-gradient(circle, rgba(255,149,0,0.05) 0%, transparent 70%);
  pointer-events: none;
}
.audit-inner { max-width: 1200px; margin: 0 auto; }
.audit-header { text-align: center; margin-bottom: 60px; }
.audit-headline {
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
  margin: 12px 0 16px;
}
.audit-sub {
  font-size: 1rem;
  color: var(--text-muted);
  max-width: 520px;
  margin: 0 auto;
  line-height: 1.7;
}

/* Layout */
.audit-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}

/* Controls */
.audit-controls {
  display: flex;
  flex-direction: column;
  gap: 32px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 40px;
}
.audit-field { display: flex; flex-direction: column; gap: 10px; }
.audit-field-row { display: flex; justify-content: space-between; align-items: baseline; }
.audit-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.audit-val {
  font-family: 'Syne', sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--accent-teal);
}

/* Industry grid */
.industry-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
.industry-btn {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 8px;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.78rem;
  color: var(--text-muted);
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s, color 0.2s;
  text-align: center;
  line-height: 1.4;
}
.industry-btn:hover { border-color: var(--border-teal); color: var(--text); }
.industry-btn.active {
  background: rgba(0,229,184,0.1);
  border-color: var(--accent-teal);
  color: var(--accent-teal);
  font-weight: 600;
}

/* Slider */
.audit-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 4px;
  background: var(--surface-2);
  border-radius: 2px;
  outline: none;
  cursor: pointer;
}
.audit-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--accent-teal);
  cursor: pointer;
  box-shadow: 0 0 12px rgba(0,229,184,0.4);
  border: 2px solid var(--bg);
  transition: transform 0.15s ease;
}
.audit-slider::-webkit-slider-thumb:hover { transform: scale(1.15); }
.audit-slider::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--accent-teal);
  cursor: pointer;
  border: 2px solid var(--bg);
}
.audit-slider-minmax {
  display: flex;
  justify-content: space-between;
  font-size: 0.68rem;
  color: var(--text-dim);
}

/* Revenue input */
.audit-input-wrap { position: relative; display: flex; align-items: center; }
.audit-input-prefix {
  position: absolute;
  left: 14px;
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  color: var(--accent-teal);
  font-size: 1rem;
  pointer-events: none;
}
.audit-input {
  width: 100%;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 14px 12px 28px;
  font-family: 'Syne', sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  outline: none;
  transition: border-color 0.2s;
  -moz-appearance: textfield;
}
.audit-input::-webkit-inner-spin-button,
.audit-input::-webkit-outer-spin-button { -webkit-appearance: none; }
.audit-input:focus { border-color: var(--border-teal); }

/* Results panel */
.audit-results {
  background: var(--surface);
  border: 1px solid var(--border-amber);
  border-radius: 20px;
  overflow: hidden;
  position: sticky;
  top: 84px;
}
.audit-results-inner { padding: 40px; }
.audit-results-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  text-align: center;
  margin-bottom: 12px;
}

/* Big animated dollar */
.audit-dollar-wrap {
  text-align: center;
  margin-bottom: 32px;
  min-height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.audit-dollar {
  font-family: 'Syne', sans-serif;
  font-size: clamp(2.8rem, 6vw, 4.5rem);
  font-weight: 800;
  color: var(--accent-amber);
  letter-spacing: -0.03em;
  line-height: 1;
  text-shadow: 0 0 60px rgba(255,149,0,0.3);
  transform-origin: center;
  transition: color 0.2s;
  display: inline-block;
}
@keyframes pop-in {
  0%   { transform: scale(0.92); opacity: 0.7; }
  60%  { transform: scale(1.06); }
  100% { transform: scale(1);    opacity: 1; }
}
.audit-dollar.pop { animation: pop-in 0.4s cubic-bezier(0.34,1.56,0.64,1) forwards; }

/* Metrics row */
.audit-metrics {
  display: flex;
  align-items: flex-start;
  gap: 0;
  border-top: 1px solid var(--border);
  padding-top: 24px;
  margin-bottom: 32px;
}
.audit-metric { flex: 1; text-align: center; padding: 0 12px; }
.audit-metric-sep { width: 1px; background: var(--border); flex-shrink: 0; }
.metric-val {
  display: block;
  font-family: 'Syne', sans-serif;
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 4px;
}
.metric-label {
  display: block;
  font-size: 0.68rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Recovery section */
.audit-recovery {
  background: rgba(0,229,184,0.05);
  border: 1px solid var(--border-teal);
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 28px;
}
.recovery-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}
.recovery-label {
  font-size: 0.72rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
}
.recovery-amount {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--accent-teal);
}
.recovery-list { list-style: none; display: flex; flex-direction: column; gap: 12px; }
.recovery-list li {
  display: flex;
  gap: 10px;
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.5;
}
.recovery-icon { font-size: 1rem; flex-shrink: 0; margin-top: 1px; }
.recovery-list li strong { color: var(--text); font-weight: 600; }

/* CTA button */
.audit-cta-btn {
  width: 100%;
  background: var(--accent-teal);
  color: #060912;
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 0.95rem;
  padding: 16px 24px;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 0 32px rgba(0,229,184,0.2);
  letter-spacing: -0.01em;
}
.audit-cta-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 48px rgba(0,229,184,0.35);
}
.audit-book-link {
  display: block;
  text-align: center;
  margin-top: 12px;
  font-size: 0.83rem;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s;
}
.audit-book-link:hover { color: var(--accent-teal); }

/* ---- Audit Modal ---- */
.audit-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(6,9,18,0.85);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 24px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}
.audit-modal-overlay.open { opacity: 1; pointer-events: all; }
.audit-modal {
  background: var(--surface);
  border: 1px solid var(--border-teal);
  border-radius: 20px;
  padding: 48px;
  width: 100%;
  max-width: 560px;
  position: relative;
  transform: translateY(16px);
  transition: transform 0.2s ease;
  max-height: 90vh;
  overflow-y: auto;
}
.audit-modal-overlay.open .audit-modal { transform: translateY(0); }
.audit-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 50%;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.75rem;
  color: var(--text-muted);
  transition: color 0.2s, border-color 0.2s;
}
.audit-modal-close:hover { color: var(--text); border-color: var(--border-teal); }
.audit-modal-eyebrow {
  font-size: 0.72rem;
  color: var(--accent-teal);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 500;
  margin-bottom: 8px;
}
.audit-modal-title {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-bottom: 8px;
}
.audit-modal-sub {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 32px;
}

/* Lead form */
.audit-form { display: flex; flex-direction: column; gap: 16px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-field { display: flex; flex-direction: column; gap: 6px; }
.form-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.form-input {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 16px;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  color: var(--text);
  outline: none;
  transition: border-color 0.2s;
}
.form-input::placeholder { color: var(--text-dim); }
.form-input:focus { border-color: var(--border-teal); }
.form-error {
  font-size: 0.82rem;
  color: #ff6b6b;
  background: rgba(255,107,107,0.08);
  border: 1px solid rgba(255,107,107,0.2);
  border-radius: 8px;
  padding: 10px 14px;
}
.form-submit {
  background: var(--accent-teal);
  color: #060912;
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  padding: 16px 24px;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s, opacity 0.2s;
  box-shadow: 0 0 32px rgba(0,229,184,0.2);
  margin-top: 4px;
}
.form-submit:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 0 48px rgba(0,229,184,0.35); }
.form-submit:disabled { opacity: 0.6; cursor: not-allowed; }
.form-disclaimer { font-size: 0.72rem; color: var(--text-dim); text-align: center; }

/* Success state */
.audit-success { text-align: center; padding: 20px 0; }
.success-icon {
  width: 64px;
  height: 64px;
  background: rgba(0,229,184,0.1);
  border: 2px solid var(--accent-teal);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  color: var(--accent-teal);
  margin: 0 auto 20px;
}
.audit-success h3 { font-size: 1.5rem; font-weight: 800; color: var(--text); margin-bottom: 12px; }
.audit-success p { font-size: 0.9rem; color: var(--text-muted); line-height: 1.6; }

/* ---- Audit responsive ---- */
@media (max-width: 900px) {
  .audit { padding: 64px 24px; }
  .audit-layout { grid-template-columns: 1fr; }
  .audit-results { position: static; }
  .audit-controls { padding: 28px; }
  .audit-results-inner { padding: 28px; }
  .audit-modal { padding: 32px 24px; }
  .form-row { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .industry-grid { grid-template-columns: repeat(2, 1fr); }
  .hero-actions { flex-direction: column; align-items: flex-start; gap: 12px; }
  .audit-metrics { flex-direction: column; gap: 16px; }
  .audit-metric-sep { display: none; }
  .audit-metric { padding: 0; }
}
