/* ============================================================
   HOME.CSS — index.html only
   ============================================================ */

/* ---- Hero ---- */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

.hero {
  border-bottom: 1px solid var(--border);
  padding: 72px var(--spacing-md) 64px;
  background-color: var(--bg-primary);
  background-image: radial-gradient(circle, var(--border) 1px, transparent 1px);
  background-size: 28px 28px;
  position: relative;
}

/* Fade the dot grid out at the bottom */
.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 40%, var(--bg-primary) 100%);
  pointer-events: none;
}

.hero-inner {
  max-width: 620px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.hero-eyebrow {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
  animation: fadeUp 0.5s ease both;
}

.hero-title {
  font-size: 2.5rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text-primary);
  margin-bottom: 20px;
  line-height: 1.1;
  animation: fadeUp 0.5s 0.1s ease both;
}

.hero-title span {
  position: relative;
  color: var(--accent);
  white-space: nowrap;
}

.hero-title span::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -3px;
  width: 100%;
  height: 3px;
  background: var(--accent);
  border-radius: 2px;
  opacity: 0.35;
}

.hero-tagline {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 28px;
  max-width: 50ch;
  animation: fadeUp 0.5s 0.2s ease both;
}

.hero-stats {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 36px;
  font-size: 0.8125rem;
  color: var(--text-secondary);
  font-weight: 500;
  animation: fadeUp 0.5s 0.3s ease both;
}

.hero-stat-dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background-color: var(--text-secondary);
  opacity: 0.35;
  flex-shrink: 0;
}

.search-wrapper {
  position: relative;
  max-width: 480px;
  animation: fadeUp 0.5s 0.4s ease both;
}

#tool-search {
  width: 100%;
  padding: 0.8125rem 1rem 0.8125rem 2.75rem;
  font-size: 0.9375rem;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-lg);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  transition: border-color var(--transition), box-shadow var(--transition);
  min-height: 50px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}

#tool-search:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(37,99,235,0.12);
}

.search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-secondary);
  pointer-events: none;
}

@media (min-width: 768px) {
  .hero { padding: 96px var(--spacing-md) 88px; }
  .hero-title { font-size: 3.25rem; }
}

@media (prefers-reduced-motion: reduce) {
  .hero-eyebrow,
  .hero-title,
  .hero-tagline,
  .hero-stats,
  .search-wrapper { animation: none; }
}

/* ---- Tools Grid ---- */
.tools-section {
  max-width: 1200px;
  margin: 0 auto;
  padding: var(--spacing-xl) var(--spacing-md);
}
.section-heading {
  text-align: center;
  margin-bottom: var(--spacing-xl);
}
.section-heading h2 { color: var(--text-primary); }
.section-heading p  { color: var(--text-secondary); max-width: 52ch; margin: 0 auto; }

.tools-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--spacing-md);
}
@media (min-width: 480px) { .tools-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 768px) { .tools-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1024px){ .tools-grid { grid-template-columns: repeat(3, 1fr); gap: var(--spacing-lg); } }

.tool-card-home {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  transition: border-color var(--transition), box-shadow var(--transition), transform 0.15s ease;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 180px;
}
.tool-card-home:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}
.tool-card-home:hover .tool-card-icon {
  background-color: var(--accent);
  border-color: var(--accent);
  color: #fff;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}
.tool-card-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius);
  background-color: var(--bg-primary);
  border: 1px solid var(--border);
  color: var(--accent);
  flex-shrink: 0;
}
.tool-card-name {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
}
.tool-card-desc {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin: 0;
  line-height: 1.6;
}
.tool-card-arrow {
  margin-top: auto;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--accent);
  opacity: 0;
  transform: translateX(-4px);
  transition: opacity 0.15s ease, transform 0.15s ease;
}
.tool-card-home:hover .tool-card-arrow {
  opacity: 1;
  transform: translateX(0);
}
#no-results {
  display: none;
  text-align: center;
  padding: var(--spacing-xl);
  color: var(--text-secondary);
  grid-column: 1 / -1;
}

/* ---- Ad strip ---- */
.home-ad {
  max-width: 1200px;
  margin: 0 auto var(--spacing-xl);
  padding: 0 var(--spacing-md);
}
