/* =========================================
   LEADSMITH — /demo page styles
   Dark glassmorphism, neon accents, staggered reveal
   ========================================= */

/* ── Hero ────────────────────────────────── */
.dhero {
  position: relative;
  min-height: 68vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 80px 24px 60px;
}

.dhero-orbs { position: absolute; inset: 0; pointer-events: none; }
.dorb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.35;
}
.dorb-1 {
  width: 600px; height: 600px;
  background: radial-gradient(circle, #3b82f6 0%, transparent 70%);
  top: -200px; left: -150px;
}
.dorb-2 {
  width: 400px; height: 400px;
  background: radial-gradient(circle, #c8f526 0%, transparent 70%);
  bottom: -100px; right: -50px;
  opacity: 0.15;
}
.dorb-3 {
  width: 300px; height: 300px;
  background: radial-gradient(circle, #8b5cf6 0%, transparent 70%);
  top: 40%; right: 20%;
  opacity: 0.2;
}

.dhero-grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
  background-size: 48px 48px;
}

.dhero-inner {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 720px;
  width: 100%;
}

.dhero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--lime, #c8f526);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 20px;
}
.dhero-dot {
  width: 8px; height: 8px;
  background: var(--lime, #c8f526);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--lime, #c8f526);
  animation: logo-pulse 2s ease-in-out infinite;
}
@keyframes logo-pulse {
  0%,100% { box-shadow: 0 0 8px rgba(200,245,38,0.6); }
  50%      { box-shadow: 0 0 16px rgba(200,245,38,0.9), 0 0 24px rgba(200,245,38,0.3); }
}

.dhero-headline {
  font-size: clamp(36px, 6vw, 64px);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: #fff;
  margin-bottom: 18px;
}

.dhero-sub {
  font-size: 17px;
  line-height: 1.7;
  color: rgba(255,255,255,0.65);
  max-width: 560px;
  margin: 0 auto 40px;
}

/* ── Scan form ─────────────────────────────── */
.dscan-form {
  display: flex;
  gap: 12px;
  max-width: 560px;
  margin: 0 auto 14px;
}

.dscan-input-wrap {
  position: relative;
  flex: 1;
}

.dscan-icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: rgba(255,255,255,0.4);
  pointer-events: none;
}

.dscan-input {
  width: 100%;
  padding: 14px 16px 14px 46px;
  background: rgba(255,255,255,0.07);
  border: 1.5px solid rgba(255,255,255,0.12);
  border-radius: 12px;
  color: #fff;
  font-size: 16px;
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  letter-spacing: 0.02em;
  outline: none;
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
  -webkit-appearance: none;
}
.dscan-input::placeholder { color: rgba(255,255,255,0.35); font-weight: 400; }
.dscan-input:focus {
  border-color: rgba(59,130,246,0.7);
  background: rgba(255,255,255,0.09);
  box-shadow: 0 0 0 3px rgba(59,130,246,0.15);
}

/* Neon scan button */
.dscan-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  background: #3b82f6;
  color: #fff;
  border: none;
  border-radius: 12px;
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  position: relative;
  box-shadow: 0 0 20px rgba(59,130,246,0.5), 0 0 40px rgba(59,130,246,0.2);
  transition: background 0.2s, box-shadow 0.2s, transform 0.15s;
  min-width: 148px;
  animation: scan-pulse 2.5s ease-in-out infinite;
}
@keyframes scan-pulse {
  0%,100% { box-shadow: 0 0 20px rgba(59,130,246,0.5), 0 0 40px rgba(59,130,246,0.2); }
  50%      { box-shadow: 0 0 30px rgba(59,130,246,0.7), 0 0 60px rgba(59,130,246,0.35); }
}
.dscan-btn:hover:not(:disabled) {
  background: #2563eb;
  box-shadow: 0 0 30px rgba(59,130,246,0.7), 0 0 60px rgba(59,130,246,0.4);
  transform: translateY(-1px);
  animation: none;
}
.dscan-btn:active:not(:disabled) { transform: scale(0.97); }
.dscan-btn:disabled { opacity: 0.7; cursor: not-allowed; animation: none; }

.dscan-btn-spinner {
  display: none;
  width: 16px; height: 16px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: idemo-spin 0.7s linear infinite;
}
@keyframes idemo-spin { to { transform: rotate(360deg); } }
.dscan-btn.is-loading .dscan-btn-spinner { display: block; }
.dscan-btn.is-loading .dscan-btn-text { display: none; }

.dscan-hint {
  font-size: 13px;
  color: rgba(255,255,255,0.35);
}

.dscan-hint a { color: rgba(255,255,255,0.5); }

/* ── Rate limit message ─────────────────────── */
.dlimit-msg {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 24px;
  background: rgba(245,158,11,0.12);
  border: 1px solid rgba(245,158,11,0.3);
  border-radius: 12px;
  color: #f59e0b;
  font-size: 14px;
  font-weight: 500;
  max-width: 560px;
  margin: 0 auto 24px;
}
.dlimit-msg a { color: #f59e0b; font-weight: 700; }

/* ── Loading skeleton ───────────────────────── */
.dskeleton-wrap {
  display: none;
  max-width: 900px;
  margin: 0 auto;
  padding: 0 24px 40px;
}
.dskeleton-inner { display: flex; flex-direction: column; gap: 20px; }
.dskeleton-strip {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 12px;
}
.dskeleton-label {
  height: 14px; width: 180px;
  background: rgba(255,255,255,0.08);
  border-radius: 4px;
  animation: skel-shimmer 1.5s ease-in-out infinite;
}
.dskeleton-val {
  height: 14px; width: 80px;
  background: rgba(255,255,255,0.05);
  border-radius: 4px;
  animation: skel-shimmer 1.5s ease-in-out infinite 0.2s;
}
@keyframes skel-shimmer {
  0%,100% { opacity: 0.5; }
  50%      { opacity: 1; }
}
.dskeleton-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
}
.dskeleton-card {
  height: 160px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 16px;
  animation: skel-shimmer 1.5s ease-in-out infinite;
}

/* ── Results ───────────────────────────────── */
.dresults-wrap {
  display: none;
  max-width: 960px;
  margin: 0 auto;
  padding: 0 24px 60px;
}

/* Stat strip */
.dstat-strip {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  padding: 18px 24px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 16px;
  margin-bottom: 24px;
  backdrop-filter: blur(12px);
}
.dstat-count {
  font-size: 40px;
  font-weight: 800;
  color: var(--lime, #c8f526);
  line-height: 1;
}
.dstat-text {
  font-size: 18px;
  font-weight: 600;
  color: rgba(255,255,255,0.9);
}
.dstat-postcode {
  font-size: 18px;
  color: rgba(255,255,255,0.5);
}
.dstat-time {
  font-size: 16px;
  color: rgba(255,255,255,0.35);
  margin-left: auto;
}
.dstat-cta { margin-left: 16px; }
.dstat-cta-link {
  font-size: 14px;
  font-weight: 600;
  color: #3b82f6;
  white-space: nowrap;
}

/* Cards grid */
.dcards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

/* Record card */
.dcard {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 16px;
  padding: 20px;
  opacity: 0;
  transform: translateY(20px);
  transition: background 0.2s, border-color 0.2s, box-shadow 0.2s;
}
.dcard.visible {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.5s var(--ease-out-expo, ease), transform 0.5s var(--ease-out-expo, ease);
}
.dcard:hover {
  background: rgba(255,255,255,0.08);
  border-color: rgba(255,255,255,0.18);
  box-shadow: 0 8px 32px rgba(0,0,0,0.3);
}

.dcard-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}
.dcard-addr {
  font-size: 14px;
  font-weight: 500;
  color: rgba(255,255,255,0.85);
  line-height: 1.5;
}

.dscore-badge {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 8px 12px;
  border: 1px solid;
  border-radius: 10px;
  min-width: 56px;
}
.dscore-num {
  font-size: 20px;
  font-weight: 800;
  line-height: 1;
}
.dscore-label {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  opacity: 0.8;
  margin-top: 3px;
}

/* Signal chips */
.dcard-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
}
.dsig-chip {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
  color: rgba(255,255,255,0.7);
  letter-spacing: 0.02em;
}

/* Reason list */
.dreason-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.dreason-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: rgba(255,255,255,0.5);
  line-height: 1.4;
}
.dreason-dot {
  flex-shrink: 0;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: rgba(255,255,255,0.3);
}
.dreason-pts {
  font-weight: 700;
  color: rgba(255,255,255,0.4);
  margin-left: auto;
}

.dcard-ref {
  margin-top: 10px;
  font-size: 11px;
  color: rgba(255,255,255,0.25);
}

/* Fallback message */
.dfallback-msg {
  display: none;
  text-align: center;
  padding: 40px 24px;
  color: rgba(255,255,255,0.5);
  font-size: 16px;
  line-height: 1.6;
}

/* ── How it works ──────────────────────────── */
.dhow-wrap {
  padding: 80px 24px;
  border-top: 1px solid rgba(255,255,255,0.06);
}
.dhow-inner {
  max-width: 860px;
  margin: 0 auto;
}
.dhow-title {
  font-size: 32px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #fff;
  margin-bottom: 10px;
  text-align: center;
}
.dhow-sub {
  font-size: 16px;
  color: rgba(255,255,255,0.5);
  text-align: center;
  margin-bottom: 40px;
}
.dhow-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 20px;
  margin-bottom: 28px;
}
.dhow-card {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 16px;
  padding: 24px;
  opacity: 0;
  transform: translateY(16px);
}
.dhow-card.visible {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.dhow-card-icon {
  width: 48px; height: 48px;
  background: rgba(59,130,246,0.15);
  border: 1px solid rgba(59,130,246,0.25);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #3b82f6;
  margin-bottom: 16px;
}
.dhow-card-title {
  font-size: 16px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 8px;
}
.dhow-card-desc {
  font-size: 14px;
  color: rgba(255,255,255,0.5);
  line-height: 1.6;
  margin-bottom: 12px;
}
.dhow-card-desc a { color: #3b82f6; }
.dhow-tag {
  display: inline-block;
  padding: 3px 10px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
  color: rgba(255,255,255,0.5);
  letter-spacing: 0.03em;
}
.dhow-privacy {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 12px;
  color: rgba(255,255,255,0.3);
  text-align: center;
}

/* ── Footer ─────────────────────────────────── */
.dftr {
  border-top: 1px solid rgba(255,255,255,0.06);
  padding: 32px 24px;
}
.dftr-inner {
  max-width: 860px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}
.dftr-logo {
  font-size: 16px;
  font-weight: 800;
  color: #fff;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 8px;
}
.dftr-logo .nav-logo-dot {
  width: 8px; height: 8px;
  background: var(--lime, #c8f526);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--lime, #c8f526);
}
.dftr-links {
  display: flex;
  gap: 16px;
  margin-left: auto;
}
.dftr-links a {
  font-size: 13px;
  color: rgba(255,255,255,0.4);
  text-decoration: none;
}
.dftr-links a:hover { color: rgba(255,255,255,0.7); }
.dftr-copy {
  width: 100%;
  font-size: 12px;
  color: rgba(255,255,255,0.25);
  text-align: center;
  margin-top: 8px;
}

/* ── Email capture ──────────────────────────── */
.dcapture-wrap {
  max-width: 700px;
  margin: 40px auto 0;
  padding: 0 24px 60px;
}
.dcapture-card {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 20px;
  padding: 40px 40px 36px;
  text-align: center;
}
.dcapture-badge {
  display: inline-block;
  background: rgba(200,245,38,0.15);
  border: 1px solid rgba(200,245,38,0.3);
  color: #c8f526;
  font-size: 12px;
  font-weight: 700;
  padding: 5px 14px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 20px;
}
.dcapture-title {
  font-size: 22px;
  font-weight: 800;
  color: #fff;
  line-height: 1.35;
  margin: 0 0 12px;
}
.dcapture-title strong { color: #c8f526; }
.dcapture-sub {
  font-size: 14px;
  color: rgba(255,255,255,0.5);
  margin: 0 0 28px;
  line-height: 1.5;
}
.dcapture-form {
  display: flex;
  gap: 12px;
  max-width: 460px;
  margin: 0 auto;
}
.dcapture-input {
  flex: 1;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 10px;
  padding: 13px 18px;
  font-size: 15px;
  color: #fff;
  outline: none;
  transition: border-color 0.2s, background 0.2s;
  min-width: 0;
}
.dcapture-input::placeholder { color: rgba(255,255,255,0.35); }
.dcapture-input:focus {
  border-color: #c8f526;
  background: rgba(255,255,255,0.1);
}
.dcapture-btn {
  background: #c8f526;
  color: #0a2540;
  border: none;
  border-radius: 10px;
  padding: 13px 22px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  transition: opacity 0.2s;
  position: relative;
}
.dcapture-btn:hover { opacity: 0.88; }
.dcapture-btn:disabled { opacity: 0.5; cursor: not-allowed; }
.dcapture-btn-spinner {
  display: none;
  width: 16px; height: 16px;
  border: 2px solid rgba(10,37,64,0.3);
  border-top-color: #0a2540;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}
.dcapture-btn.is-loading .dcapture-btn-spinner { display: block; }
.dcapture-btn.is-loading .dcapture-btn-text { display: none; }
.dcapture-legal {
  margin: 16px 0 0;
  font-size: 12px;
  color: rgba(255,255,255,0.3);
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Capture confirmation */
.dcapture-confirm {
  max-width: 700px;
  margin: 40px auto 0;
  padding: 0 24px 60px;
}
.dcapture-confirm-inner {
  background: rgba(16,185,129,0.08);
  border: 1px solid rgba(16,185,129,0.25);
  border-radius: 20px;
  padding: 40px 40px 36px;
  text-align: center;
}
.dcapture-confirm-icon {
  width: 56px; height: 56px;
  background: rgba(16,185,129,0.15);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
}
.dcapture-confirm-title {
  font-size: 22px;
  font-weight: 800;
  color: #fff;
  margin: 0 0 8px;
}
.dcapture-confirm-sub {
  font-size: 15px;
  color: rgba(255,255,255,0.6);
  margin: 0 0 24px;
}
.dcapture-confirm-cta {
  display: inline-block;
  background: #c8f526;
  color: #0a2540;
  padding: 14px 32px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
  transition: opacity 0.2s;
}
.dcapture-confirm-cta:hover { opacity: 0.88; }

/* Capture error */
.dcapture-error {
  display: none;
  margin: 8px auto 0;
  max-width: 460px;
  font-size: 13px;
  color: #f87171;
  text-align: center;
}
.dcapture-error.visible { display: block; }

/* ── Responsive ─────────────────────────────── */
@media (max-width: 640px) {
  .dscan-form { flex-direction: column; }
  .dscan-btn { width: 100%; min-width: unset; }
  .dstat-strip { flex-direction: column; align-items: flex-start; }
  .dstat-time, .dstat-cta { margin-left: 0; }
  .dcards-grid { grid-template-columns: 1fr; }
  .dhow-cards { grid-template-columns: 1fr; }
  .dftr-inner { flex-direction: column; align-items: flex-start; }
  .dftr-links { margin-left: 0; }
  .dcapture-form { flex-direction: column; }
  .dcapture-btn { width: 100%; justify-content: center; }
  .dcapture-card, .dcapture-confirm-inner { padding: 28px 24px 24px; }
}