/* ══════════════════════════════════════════
   Categories Page
   Dark hero + Masonry grid (feat-item pattern)
   ══════════════════════════════════════════ */


/* ── Nav: dark hero state ── */

body.cp-page .nav:not(.is-scrolled) .nav__pill {
  background: rgba(0,0,0,0.25);
  border-color: rgba(255,255,255,0.08);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
}
body.cp-page .nav:not(.is-scrolled) .nav__logo-white { display: block; }
body.cp-page .nav:not(.is-scrolled) .nav__logo-black { display: none; }
body.cp-page .nav:not(.is-scrolled) .nav__link       { color: rgba(255,255,255,0.92); }
body.cp-page .nav:not(.is-scrolled) .nav__link:hover  { color: rgba(255,255,255,0.95); }
body.cp-page .nav:not(.is-scrolled) .nav__link::after  { background: var(--lime); }
body.cp-page .nav:not(.is-scrolled) .nav__hamburger   { background: rgba(255,255,255,0.08); border-color: rgba(255,255,255,0.12); }
body.cp-page .nav:not(.is-scrolled) .nav__hamburger-line { background-color: rgba(255,255,255,0.85); }
body.cp-page .nav:not(.is-scrolled) .nav__link--active { color: rgba(255,255,255,0.95) !important; }
body.cp-page .nav:not(.is-scrolled) .nav__link--active::after { width: 100% !important; }
body.cp-page .nav.is-scrolled .nav__link--active { color: var(--black) !important; }
body.cp-page .nav.is-scrolled .nav__link--active::after { width: 100% !important; background: var(--black) !important; }

@media (max-width: 960px) {
  body.cp-page .nav:not(.is-scrolled) .nav__pill {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
}


/* ══════════════════════════════════════════
   Hero — Dark, image-backed
   ══════════════════════════════════════════ */

.cp-hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  background: var(--black);
  overflow: hidden;
  padding-top: 100px;
}

.cp-hero__bg { position: absolute; inset: 0; }
.cp-hero__bg img { width: 100%; height: 100%; object-fit: cover; opacity: 0.32; }

.cp-hero__overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(17,17,17,0.96) 0%, rgba(17,17,17,0.55) 45%, rgba(17,17,17,0.18) 100%);
  z-index: 1;
}

.cp-hero__inner {
  position: relative; z-index: 2;
  padding: 0 var(--gutter) 48px;
  max-width: var(--container-wide);
  margin: 0 auto; width: 100%;
}

.cp-hero__breadcrumb {
  font-size: 11px; letter-spacing: 0.06em;
  color: rgba(255,255,255,0.35);
  margin-bottom: 52px;
  display: flex; align-items: center; flex-wrap: wrap;
}
.cp-hero__breadcrumb a { color: rgba(255,255,255,0.35); transition: color var(--transition); }
.cp-hero__breadcrumb a:hover { color: rgba(255,255,255,0.8); }
.cp-hero__breadcrumb-sep { margin: 0 8px; color: rgba(255,255,255,0.15); }

.cp-hero__eyebrow {
  font-size: 11px; font-weight: 600; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--lime);
  display: flex; align-items: center; gap: 14px; margin-bottom: 20px;
}
.cp-hero__eyebrow::before { content: ''; width: 32px; height: 1px; background: var(--lime); }

.cp-hero__headline {
  font-family: var(--font-heading);
  font-size: clamp(52px, 8vw, 120px);
  font-weight: 700; line-height: 0.92;
  letter-spacing: -0.045em; color: var(--white);
  margin: 0 0 28px; max-width: 14ch;
}

.cp-hero__valueprop {
  font-size: 15px; font-weight: 300; line-height: 1.85;
  color: rgba(255,255,255,0.55); max-width: 52ch; margin-bottom: 36px;
}

.cp-hero__actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }

.cp-hero__stat-bar {
  position: relative; z-index: 2;
  background: rgba(255,255,255,0.04);
  border-top: 1px solid rgba(255,255,255,0.08);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.cp-hero__stat-bar-inner {
  max-width: var(--container-wide); margin: 0 auto;
  padding: 28px var(--gutter);
}
.cp-hero__stats { display: flex; gap: 56px; flex-wrap: wrap; }
.cp-hero__stat { display: flex; flex-direction: column; }
.cp-hero__stat-num {
  font-family: var(--font-heading); font-size: 36px; font-weight: 700;
  color: var(--white); letter-spacing: -0.02em; line-height: 1;
}
.cp-hero__stat-label {
  font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase;
  color: rgba(255,255,255,0.35); margin-top: 6px;
}

.cp-hero__scroll {
  position: absolute; bottom: 120px; right: var(--gutter); z-index: 2;
  display: flex; flex-direction: column; align-items: center; gap: 8px;
}
.cp-hero__scroll-text {
  font-size: 9px; font-weight: 500; letter-spacing: 0.2em;
  text-transform: uppercase; color: rgba(255,255,255,0.25);
}
.cp-hero__scroll-line {
  width: 1px; height: 32px;
  background: linear-gradient(to bottom, rgba(255,255,255,0.3), transparent);
  animation: cpScrollPulse 2s ease-in-out infinite;
}
@keyframes cpScrollPulse { 0%,100% { opacity: 0.3; } 50% { opacity: 0.8; } }


/* ══════════════════════════════════════════
   Category Grid — Masonry (mirrors featured__masonry / feat-item)
   ══════════════════════════════════════════ */

.cp-categories { background: var(--white); }

.cp-categories__header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 64px;
  gap: 2rem;
}

.cp-categories__desc {
  max-width: 36ch;
  text-align: right;
}

/* Masonry — same structure as featured__masonry */
.cp-masonry {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

.cp-masonry__col {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.cp-masonry__col--right { margin-top: 80px; }

/* ── Category item — extends feat-item pattern ── */

.cp-item {
  display: block;
  text-decoration: none;
  color: inherit;
}

.cp-item__img {
  background: var(--off-white);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  margin-bottom: 20px;
  will-change: transform;
}

.cp-item--tall .cp-item__img { aspect-ratio: 3 / 4; }

.cp-item__img img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  transition: transform 0.6s var(--ease);
}

.cp-item:hover .cp-item__img img { transform: scale(1.05); }

/* Info block below image */
.cp-item__info {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.cp-item__eyebrow {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--lime);
  display: block;
  margin-bottom: 8px;
}

.cp-item__name {
  font-family: var(--font-heading);
  font-size: clamp(22px, 2.5vw, 32px);
  font-weight: 700;
  color: var(--black);
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin: 0 0 12px;
  transition: color var(--transition);
}

.cp-item:hover .cp-item__name { color: var(--lime); }

.cp-item__desc {
  font-size: 14px;
  font-weight: 300;
  line-height: 1.75;
  color: var(--gray);
  margin-bottom: 16px;
  max-width: 48ch;
}

.cp-item__meta {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 14px;
}

.cp-item__count {
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 600;
  color: var(--black);
  letter-spacing: -0.01em;
}

.cp-item__link {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--lime);
  transition: opacity var(--transition);
}

.cp-item:hover .cp-item__link { opacity: 0.7; }

.cp-item__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.cp-item__tags span {
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.02em;
  color: var(--gray-light);
  padding: 5px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  white-space: nowrap;
  transition: border-color var(--transition), color var(--transition);
}

.cp-item:hover .cp-item__tags span {
  border-color: rgba(168,204,54,0.4);
  color: var(--gray);
}


/* ══════════════════════════════════════════
   CTA Section
   ══════════════════════════════════════════ */

.cp-cta {
  background: var(--black);
  padding: 120px 0;
}

.cp-cta__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: end;
}

.cp-cta .eyebrow { margin-bottom: 20px; }

.cp-cta__headline {
  font-family: var(--font-heading);
  font-size: clamp(40px, 5vw, 68px);
  font-weight: 700;
  line-height: 1.02;
  letter-spacing: -0.025em;
  color: var(--white);
  margin: 0;
}

.cp-cta__lead {
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 300;
  line-height: 1.75;
  color: var(--gray);
  margin-bottom: 32px;
  max-width: 42ch;
}


/* ══════════════════════════════════════════
   Responsive — Tablet (≤ 1023px)
   ══════════════════════════════════════════ */

@media (max-width: 1023px) {
  .cp-hero__headline { font-size: clamp(44px, 8vw, 80px); }
  .cp-hero__stats { gap: 36px; }
  .cp-hero__scroll { display: none; }

  .cp-categories__header {
    flex-direction: column;
    align-items: flex-start;
  }
  .cp-categories__desc { text-align: left; }

  .cp-masonry { gap: 24px; }
  .cp-masonry__col--right { margin-top: 48px; }
  .cp-item__img { padding: 32px; }

  .cp-cta__inner {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }
}


/* ══════════════════════════════════════════
   Responsive — Mobile (≤ 767px)
   ══════════════════════════════════════════ */

@media (max-width: 767px) {
  .cp-hero { min-height: 90vh; min-height: 90svh; }
  .cp-hero__inner { padding-bottom: 40px; }
  .cp-hero__headline { font-size: clamp(36px, 11vw, 60px); margin-bottom: 20px; }
  .cp-hero__valueprop { font-size: 14px; }
  .cp-hero__actions { flex-direction: column; align-items: flex-start; }
  .cp-hero__stat-bar-inner { padding: 20px var(--gutter); }
  .cp-hero__stats { gap: 24px; }
  .cp-hero__stat-num { font-size: 28px; }

  .cp-masonry { grid-template-columns: 1fr; gap: 40px; }
  .cp-masonry__col--right { margin-top: 0; }
  .cp-item--tall .cp-item__img { aspect-ratio: 4 / 3; }
  .cp-item__img { padding: 32px; }
  .cp-item__name { font-size: clamp(20px, 5vw, 28px); }
  .cp-item__desc { font-size: 13px; }

  .cp-cta { padding: 80px 0; }
  .cp-cta__headline { font-size: clamp(32px, 8vw, 48px); }
}


/* ══════════════════════════════════════════
   Responsive — Small phones (≤ 400px)
   ══════════════════════════════════════════ */

@media (max-width: 400px) {
  .cp-hero__headline { font-size: 34px; }
  .cp-hero__stat-num { font-size: 24px; }

  .cp-item__img { padding: 24px; }
  .cp-item__eyebrow { font-size: 10px; }
  .cp-item__name { font-size: 20px; }
  .cp-item__desc { font-size: 13px; }
  .cp-item__tags span { font-size: 9px; padding: 4px 9px; }

  .cp-cta { padding: 56px 0; }
  .cp-cta__headline { font-size: 28px; }
  .cp-cta__lead { font-size: 14px; }
}
