/* Shared long-form "legal page" article styles for Project-if.
   Originally built for /terms/, and reused as-is (unmodified, loaded via a
   relative path) by /privacy/ — both are single-column numbered-section
   documents, so this file is intentionally generic rather than named after
   either page. Mirrors the article pattern already established by
   about/about.css (numbered section + heading + body), which reads better
   for legal/reference text than the 2-column landing-page "detail-section"
   pattern used on product pages. Class names keep the "terms-" prefix for
   historical reasons (this file predates /privacy/); treat it as the
   general legal-page system, not something specific to the Terms page. */

.terms-body {
  background:
    linear-gradient(rgba(255, 255, 255, 0.36), rgba(255, 255, 255, 0.08)),
    var(--bg);
}

.terms-main {
  padding-bottom: 60px;
}

.terms-hero {
  padding: 72px 0 44px;
}

.terms-shell {
  display: grid;
  gap: 18px;
  max-width: 900px;
  margin-inline: auto;
}

.terms-shell h1 {
  margin: 0;
  font-size: clamp(2.4rem, 5.5vw, 4rem);
  line-height: 1.1;
  letter-spacing: -0.07em;
  color: var(--ink);
}

.terms-lead {
  margin: 0;
  max-width: 800px;
  color: var(--muted);
  font-size: clamp(1rem, 1.4vw, 1.16rem);
  line-height: 1.75;
}

.terms-updated {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
}

.terms-body-content {
  padding-top: 20px;
}

.terms-content-shell {
  max-width: 880px;
  margin: 0 auto;
  padding: 0;
}

.terms-article {
  display: grid;
  gap: 56px;
}

.terms-section {
  display: grid;
  gap: 20px;
}

.section-head {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 24px;
  align-items: start;
}

.section-number {
  margin: 0;
  font-size: clamp(1.8rem, 3.2vw, 2.6rem);
  line-height: 1;
  font-weight: 900;
  letter-spacing: -0.08em;
  color: rgba(49, 94, 219, 0.15);
  flex-shrink: 0;
  width: 52px;
  text-align: right;
}

.section-head h2 {
  margin: 0;
  font-size: clamp(1.3rem, 2.2vw, 1.7rem);
  line-height: 1.3;
  letter-spacing: -0.03em;
  color: var(--ink);
  font-weight: 700;
}

.section-body {
  display: grid;
  gap: 12px;
}

.section-body p {
  margin: 0;
  color: var(--text);
  font-size: 0.98rem;
  line-height: 1.85;
}

.section-body ul {
  margin: 0;
  padding-left: 22px;
  display: grid;
  gap: 8px;
}

.section-body li {
  color: var(--text);
  font-size: 0.98rem;
  line-height: 1.75;
}

.section-body a {
  color: var(--blue);
  font-weight: 700;
}

.section-body a:hover,
.section-body a:focus-visible {
  text-decoration: underline;
}

.terms-note {
  margin: 0;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.5);
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.7;
}

@media (max-width: 768px) {
  .terms-hero {
    padding: 50px 0 36px;
  }

  .section-head {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .section-number {
    width: 100%;
    text-align: left;
    margin-bottom: -6px;
  }
}

@media (max-width: 640px) {
  .terms-shell h1 {
    font-size: clamp(1.8rem, 4vw, 2.3rem);
  }

  .terms-lead {
    font-size: 0.96rem;
  }

  .terms-article {
    gap: 40px;
  }

  .terms-content-shell {
    padding: 0 12px;
  }
}
