@import url("https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@300;400;500;600;700&display=swap");

* {
  font-family: "Space Grotesk", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --background: 245 247 250;
  --foreground: 20 23 30;
  --card: 255 255 255;
  --card-foreground: 20 23 30;
  --primary: 14 165 233;
  --primary-foreground: 255 255 255;
  --secondary: 234 236 240;
  --secondary-foreground: 20 23 30;
  --muted: 234 236 240;
  --muted-foreground: 100 116 139;
  --accent: 14 165 233;
  --destructive: 220 38 38;
  --destructive-foreground: 255 255 255;
  --border: 222 226 230;
  --radius: 0.75rem;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: rgb(var(--background));
  color: rgb(var(--foreground));
  line-height: 1.5;
  min-height: 100vh;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1.5rem;
}

.header {
  background-color: rgb(var(--card));
  border: 1px solid rgb(var(--border));
  border-radius: var(--radius);
  padding: 3rem 2rem;
  text-align: center;
  margin-bottom: 2rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.header h1 {
  font-size: 3rem;
  font-weight: 700;
  color: rgb(var(--primary));
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
}

.header p {
  font-size: 1.125rem;
  color: rgb(var(--muted-foreground));
  margin-bottom: 1.5rem;
}

.search-container {
  max-width: 600px;
  margin: 2rem auto;
}

.search-box {
  background-color: rgb(var(--card));
  border: 2px solid rgb(var(--border));
  border-radius: var(--radius);
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  transition: all 0.2s ease;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.search-box:focus-within {
  border-color: rgb(var(--primary));
  box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.1);
}

.search-icon {
  color: rgb(var(--muted-foreground));
  font-size: 1.5rem;
}

.search-input {
  flex: 1;
  border: none;
  outline: none;
  font-size: 1rem;
  background: transparent;
  color: rgb(var(--foreground));
}

.search-input::placeholder {
  color: rgb(var(--muted-foreground));
}

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.stat-card {
  background-color: rgb(var(--card));
  border: 1px solid rgb(var(--border));
  padding: 1.5rem;
  border-radius: var(--radius);
  text-align: center;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.stat-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.stat-number {
  font-size: 2.5rem;
  font-weight: 700;
  color: rgb(var(--primary));
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.stat-label {
  color: rgb(var(--muted-foreground));
  font-size: 0.875rem;
  font-weight: 500;
}

.sites-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.site-card {
  background-color: rgb(var(--card));
  border: 1px solid rgb(var(--border));
  border-radius: var(--radius);
  padding: 1.5rem;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.site-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background-color: rgb(var(--primary));
  border-radius: var(--radius) var(--radius) 0 0;
}

.site-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.site-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1rem;
  gap: 1rem;
}

.site-info {
  flex: 1;
}

.site-name {
  font-size: 1.125rem;
  font-weight: 600;
  color: rgb(var(--foreground));
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.25rem;
}

.site-domain {
  font-size: 0.875rem;
  color: rgb(var(--muted-foreground));
}

.site-rating {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background-color: #fef3c7;
  padding: 0.5rem 0.75rem;
  border-radius: 9999px;
  border: 1px solid #fcd34d;
  white-space: nowrap;
}

.stars {
  color: #f59e0b;
  font-size: 0.875rem;
  display: flex;
  gap: 2px;
}

.rating-number {
  font-weight: 600;
  color: #92400e;
  font-size: 0.875rem;
}

.site-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}

.stat-item {
  text-align: center;
  padding: 1rem;
  background-color: rgb(var(--secondary));
  border-radius: var(--radius);
}

.stat-item-number {
  font-size: 1.5rem;
  font-weight: 700;
  color: rgb(var(--primary));
  margin-bottom: 0.25rem;
}

.stat-item-label {
  color: rgb(var(--muted-foreground));
  font-size: 0.75rem;
  font-weight: 500;
}

.site-actions {
  display: flex;
  gap: 0.75rem;
}

.btn {
  padding: 0.75rem 1.25rem;
  border: none;
  border-radius: var(--radius);
  text-decoration: none;
  font-weight: 500;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  flex: 1;
  font-size: 0.875rem;
}

.btn-primary {
  background-color: rgb(var(--primary));
  color: rgb(var(--primary-foreground));
}

.btn-primary:hover {
  opacity: 0.9;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(14, 165, 233, 0.3);
}

.btn-secondary {
  background-color: rgb(var(--secondary));
  color: rgb(var(--secondary-foreground));
}

.btn-secondary:hover {
  background-color: rgb(var(--muted));
}

.empty-state {
  text-align: center;
  padding: 4rem 2rem;
  background-color: rgb(var(--card));
  border: 1px solid rgb(var(--border));
  border-radius: var(--radius);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.empty-state i {
  font-size: 4rem;
  color: rgb(var(--muted-foreground));
  margin-bottom: 1.5rem;
}

.empty-state h3 {
  color: rgb(var(--foreground));
  margin-bottom: 1rem;
  font-weight: 600;
}

.empty-state p {
  color: rgb(var(--muted-foreground));
  margin-bottom: 1rem;
}

.footer {
  background-color: rgb(var(--card));
  border-top: 1px solid rgb(var(--border));
  color: rgb(var(--muted-foreground));
  text-align: center;
  padding: 1.5rem 0;
  margin-top: 3rem;
  box-shadow: 0 -1px 3px rgba(0, 0, 0, 0.05);
}

.footer-links {
  margin-top: 0.5rem;
  display: flex;
  justify-content: center;
  gap: 1.2rem;
  flex-wrap: wrap;
}

.footer-links a {
  color: rgb(var(--muted-foreground));
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: rgb(var(--foreground));
}

.footer p {
  font-size: 0.875rem;
}

.loading {
  text-align: center;
  padding: 2rem;
}

.loading i {
  font-size: 2rem;
  color: rgb(var(--primary));
  animation: spin 1s linear infinite;
}

@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

@media (max-width: 768px) {
  .container {
    padding: 1rem;
  }

  .header {
    padding: 2rem 1.5rem;
  }

  .header h1 {
    font-size: 2rem;
  }

  .header p {
    font-size: 1rem;
  }

  .sites-grid {
    grid-template-columns: 1fr;
  }

  .stats {
    grid-template-columns: repeat(2, 1fr);
  }
}