/* =========================================================
   CAPSTONE PROJECTS
   Remove Roofix / WordPress auto title banner on project pages
   Keeps the custom Capstone project hero intact
   ========================================================= */

body.single-capstone_project .entry-banner,
body.single-capstone_project .entry-banner-after,
body.single-capstone_project .inner-page-banner.bg-common,
body.single-capstone_project .inner-page-top-margin {
  display: none !important;
  visibility: hidden !important;
  height: 0 !important;
  min-height: 0 !important;
  max-height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: hidden !important;
}

/* Remove any leftover spacing the theme may leave before the custom project page */
body.single-capstone_project #content,
body.single-capstone_project .site-content,
body.single-capstone_project main.cpb-single-project {
  margin-top: 0 !important;
  padding-top: 0 !important;
}

/* Make sure the custom Capstone project hero still displays normally */
body.single-capstone_project .cpb-single-project,
body.single-capstone_project .cpb-project-hero,
body.single-capstone_project .cpb-project-single-hero {
  display: block !important;
  visibility: visible !important;
  height: auto !important;
  max-height: none !important;
  overflow: visible !important;
}
/* =========================================================
   CAPSTONE PROJECTS ARCHIVE / PROJECTS PAGE
   Remove Roofix / WordPress auto title banner on the main
   Projects page while keeping the custom Capstone archive hero
   ========================================================= */

/* Native Capstone projects archive */
body.post-type-archive-capstone_project .entry-banner,
body.post-type-archive-capstone_project .entry-banner-after,
body.post-type-archive-capstone_project .inner-page-banner.bg-common,
body.post-type-archive-capstone_project .inner-page-top-margin,

/* Projects page using the Capstone archive shortcode/widget */
body:has(.cpb-projects-archive) .entry-banner,
body:has(.cpb-projects-archive) .entry-banner-after,
body:has(.cpb-projects-archive) .inner-page-banner.bg-common,
body:has(.cpb-projects-archive) .inner-page-top-margin {
  display: none !important;
  visibility: hidden !important;
  height: 0 !important;
  min-height: 0 !important;
  max-height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: hidden !important;
}

/* Remove leftover spacing before the custom Projects page layout */
body.post-type-archive-capstone_project #content,
body.post-type-archive-capstone_project .site-content,
body.post-type-archive-capstone_project .content-area,
body.post-type-archive-capstone_project main.cpb-projects-archive,
body:has(.cpb-projects-archive) #content,
body:has(.cpb-projects-archive) .site-content,
body:has(.cpb-projects-archive) .content-area,
body:has(.cpb-projects-archive) main.cpb-projects-archive {
  margin-top: 0 !important;
  padding-top: 0 !important;
}

/* Make sure the custom Capstone Projects archive still displays normally */
body.post-type-archive-capstone_project .cpb-projects-archive,
body.post-type-archive-capstone_project .cpb-archive-hero,
body:has(.cpb-projects-archive) .cpb-projects-archive,
body:has(.cpb-projects-archive) .cpb-archive-hero {
  display: block !important;
  visibility: visible !important;
  height: auto !important;
  max-height: none !important;
  overflow: visible !important;
}

/* Pull the custom archive hero tight to the header */
body.post-type-archive-capstone_project .cpb-projects-archive,
body:has(.cpb-projects-archive) .cpb-projects-archive {
  margin-top: 0 !important;
}
/* =========================================================
   CAPSTONE RAIL — DOTCOMM AWARD ARTICLE
   ========================================================= */

.capstone-award-article {
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  color: #262626;
  font-size: 18px;
  line-height: 1.75;
}

.capstone-award-article * {
  box-sizing: border-box;
}

.capstone-award-article p {
  margin: 0 0 24px;
}

.capstone-award-article a {
  color: #bd2026;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.capstone-award-article h2 {
  margin: 0 0 24px;
  color: #1f1f1f;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.1;
  letter-spacing: -0.03em;
}

.capstone-award-hero {
  width: 100%;
  margin: 0 0 50px;
}

.capstone-award-hero img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 4px;
}

.capstone-award-intro {
  max-width: 850px;
  margin: 0 auto 48px;
}

.capstone-award-lead {
  color: #1f1f1f;
  font-size: clamp(23px, 3vw, 31px);
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: -0.02em;
}

.capstone-award-quote {
  position: relative;
  margin: 55px 0 70px;
  padding: 45px 50px 42px;
  overflow: hidden;
  border-left: 6px solid #bd2026;
  background: #222;
  color: #fff;
}

.capstone-award-quote::after {
  position: absolute;
  top: -35px;
  right: 20px;
  color: rgba(255, 255, 255, 0.06);
  font-family: Georgia, serif;
  font-size: 190px;
  line-height: 1;
  content: "“";
}

.capstone-award-quote p {
  position: relative;
  z-index: 1;
  margin: 0 0 25px;
  font-size: clamp(24px, 3.2vw, 38px);
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: -0.025em;
}

.capstone-award-quote footer {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.capstone-award-quote footer strong {
  font-size: 17px;
}

.capstone-award-quote footer span {
  color: rgba(255, 255, 255, 0.72);
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.capstone-award-section {
  margin: 0 0 70px;
}

.capstone-award-two-column {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: 65px;
  align-items: start;
}

.capstone-award-content {
  min-width: 0;
}

.capstone-award-profile {
  position: sticky;
  top: 120px;
  margin: 0;
  padding: 14px;
  background: #f2f2f2;
}

.capstone-award-profile img {
  display: block;
  width: 100%;
  height: auto;
}

.capstone-award-profile figcaption {
  display: flex;
  flex-direction: column;
  padding: 18px 8px 8px;
  line-height: 1.35;
}

.capstone-award-profile figcaption strong {
  color: #202020;
  font-size: 18px;
}

.capstone-award-profile figcaption span {
  margin-top: 4px;
  color: #6a6a6a;
  font-size: 14px;
}

.capstone-award-section-light {
  margin: 0 0 70px;
  padding: 55px 60px 35px;
  background: #f3f3f3;
}

.capstone-award-cta {
  position: relative;
  margin: 0 0 65px;
  padding: 65px;
  overflow: hidden;
  background: #202020;
  color: #fff;
}

.capstone-award-cta::after {
  position: absolute;
  top: 0;
  right: 0;
  width: 8px;
  height: 100%;
  background: #bd2026;
  content: "";
}

.capstone-award-cta-content {
  max-width: 760px;
}

.capstone-award-eyebrow {
  display: block;
  margin-bottom: 15px;
  color: #e02a31;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.13em;
}

.capstone-award-cta h2 {
  color: #fff;
}

.capstone-award-cta p {
  color: rgba(255, 255, 255, 0.78);
}

.capstone-award-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  margin-top: 10px;
  padding: 14px 25px;
  border: 2px solid #bd2026;
  background: #bd2026;
  color: #fff !important;
  font-size: 15px;
  font-weight: 700;
  text-decoration: none !important;
  transition: 0.2s ease;
}

.capstone-award-button:hover {
  background: transparent;
  color: #fff !important;
}

.capstone-award-about {
  padding-top: 10px;
  border-top: 1px solid #d5d5d5;
}

.capstone-award-about h2 {
  margin-top: 40px;
  font-size: clamp(25px, 3vw, 34px);
}

@media (max-width: 800px) {
  .capstone-award-article {
    font-size: 17px;
  }

  .capstone-award-two-column {
    grid-template-columns: 1fr;
    gap: 35px;
  }

  .capstone-award-profile {
    position: static;
    display: grid;
    grid-template-columns: 130px minmax(0, 1fr);
    align-items: center;
    max-width: 430px;
  }

  .capstone-award-profile figcaption {
    padding: 15px 20px;
  }

  .capstone-award-quote,
  .capstone-award-section-light,
  .capstone-award-cta {
    padding: 38px 28px;
  }
}

@media (max-width: 520px) {
  .capstone-award-hero {
    margin-bottom: 35px;
  }

  .capstone-award-quote {
    margin: 40px 0 50px;
  }

  .capstone-award-profile {
    display: block;
  }

  .capstone-award-profile img {
    width: 100%;
  }

  .capstone-award-section,
  .capstone-award-section-light,
  .capstone-award-cta {
    margin-bottom: 50px;
  }
}