Files
CWC/styles/blocks/page-hero.css
T
Keith SolomonandClaude e221f62ef7 Refine hero: gradient backdrop, intro inside hero, image on right, vector visible
- styles/blocks/page-hero.css: add blue-to-teal gradient to .page-hero (matches
  homepage-hero). Fix image mask direction (right-to-left fade) so the image
  is visible on the right and fades to transparent on the left. Reposition
  the vector to span the full bottom of the hero at z-index 2 (above the
  media layer, below content). Add .page-hero__intro and .page-hero__intro-inner
  grid rules for the new two-column heading + body block.
- views/partials/page-hero.php: drop bg-dark / bg-cover / bg-no-repeat
  utilities (the gradient comes from CSS now). Simplify the heading render.
  Load the page-intro partial inside .page-hero__content, below the heading.
- views/partials/page-intro.php: rewrite as a fragment for embedding inside
  the hero - a two-column heading (hard-coded 'Our Work') + body grid.
  Returns early when the intro field is empty.
- page.php: remove the page-intro partial call (it's now loaded from
  page-hero.php).
- tests/inner-page.spec.js: switch the selector from .page-intro to
  .page-hero__intro. Update the order assertions to verify the intro is
  a descendant of the hero (not a sibling below it).

Co-Authored-By: Claude <noreply@anthropic.com>
2026-07-01 15:25:39 -05:00

80 lines
1.6 KiB
CSS

/* Page Hero partial styles (page-hero.php)
* Scoped to .page-hero to avoid affecting the homepage-hero block. */
.page-hero {
background:
linear-gradient(83.68deg, #032F46 3.13%, #006196 45.91%, #8FC9E6 96.27%);
isolation: isolate;
overflow: hidden;
position: relative;
}
.page-hero__media {
inset: 0;
-webkit-mask-image: linear-gradient(to left, transparent 0%, black 50%);
mask-image: linear-gradient(to left, transparent 0%, black 50%);
position: absolute;
z-index: 1;
}
.page-hero__media img {
display: block;
height: 100%;
object-fit: cover;
object-position: right center;
width: 100%;
}
.page-hero__vector {
bottom: 0;
height: auto;
left: 0;
pointer-events: none;
position: absolute;
width: 100%;
z-index: 2;
}
.page-hero__content {
position: relative;
z-index: 10;
}
.page-hero__intro {
margin-top: clamp(2rem, 6vw, 4rem);
}
.page-hero__intro-inner {
display: grid;
gap: clamp(1.5rem, 4vw, 3rem);
grid-template-columns: 1fr;
}
@media (min-width: 768px) {
.page-hero__intro-inner {
grid-template-columns: 1fr 2fr;
}
}
@media (max-width: 767px) {
.page-hero__media {
-webkit-mask-image: linear-gradient(
to bottom,
rgb(0 0 0 / 0.9) 0%,
rgb(0 0 0 / 0.45) 100%
);
mask-image: linear-gradient(
to bottom,
rgb(0 0 0 / 0.9) 0%,
rgb(0 0 0 / 0.45) 100%
);
}
.page-hero__vector {
bottom: 0;
left: 0;
right: auto;
width: 100vw;
}
}