/* ============================================================
   index.css — Landing page (index.html) specific styles
   ============================================================ */

/* ── Hero ── */
.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 65px);
  padding: 60px 20px;
  text-align: center;
}

.hero h1 {
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 20px;
  max-width: 700px;
}

.hero h1 span {
  color: var(--primary);
}

.hero p {
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 520px;
  line-height: 1.7;
  margin-bottom: 36px;
}

/* ── CTA button ── */
.cta-btn {
  display: inline-block;
  padding: 14px 32px;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  margin-bottom: 40px;
  font-family: inherit;
}

.cta-btn:hover {
  background: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(233, 30, 99, 0.4);
}

/* ── URL input bar ── */
.url-bar {
  display: flex;
  width: 100%;
  max-width: 580px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  overflow: hidden;
}

.url-bar input {
  flex: 1;
  padding: 14px 18px;
  background: transparent;
  border: none;
  color: var(--text);
  font-size: 0.95rem;
  outline: none;
  font-family: inherit;
}

.url-bar input::placeholder {
  color: var(--muted);
}

.url-bar button {
  padding: 14px 24px;
  background: var(--primary);
  color: white;
  border: none;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s;
  white-space: nowrap;
  font-family: inherit;
}

.url-bar button:hover {
  background: var(--primary-hover);
}

.url-error {
  color: var(--field-err);
  font-size: 0.85rem;
  margin-top: 8px;
}

.error-box {
  max-width: 580px;
  width: 100%;
}

/* ── Lead capture modal ── */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-overlay.open {
  display: flex;
}

.modal {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 36px;
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  animation: slideUp 0.25s ease;
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: none;
  border: none;
  color: var(--muted);
  font-size: 1.4rem;
  cursor: pointer;
  line-height: 1;
  padding: 4px 8px;
  border-radius: 4px;
  transition: color 0.2s;
}

.modal-close:hover {
  color: var(--text);
}

.modal h2 {
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.modal-subtitle {
  color: var(--muted);
  font-size: 0.9rem;
  margin-bottom: 24px;
}

.modal-subtitle strong {
  color: var(--primary);
}

.modal-submit {
  width: 100%;
  padding: 13px;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  margin-top: 8px;
  transition: all 0.2s;
  font-family: inherit;
}

.modal-submit:hover {
  background: var(--primary-hover);
}

/* ── Loader screen ── */
.loader-screen {
  display: none;
  position: fixed;
  inset: 0;
  background: var(--bg);
  z-index: 2000;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
}

.loader-screen.open {
  display: flex;
}

.loader-screen .spinner {
  width: 64px;
  height: 64px;
  border-width: 5px;
}

.loader-title {
  font-size: 1.3rem;
  font-weight: 700;
}

.loader-status {
  color: var(--muted);
  font-size: 0.95rem;
}

.loader-screen .progress-bar {
  width: 320px;
}

/* ── Result screen ── */
.result-screen {
  display: none;
  position: fixed;
  inset: 0;
  background: var(--bg);
  z-index: 2000;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  text-align: center;
  padding: 20px;
}

.result-screen.open {
  display: flex;
}

.result-icon {
  font-size: 3.5rem;
}
.result-title {
  font-size: 1.6rem;
  font-weight: 800;
}
.result-desc {
  color: var(--muted);
  max-width: 400px;
}

.result-actions {
  display: flex;
  gap: 12px;
  margin-top: 8px;
  flex-wrap: wrap;
  justify-content: center;
}

/* ── Responsive ── */
@media (max-width: 600px) {
  .modal {
    padding: 24px;
  }
  .loader-screen .progress-bar {
    width: 260px;
  }
}

/* ── Agent tiles (loader) ── */
.agent-tiles {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
  margin: 20px 0 8px;
  max-width: 480px;
}

.agent-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 14px;
  min-width: 72px;
  transition: all 0.3s;
}

.agent-tile.running {
  border-color: var(--primary);
  background: rgba(233, 30, 99, 0.08);
}

.agent-tile.done {
  border-color: #22c55e;
  background: rgba(34, 197, 94, 0.08);
}

.agent-tile-icon {
  font-size: 1.3rem;
}

.agent-tile-name {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--muted);
}

.agent-tile-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.agent-tile-dot.waiting {
  background: rgba(255, 255, 255, 0.2);
}

.agent-tile-dot.running {
  background: var(--primary);
  animation: pulse-dot 1s infinite;
}

.agent-tile-dot.done {
  background: #22c55e;
}

@keyframes pulse-dot {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.5;
    transform: scale(0.8);
  }
}
