@import url('/static/shared/new-api-tokens.css');

@keyframes landing-fade-up {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.landing-animate-fade-up {
  animation: landing-fade-up 0.6s cubic-bezier(0.16, 1, 0.3, 1) both;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body.site-body {
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 1.5;
  background: var(--background);
  color: var(--foreground);
  min-height: 100svh;
  overflow-x: clip;
}

/* —— Public header (mirrors PublicHeader) —— */
.site-header-shell {
  pointer-events: none;
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
}

.site-header-inner-wrap {
  pointer-events: auto;
  margin: 0 auto;
  transition: max-width 0.7s cubic-bezier(0.16, 1, 0.3, 1),
    padding 0.7s cubic-bezier(0.16, 1, 0.3, 1);
  max-width: 80rem;
  padding: 0 1rem;
}

.site-header-shell.is-scrolled .site-header-inner-wrap {
  max-width: 52rem;
  padding: 0.75rem 0.75rem 0;
}

.site-header-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  height: 4rem;
  padding: 0 0.5rem;
  transition: height 0.7s cubic-bezier(0.16, 1, 0.3, 1),
    border-radius 0.7s cubic-bezier(0.16, 1, 0.3, 1),
    background 0.7s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.site-header-shell.is-scrolled .site-header-nav {
  height: 3rem;
  padding: 0 0.375rem 0 1rem;
  border-radius: 1rem;
  background: color-mix(in oklch, var(--background) 60%, transparent);
  backdrop-filter: blur(24px);
  box-shadow: 0 2px 16px -6px rgba(0, 0, 0, 0.08), 0 0 0 0.5px rgba(0, 0, 0, 0.02);
  border: 0.5px solid color-mix(in oklch, var(--border) 50%, transparent);
}

html.dark .site-header-shell.is-scrolled .site-header-nav {
  box-shadow: 0 2px 16px -6px rgba(0, 0, 0, 0.4);
}

.site-brand {
  display: flex;
  min-width: 0;
  flex: 1;
  align-items: center;
  gap: 0.625rem;
  text-decoration: none;
  color: inherit;
}

.site-brand-mark {
  width: 1.75rem;
  height: 1.75rem;
  border-radius: 0.5rem;
  background: linear-gradient(135deg, oklch(0.72 0.18 250), oklch(0.65 0.15 280));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  transition: transform 0.3s;
}

.site-brand:hover .site-brand-mark {
  transform: scale(1.05);
}

.site-brand-name {
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  max-width: 12rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.site-nav-desktop {
  display: none;
  align-items: center;
  gap: 0.125rem;
}

@media (min-width: 1024px) {
  .site-nav-desktop {
    display: flex;
  }
}

.site-nav-desktop a {
  text-decoration: none;
  color: var(--muted-foreground);
  font-size: 0.875rem;
  font-weight: 500;
  padding: 0.375rem 0.75rem;
  border-radius: 0.5rem;
  transition: color 0.2s;
}

.site-nav-desktop a:hover,
.site-nav-desktop a.active {
  color: var(--foreground);
}

.site-header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.site-header-divider {
  width: 1px;
  height: 1rem;
  background: color-mix(in oklch, var(--border) 40%, transparent);
  margin: 0 0.25rem;
}

.site-icon-btn {
  width: 2rem;
  height: 2rem;
  border-radius: 0.5rem;
  border: none;
  background: transparent;
  color: var(--muted-foreground);
  cursor: pointer;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.site-icon-btn:hover {
  color: var(--foreground);
  background: var(--muted);
}

.site-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  height: 2rem;
  padding: 0 0.875rem;
  border-radius: 0.5rem;
  font-size: 0.75rem;
  font-weight: 500;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.site-btn.primary {
  background: var(--primary);
  color: var(--primary-foreground);
}

.site-btn.primary:hover {
  filter: brightness(1.05);
}

.site-btn.outline {
  border-color: color-mix(in oklch, var(--border) 50%, transparent);
  color: var(--foreground);
  background: transparent;
}

.site-btn.outline:hover {
  background: color-mix(in oklch, var(--muted) 50%, transparent);
  border-color: var(--border);
}

.site-btn.lg {
  height: 2.75rem;
  padding: 0 1.25rem;
  font-size: 0.875rem;
  border-radius: 0.5rem;
}

/* —— Hero (mirrors home Hero section) —— */
.site-main {
  position: relative;
  z-index: 10;
}

.hero-section {
  position: relative;
  overflow: hidden;
  padding: 6rem 1.5rem 4rem;
}

@media (min-width: 768px) {
  .hero-section {
    padding-top: 8rem;
    padding-bottom: 6rem;
  }
}

.hero-bg-radial {
  pointer-events: none;
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: 0.25;
  background: radial-gradient(ellipse 60% 50% at 20% 20%, oklch(0.72 0.18 250 / 80%) 0%, transparent 70%),
    radial-gradient(ellipse 50% 40% at 80% 15%, oklch(0.65 0.15 200 / 60%) 0%, transparent 70%),
    radial-gradient(ellipse 40% 35% at 40% 80%, oklch(0.7 0.12 280 / 40%) 0%, transparent 70%);
}

html.dark .hero-bg-radial {
  opacity: 0.12;
}

.hero-bg-grid {
  pointer-events: none;
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: 0.08;
  background-image: linear-gradient(to right, var(--border) 1px, transparent 1px),
    linear-gradient(to bottom, var(--border) 1px, transparent 1px);
  background-size: 4rem 4rem;
  mask-image: radial-gradient(ellipse 60% 50% at 50% 30%, black 20%, transparent 100%);
}

.hero-inner {
  max-width: 72rem;
  margin: 0 auto;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  margin-bottom: 1.25rem;
  padding: 0.375rem 0.75rem;
  border-radius: 9999px;
  border: 1px solid color-mix(in oklch, var(--primary) 20%, transparent);
  background: color-mix(in oklch, var(--primary) 5%, transparent);
  font-size: 11px;
  font-weight: 500;
  color: oklch(0.52 0.14 250);
}

html.dark .hero-pill {
  color: oklch(0.72 0.12 250);
}

.hero-pill-dot {
  position: relative;
  width: 0.375rem;
  height: 0.375rem;
  border-radius: 9999px;
  background: oklch(0.62 0.16 250);
}

.hero h1 {
  font-size: clamp(2.25rem, 4.5vw, 3.25rem);
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.hero h1 .gradient {
  background: linear-gradient(to right, #60a5fa, #a78bfa, #a855f7);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-lead {
  margin-top: 1.25rem;
  max-width: 36rem;
  font-size: 1rem;
  line-height: 1.625;
  color: color-mix(in oklch, var(--muted-foreground) 80%, transparent);
}

@media (min-width: 768px) {
  .hero-lead {
    font-size: 15px;
  }
}

.hero-actions {
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* —— Content sections —— */
.site-container {
  max-width: 72rem;
  margin: 0 auto;
  padding: 0 1.5rem 4rem;
}

.section-title {
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-bottom: 1.25rem;
}

.feature-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
}

@media (min-width: 768px) {
  .feature-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.feature-card {
  border: 1px solid color-mix(in oklch, var(--border) 50%, transparent);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  background: color-mix(in oklch, var(--muted) 15%, var(--background));
}

.feature-card h3 {
  font-size: 0.9375rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.feature-card p {
  font-size: 0.875rem;
  color: var(--muted-foreground);
  line-height: 1.6;
}

.stats-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
  margin-bottom: 3rem;
}

@media (min-width: 768px) {
  .stats-row {
    grid-template-columns: repeat(4, 1fr);
  }
}

.stat-card {
  border: 1px solid color-mix(in oklch, var(--border) 50%, transparent);
  border-radius: calc(var(--radius) * 0.8);
  padding: 1rem 1.25rem;
  background: var(--card);
}

.stat-card strong {
  display: block;
  font-size: 1.125rem;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.stat-card span {
  font-size: 0.75rem;
  color: var(--muted-foreground);
}

.site-footer {
  border-top: 1px solid var(--border);
  padding: 2rem 1.5rem;
  text-align: center;
  font-size: 0.8125rem;
  color: var(--muted-foreground);
}

.site-footer a {
  color: var(--foreground);
  text-decoration: none;
}

.site-footer a:hover {
  text-decoration: underline;
}

/* Inner pages */
.page-hero {
  padding-top: 5.5rem;
  padding-bottom: 2rem;
}

.page-hero h1 {
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.page-hero p {
  margin-top: 0.5rem;
  color: var(--muted-foreground);
  font-size: 0.9375rem;
}

.model-card {
  border: 1px solid color-mix(in oklch, var(--border) 50%, transparent);
  border-radius: var(--radius);
  padding: 1.25rem;
  background: var(--card);
}

.model-card-head h3 {
  font-size: 0.9375rem;
  font-weight: 600;
}

.model-meta {
  margin-top: 0.5rem;
  font-size: 0.8125rem;
  color: var(--muted-foreground);
}

.filter-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.filter-tabs button {
  height: 2rem;
  padding: 0 0.875rem;
  border-radius: 0.5rem;
  border: 1px solid color-mix(in oklch, var(--border) 50%, transparent);
  background: transparent;
  color: var(--muted-foreground);
  font-size: 0.8125rem;
  font-weight: 500;
  cursor: pointer;
}

.filter-tabs button.active {
  background: var(--primary);
  color: var(--primary-foreground);
  border-color: transparent;
}

.model-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
}

@media (min-width: 768px) {
  .model-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.model-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.model-tag {
  font-size: 10px;
  font-weight: 600;
  padding: 0.125rem 0.5rem;
  border-radius: 9999px;
  background: color-mix(in oklch, var(--primary) 12%, transparent);
  color: oklch(0.52 0.14 250);
}

.model-price {
  margin-top: 0.75rem;
  font-size: 0.8125rem;
  color: var(--muted-foreground);
}
