/* Homepage: OpenAI-style + animations */

html {
  scroll-behavior: smooth;
}

.home {
  --home-text: #0a0a0a;
  --home-muted: #737373;
  --home-border: #e5e5e5;
  --home-bg: #ffffff;
  --home-bg-subtle: #fafafa;
  --home-font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --home-max: 880px;
}

.home {
  margin: 0;
  font-family: var(--home-font);
  font-size: 16px;
  line-height: 1.6;
  color: var(--home-text);
  background: var(--home-bg);
  -webkit-font-smoothing: antialiased;
}

/* ----- Animations ----- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.animate-in {
  opacity: 0;
  animation: fadeInUp 0.7s ease-out forwards;
}

.animate-in--delay-1 {
  animation-delay: 0.15s;
  animation-fill-mode: both;
}

.animate-in--delay-2 {
  animation-delay: 0.3s;
  animation-fill-mode: both;
}

.animate-in--delay-3 {
  animation-delay: 0.45s;
  animation-fill-mode: both;
}

.animate-in--delay-4 {
  animation-delay: 0.6s;
  animation-fill-mode: both;
}

.animate-on-scroll {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-on-scroll.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.animate-on-scroll--delay-1 {
  transition-delay: 0.1s;
}

.animate-on-scroll--delay-2 {
  transition-delay: 0.2s;
}

.approach-list__item.animate-on-scroll {
  transition-delay: calc(0.1s * var(--i, 0));
}

@media (prefers-reduced-motion: reduce) {
  .animate-in,
  .animate-in--delay-1,
  .animate-in--delay-2,
  .animate-in--delay-3,
  .animate-in--delay-4 {
    animation-duration: 0.01ms;
    animation-delay: 0s;
  }
  .animate-on-scroll {
    transition-duration: 0.01ms;
    transition-delay: 0s;
  }
}

/* ----- Header (home: fixed + blur) ----- */
body.home .site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition: background 0.3s ease, border-color 0.3s ease;
}

[data-theme="dark"] body.home .site-header {
  background: rgba(17, 17, 17, 0.85);
}

/* ----- Hero ----- */
.hero {
  padding: calc(var(--header-height) + 4rem) 24px 5rem;
  min-height: 60vh;
  display: flex;
  align-items: center;
}

@media (max-width: 768px) {
  body.home .hero {
    padding-top: calc(var(--header-height) + 6rem);
  }
}

.hero .hero__inner {
  width: 100%;
}

.hero__version {
  margin: 0 0 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.hero__version-badge {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--home-text);
  background: var(--home-bg-subtle);
  border: 1px solid var(--home-border);
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
}

.hero__version-label {
  font-size: 0.75rem;
  color: var(--home-muted);
  font-weight: 500;
}

.hero__title {
  font-size: clamp(2.75rem, 8vw, 4.25rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin: 0 0 1.25rem;
  color: var(--home-text);
}

.hero__lead {
  font-size: 1.25rem;
  line-height: 1.5;
  color: var(--home-muted);
  margin: 0 0 2rem;
  max-width: 42ch;
}

.hero__cta {
  margin: 0;
}

.hero__button {
  display: inline-block;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--home-text);
  text-decoration: none;
  padding: 0.6rem 0;
  border-bottom: 2px solid var(--home-text);
  transition: opacity 0.2s ease, border-color 0.2s ease;
}

.hero__button:hover {
  opacity: 0.7;
}

/* ----- Sections ----- */
.section {
  padding: 4rem 24px;
}

.section--light {
  background: var(--home-bg-subtle);
}

.section__inner {
  max-width: var(--home-max);
  margin: 0 auto;
}

.section__title {
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 0 0 1rem;
  color: var(--home-text);
}

.section__lead {
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--home-muted);
  margin: 0 0 1.5rem;
  max-width: 55ch;
}

.section-docs {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 0.9375rem;
  color: var(--home-muted);
}

.section-docs li {
  margin-bottom: 0.5rem;
}

.section-docs a {
  color: var(--home-text);
  text-decoration: none;
  border-bottom: 1px solid var(--home-border);
  transition: border-color 0.2s ease;
}

.section-docs a:hover {
  border-bottom-color: var(--home-text);
}

/* ----- Taxonomy (Approach) ----- */
.approach-taxonomy-title,
.approach-pillars-title {
  font-size: 1.125rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin: 1.5rem 0 0.5rem;
  color: var(--home-text);
}

.approach-pillars-title {
  margin-top: 2rem;
}

.approach-taxonomy-intro {
  font-size: 0.9375rem;
  line-height: 1.55;
  color: var(--home-muted);
  margin: 0 0 1.25rem;
}

.taxonomy-block {
  margin-bottom: 2.5rem;
  padding: 1.25rem 0;
  border-top: 1px solid var(--home-border);
  border-bottom: 1px solid var(--home-border);
}

.taxonomy-block__heading {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--home-muted);
  margin: 0 0 0.75rem;
}

.taxonomy-block__heading + .taxonomy-domains,
.taxonomy-block__heading + .taxonomy-respects {
  margin-top: 0;
}

.taxonomy-domains {
  display: grid;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

@media (min-width: 640px) {
  .taxonomy-domains {
    grid-template-columns: repeat(2, 1fr);
  }
}

.taxonomy-domain {
  padding: 1rem;
  background: var(--home-bg-subtle);
  border: 1px solid var(--home-border);
  border-radius: 6px;
}

.taxonomy-domain__name {
  font-size: 0.9375rem;
  color: var(--home-text);
  display: block;
  margin-bottom: 0.25rem;
}

.taxonomy-domain__source {
  font-size: 0.75rem;
  color: var(--home-muted);
  display: block;
  margin-bottom: 0.5rem;
}

.taxonomy-domain__desc {
  font-size: 0.875rem;
  line-height: 1.5;
  color: var(--home-muted);
  margin: 0;
}

.taxonomy-respects {
  margin: 0;
  padding-left: 1.25rem;
  font-size: 0.9375rem;
  line-height: 1.6;
  color: var(--home-muted);
}

.taxonomy-respects li {
  margin-bottom: 0.35rem;
}

.taxonomy-respects li strong {
  color: var(--home-text);
}

/* ----- Approach list ----- */
.approach-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 2rem;
}

@media (min-width: 640px) {
  .approach-list {
    grid-template-columns: repeat(3, 1fr);
  }
}

.approach-list__item {
  padding: 0;
}

.approach-list__heading {
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin: 0 0 0.5rem;
  color: var(--home-text);
}

.approach-list__item p {
  font-size: 0.9375rem;
  line-height: 1.55;
  color: var(--home-muted);
  margin: 0;
}

/* ----- Link arrow ----- */
.link-arrow {
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--home-text);
  text-decoration: none;
  border-bottom: 1px solid var(--home-border);
  padding-bottom: 0.1em;
  transition: border-color 0.2s ease;
}

.link-arrow:hover {
  border-bottom-color: var(--home-text);
}

/* ----- Updates list ----- */
.updates-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.updates-list__item {
  padding: 1.25rem 0;
  border-bottom: 1px solid var(--home-border);
}

.updates-list__item:last-child {
  border-bottom: none;
}

.updates-list__meta-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 0.35rem;
}

.updates-list__version {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--home-text);
}

.updates-list__meta {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--home-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.updates-list__date {
  font-size: 0.75rem;
  color: var(--home-muted);
  margin-left: auto;
}

.updates-list__desc {
  font-size: 0.9375rem;
  line-height: 1.55;
  color: var(--home-muted);
  margin: 0.5rem 0 0.5rem;
}

.updates-list__item .link-arrow {
  font-size: 0.875rem;
}

.updates-list__sep {
  margin: 0 0.35rem;
  color: var(--home-muted);
  font-weight: 400;
}

/* ----- Footer ----- */
.home-footer {
  padding: 2.5rem 24px 3rem;
  border-top: 1px solid var(--home-border);
  background: var(--home-bg);
}

.home-footer__inner {
  max-width: var(--home-max);
  margin: 0 auto;
}

.home-footer__top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.home-footer__logo {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--home-text);
  text-decoration: none;
  letter-spacing: -0.01em;
  transition: opacity 0.2s ease;
}

.home-footer__logo:hover {
  opacity: 0.7;
}

.home-footer__nav {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.home-footer__nav a {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--home-muted);
  text-decoration: none;
  transition: color 0.2s ease;
}

.home-footer__nav a:hover {
  color: var(--home-text);
}

.home-footer__copy {
  font-size: 0.8125rem;
  color: var(--home-muted);
  margin: 0;
}

.home-footer__version {
  font-weight: 500;
  color: var(--home-text);
}
