:root {
  color: #292524;
  background: #e7e5e4;
  font-family: Georgia, "Times New Roman", serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
}

.knowledge-page {
  width: min(100% - 2.5rem, 68rem);
  margin: 0 auto;
  padding: 4rem 0 5rem;
}

.page-header {
  max-width: 44rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid #a8a29e;
}

.back-link,
.case-study a {
  color: inherit;
  font-family: Arial, sans-serif;
  font-size: 0.8125rem;
  font-weight: 600;
}

.back-link {
  display: inline-block;
  margin-bottom: 3rem;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.25rem;
}

.eyebrow,
.case-type {
  margin: 0;
  color: #78716c;
  font-family: Arial, sans-serif;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  margin: 0.65rem 0 1rem;
  font-size: clamp(2.25rem, 6vw, 4.5rem);
  font-weight: 500;
  letter-spacing: 0;
  line-height: 1;
}

.intro {
  max-width: 38rem;
  margin-bottom: 0;
  color: #57534e;
  font-family: Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.6;
}

.case-studies {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr));
  gap: 1rem;
  margin: 3rem 0;
}

.case-study {
  display: flex;
  min-height: 18rem;
  flex-direction: column;
  border: 1px solid #a8a29e;
  padding: 1.5rem;
  background: #f5f5f4;
}

.case-study h2,
.writing-template h2 {
  margin: 1rem 0;
  font-size: 1.5rem;
  font-weight: 500;
  letter-spacing: 0;
  line-height: 1.15;
}

.case-study p:not(.case-type) {
  color: #57534e;
  font-family: Arial, sans-serif;
  font-size: 0.875rem;
  line-height: 1.55;
}

.case-study a {
  margin-top: auto;
  padding-top: 1.5rem;
  text-underline-offset: 0.25rem;
}

.writing-template {
  max-width: 44rem;
  padding: 2rem 0;
}

.writing-template ol {
  display: grid;
  gap: 0.75rem;
  margin: 0;
  padding-left: 1.25rem;
  color: #57534e;
  font-family: Arial, sans-serif;
  font-size: 0.9375rem;
  line-height: 1.55;
}

.writing-template strong {
  color: #292524;
}

.case-study-page {
  max-width: 48rem;
}

.case-study-detail h1 {
  margin: 0.65rem 0 1.25rem;
  font-size: clamp(2.25rem, 6vw, 4rem);
  font-weight: 500;
  line-height: 1.05;
}

.detail-summary {
  max-width: 42rem;
  margin-bottom: 3rem;
  color: #57534e;
  font-family: Arial, sans-serif;
  font-size: 1.05rem;
  line-height: 1.6;
}

.detail-section {
  padding: 1.75rem 0;
  border-top: 1px solid #a8a29e;
}

.detail-section h2 {
  margin-bottom: 0.75rem;
  font-size: 1.5rem;
  font-weight: 500;
  line-height: 1.2;
}

.detail-section p,
.detail-section ol {
  margin: 0;
  color: #57534e;
  font-family: Arial, sans-serif;
  font-size: 0.9375rem;
  line-height: 1.65;
}

.detail-section ol {
  display: grid;
  gap: 0.75rem;
  padding-left: 1.25rem;
}

.detail-error {
  color: #b91c1c;
  font-family: Arial, sans-serif;
}

@media (max-width: 700px) {
  .knowledge-page {
    width: min(100% - 2rem, 68rem);
    padding: 2rem 0 3rem;
  }

  .back-link {
    margin-bottom: 2rem;
  }

  .case-studies {
    grid-template-columns: 1fr;
  }

  .case-study {
    min-height: 14rem;
  }
}
