/* Resources archive + single article */

.resources-archive {
  /* Clear fixed topbar so breadcrumbs are not covered. */
  padding-top: calc(7.75rem + 2.75rem);
  padding-bottom: 7rem;
}

.resources-archive__grid {
  display: grid;
  gap: 1.75rem;
  grid-template-columns: 1fr;
  margin-top: 3rem;
}

@media (min-width: 1024px) {
  .resources-archive__grid {
    margin-top: 3.5rem;
  }
}

@media (min-width: 768px) {
  .resources-archive__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1200px) {
  .resources-archive__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.resource-card {
  border: 1px solid #dce3e0;
  background: #fff;
  transition: border-color .25s ease, box-shadow .25s ease, transform .25s ease;
}

.resource-card:hover {
  border-color: rgba(39, 196, 106, .45);
  box-shadow: 0 18px 40px rgba(8, 12, 17, .08);
  transform: translateY(-2px);
}

.resource-card__link {
  display: flex;
  flex-direction: column;
  height: 100%;
  color: inherit;
  text-decoration: none;
}

.resource-card__media {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #e8eee9;
}

.resource-card__image,
.resource-card__placeholder {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.resource-card__placeholder {
  background:
    linear-gradient(135deg, #d7e3db 0%, #eef3f0 55%, #c9d8cf 100%);
}

.resource-card__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: .75rem;
  padding: 1.35rem 1.4rem 1.5rem;
}

.resource-card__title {
  margin: 0;
  font-family: var(--font-display, Manrope, sans-serif);
  font-size: clamp(1.35rem, 2vw, 1.65rem);
  font-weight: 800;
  letter-spacing: -.035em;
  line-height: 1.15;
}

.resource-card__excerpt {
  margin: 0;
  color: #475569;
  font-size: .98rem;
  line-height: 1.55;
}

.resource-card__cta {
  margin-top: auto;
  padding-top: .5rem;
  color: var(--ml-metalgreen, #27c46a);
  font: 700 .78rem/1 var(--font-cta, Sora, sans-serif);
  letter-spacing: .06em;
  text-transform: uppercase;
}

.resource-single {
  background: #fff;
}

.resource-single__topbar-spacer {
  height: 7.75rem;
  background: #fff;
}

.resource-single__hero {
  position: relative;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  background: #fff;
  color: var(--ml-ink, #080c11);
}

.resource-single__hero--has-media {
  align-items: center;
  justify-content: center;
  min-height: min(calc((72vh + 20px) * 0.9), calc((42rem + 20px) * 0.9));
  background: #080c11;
  color: #fff;
  box-sizing: border-box;
}

.resource-single__hero--no-media {
  padding: 7.75rem 0 2.5rem;
}

.resource-single__media,
.resource-single__overlay {
  position: absolute;
  inset: 0;
}

.resource-single__media {
  overflow: hidden;
}

.resource-single__image,
.resource-single__media img {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: center;
}

.resource-single__overlay {
  background:
    linear-gradient(180deg, rgba(8, 12, 17, .55) 0%, rgba(8, 12, 17, .72) 48%, rgba(8, 12, 17, .9) 100%),
    linear-gradient(90deg, rgba(8, 12, 17, .42), transparent 42%, transparent 58%, rgba(8, 12, 17, .42));
}

.resource-single__hero-content {
  position: relative;
  z-index: 1;
  display: flex;
  width: 100%;
  justify-content: center;
  padding: 2rem 1.5rem 2.75rem;
  text-align: center;
}

.resource-single__hero--has-media .resource-single__hero-content {
  padding-bottom: 3.25rem;
}

.resource-single__hero-inner {
  box-sizing: border-box;
  width: 100%;
  max-width: 52rem;
  margin-inline: auto;
}

.resource-single__eyebrow {
  margin: 0;
  color: var(--ml-metalgreen, #27c46a);
}

.resource-single__title {
  max-width: 18ch;
  margin: 0 auto;
  font-size: clamp(2.6rem, 6vw, 4.75rem);
  line-height: .96;
}

.resource-single__breadcrumbs {
  background: #fff;
  padding: 0 1.5rem 2.5rem;
}

.resource-single__breadcrumbs-inner {
  box-sizing: border-box;
  width: 100%;
  max-width: 760px;
  margin-inline: auto;
}

.resource-single__breadcrumbs .metalleve-breadcrumbs {
  margin-bottom: 0;
}

.resource-single__breadcrumbs .metalleve-breadcrumbs__list {
  justify-content: center;
  text-align: center;
}

.resource-single__content {
  padding: clamp(3rem, 6vw, 5rem) 0 1.5rem;
  background: #fff;
}

.resource-single__prose {
  box-sizing: border-box;
  width: 100%;
  max-width: 760px;
  margin-inline: auto;
  padding-inline: 1.5rem;
  color: #334155;
  font-size: 1.08rem;
  line-height: 1.75;
}

.resource-single__prose > *:first-child {
  margin-top: 0;
}

.resource-single__prose h2,
.resource-single__prose h3 {
  margin: 2.4rem 0 1rem;
  color: var(--ml-ink, #080c11);
  font-family: var(--font-display, Manrope, sans-serif);
  font-weight: 800;
  letter-spacing: -.04em;
  line-height: 1.15;
}

.resource-single__prose h2 {
  font-size: clamp(1.7rem, 3vw, 2.25rem);
}

.resource-single__prose h3 {
  font-size: clamp(1.25rem, 2vw, 1.5rem);
}

.resource-single__prose p,
.resource-single__prose ul,
.resource-single__prose ol {
  margin: 0 0 1.15rem;
}

.resource-single__prose ul,
.resource-single__prose ol {
  padding-left: 1.25rem;
}

.resource-single__prose a {
  color: var(--ml-metalgreen, #27c46a);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.resource-single__prose .resource-figure {
  margin: 2rem 0 2.25rem;
}

.resource-single__prose .resource-figure img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 28rem;
  object-fit: cover;
  object-position: center;
  background: #e8eee9;
}

.resource-single__prose .resource-figure figcaption {
  margin-top: .65rem;
  color: #64748b;
  font-size: .9rem;
  line-height: 1.45;
}

/* Fabrication article: keep the FRAMECAD operator visible in cropped frames. */
.resource-single--how-cfs-fabrication-works.resource-single .resource-single__hero--has-media,
.resource-single--how-cfs-fabrication-works .resource-single__hero--has-media {
  min-height: min(calc((72vh + 20px) * 0.98), calc((42rem + 20px) * 0.98));
}

.resource-single--how-cfs-fabrication-works .resource-single__image,
.resource-single--how-cfs-fabrication-works .resource-single__media img {
  object-position: 88% 35%;
}

.resource-single__prose .resource-figure--operator img {
  max-height: 32rem;
  object-fit: cover;
  object-position: 88% 28%;
}

.resource-card--how-cfs-fabrication-works .resource-card__image {
  object-position: 92% 30%;
}

.resource-single__cta {
  padding: clamp(4rem, 8vw, 6.5rem) 0;
  background: #080c11;
  color: #fff;
}

.resource-single__cta .local-button {
  display: inline-flex;
  min-height: 52px;
  align-items: center;
  justify-content: center;
  padding: .8rem 1.4rem;
  border: 1px solid transparent;
  font: 700 .82rem/1 var(--font-cta, Sora, sans-serif);
  letter-spacing: .04em;
  text-decoration: none;
  text-transform: uppercase;
  transition: transform .2s, background .2s, border-color .2s;
}

.resource-single__cta .local-button:hover {
  transform: translateY(-2px);
}

.resource-single__cta .local-button--primary {
  background: var(--ml-metalgreen, #27c46a);
  color: #06130c;
}

.resource-single__cta .local-button--secondary {
  border-color: rgba(255, 255, 255, .32);
  background: rgba(255, 255, 255, .06);
  color: #fff;
}

.resources-archive .navigation.pagination {
  margin-top: 3rem;
}

.resources-archive .nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
  align-items: center;
}

.resources-archive .page-numbers {
  display: inline-flex;
  min-width: 2.5rem;
  min-height: 2.5rem;
  align-items: center;
  justify-content: center;
  border: 1px solid #dce3e0;
  color: #334155;
  font-weight: 700;
  text-decoration: none;
}

.resources-archive .page-numbers.current,
.resources-archive a.page-numbers:hover {
  border-color: var(--ml-metalgreen, #27c46a);
  color: var(--ml-ink, #080c11);
}
