.cs3-page {
  position: relative;
  padding: clamp(18px, 3vw, 28px) 0 clamp(50px, 6vw, 76px);
  display: grid;
  gap: clamp(14px, 2vw, 22px);
}

/* Single page heading for /our-work (hero marketing block removed). */
.cs3-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.cs3-nav {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.cs3-nav-btn {
  min-height: 44px;
  min-width: 44px;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.18);
  background: rgba(255,255,255,.04);
  color: #fff;
  font-weight: 600;
  opacity: .65;
  cursor: not-allowed;
}

.cs3-hero,
.cs3-brief,
.cs3-deliverables,
.cs3-journey {
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 16px;
  padding: clamp(16px, 2.6vw, 24px);
  background:
    radial-gradient(120% 150% at 10% -20%, rgba(255,184,0,.08) 0%, transparent 40%),
    rgba(12,12,12,.82);
  box-shadow: 0 10px 28px rgba(0,0,0,.2);
}

.cs3-kicker {
  margin: 0;
  color: var(--primary-yellow);
  text-transform: uppercase;
  letter-spacing: .12em;
  font-size: .74rem;
  font-weight: 700;
  position: relative;
  display: inline-block;
  padding-bottom: 8px;
}

.cs3-kicker::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, var(--primary-yellow), transparent);
  border-radius: 1px;
}

.cs3-hero {
  display: grid;
  gap: clamp(14px, 2vw, 24px);
}

.cs3-hero-main h1 {
  margin: 10px 0 8px;
  /* .hero-title sizing lives in public.css (matches home hero) */
}

.cs3-lead {
  margin: 0;
  color: var(--text-gray);
  max-width: 64ch;
  line-height: 1.7;
}

.cs3-hero-meta {
  display: grid;
  gap: 10px;
}

.cs3-meta-card {
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 12px;
  padding: 12px;
  background: rgba(255,255,255,.03);
  min-height: 100%;
}

.cs3-meta-card h3 {
  margin: 0 0 6px;
  font-size: .76rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--text-gray);
}

.cs3-meta-card p,
.cs3-meta-card a {
  margin: 0;
  color: var(--primary-yellow);
  word-break: break-word;
}

.cs3-meta-card--inline {
  display: flex;
  align-items: baseline;
  gap: 8px;
  min-width: 0;
}

.cs3-meta-card--inline h3 {
  margin: 0;
  white-space: nowrap;
}

.cs3-meta-card--inline p,
.cs3-meta-card--inline a {
  margin: 0;
  min-width: 0;
  white-space: nowrap;
}

.cs3-deliverables-head h2 {
  margin: 0 0 6px;
  font-size: clamp(1.35rem, 3.5vw, 2rem);
}

.cs3-deliverables-head .cs3-deliverables-intro {
  margin: 0 0 30px;
  color: var(--text-gray);
}

.cs3-deliverables-head {
  padding-inline: clamp(8px, 1.8vw, 16px);
  padding-bottom: clamp(10px, 1.8vw, 18px);
  position: static;
  top: auto;
}

.cs3-brief {
  display: grid;
  gap: clamp(10px, 1.6vw, 16px);
}

.cs3-brief > .cs3-kicker {
  grid-column: 1 / -1;
  margin-bottom: 2px;
}

.cs3-brief-card {
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 12px;
  padding: 14px;
  background: rgba(255,255,255,.02);
  min-height: 100%;
}

.cs3-brief-card h2 {
  margin: 0 0 8px;
  font-size: 1.05rem;
}

.cs3-brief-card p {
  margin: 0;
  color: var(--text-gray);
  line-height: 1.65;
}

.cs3-deliverables-grid {
  display: grid;
  gap: clamp(12px, 1.8vw, 18px);
  margin-top: clamp(8px, 1.4vw, 14px);
}

.cs3-card {
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 14px;
  padding: 14px;
  background: rgba(8,8,8,.76);
  display: grid;
  align-content: start;
  transition: transform .24s ease, border-color .24s ease, box-shadow .24s ease;
}

.cs3-card:hover {
  transform: translateY(-2px);
  border-color: rgba(255,184,0,.32);
  box-shadow: 0 10px 24px rgba(0,0,0,.25);
}

.cs3-card h3 {
  margin: 0 0 6px;
  font-size: clamp(1rem, 2.3vw, 1.3rem);
}

.cs3-card p {
  margin: 0 0 10px;
  color: var(--text-gray);
  line-height: 1.6;
}

.cs3-frame {
  width: 100%;
  aspect-ratio: 16 / 10;
  border: 0;
  border-radius: 10px;
  background: #000;
}

.cs3-viewer {
  width: 100%;
  aspect-ratio: 16 / 10;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.12);
  background: #000;
}

.cs3-viewer img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.cs3-viewer img.floorplan-image {
  object-fit: contain;
  background: #fff;
}

.cs3-viewer img.zoomable {
  cursor: grab;
  transform-origin: center center;
  will-change: transform;
}

.cs3-viewer img.zoomable:active { cursor: grabbing; }

.cs3-controls {
  margin-top: 10px;
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

.cs3-zoom-btn {
  min-width: 44px;
  min-height: 44px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.22);
  background: rgba(20,20,20,.84);
  color: #fff;
  font-weight: 700;
  cursor: pointer;
  transition: border-color .2s ease, transform .2s ease;
}

.cs3-zoom-btn:hover {
  border-color: rgba(255,184,0,.6);
  transform: translateY(-1px);
}

.cs3-journey {
  display: grid;
  gap: clamp(12px, 2vw, 18px);
}

.cs3-workflow h2 {
  margin: 10px 0 12px;
}

.cs3-steps {
  display: grid;
  gap: clamp(10px, 1.6vw, 16px);
}

.cs3-step {
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 12px;
  padding: 12px;
  background: rgba(255,255,255,.02);
  min-height: 100%;
}

.cs3-step h3 {
  margin: 0 0 6px;
  font-size: .98rem;
}

.cs3-step p {
  margin: 0;
  color: var(--text-gray);
  line-height: 1.55;
}

.js-reveal {
  opacity: 0;
  transform: translateY(16px);
}

@media (max-width: 759px) {
  .cs3-nav {
    flex-direction: column;
  }
  .cs3-nav-btn:last-child {
    order: -1;
  }
}

@media (min-width: 760px) {
  .cs3-hero {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: stretch;
  }
  .cs3-hero-meta {
    grid-template-columns: 1fr;
  }
  .cs3-brief {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .cs3-deliverables-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-areas:
      "tour tour"
      "floor image";
  }
  .cs3-card--tour { grid-area: tour; }
  .cs3-card--floor { grid-area: floor; }
  .cs3-card--image { grid-area: image; }
  .cs3-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (min-width: 1100px) {
  .cs3-workflow {
    border-left: 0;
    padding-left: 0;
  }
  .cs3-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Match site hero media framing on case-study hero viewers */
.cs3-frame,
.cs3-viewer {
  border: 3px solid var(--primary-yellow);
  border-radius: 20px;
  box-shadow: 0 12px 48px rgba(0, 0, 0, 0.45), 0 0 40px rgba(255, 184, 0, 0.2);
  overflow: hidden;
}

/* Portfolio hub (/our-work) */
.cs3-portfolio-grid {
  display: grid;
  gap: clamp(12px, 2vw, 18px);
  grid-template-columns: 1fr;
}

/* Entire tile is one link (/our-work hub). */
a.cs3-portfolio-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  padding: clamp(16px, 2.4vw, 22px);
  background:
    radial-gradient(120% 120% at 10% -30%, rgba(255, 184, 0, 0.1), transparent 45%),
    rgba(12, 12, 12, 0.82);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.2);
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease,
    transform 0.2s ease;
}

a.cs3-portfolio-card:hover {
  border-color: rgba(255, 184, 0, 0.42);
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.28);
  transform: translateY(-2px);
}

a.cs3-portfolio-card:focus-visible {
  outline: 2px solid var(--primary-yellow);
  outline-offset: 3px;
}

a.cs3-portfolio-card--featured {
  border-color: rgba(255, 184, 0, 0.35);
}

a.cs3-portfolio-card--featured:hover {
  border-color: rgba(255, 184, 0, 0.55);
}

.cs3-portfolio-tag {
  margin: 0 0 8px;
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--primary-yellow);
  font-weight: 700;
}

.cs3-portfolio-card-title {
  margin: 0 0 10px;
  font-size: clamp(1.15rem, 2.8vw, 1.45rem);
  line-height: 1.2;
  color: #fff;
  font-weight: 700;
  transition: color 0.2s ease;
}

a.cs3-portfolio-card:hover .cs3-portfolio-card-title {
  color: var(--primary-yellow);
}

.cs3-portfolio-card-desc {
  margin: 0 0 12px;
  color: var(--text-gray);
  line-height: 1.65;
  max-width: 62ch;
}

.cs3-portfolio-card-cta {
  display: inline-block;
  margin-top: auto;
  font-weight: 700;
  color: var(--primary-yellow);
  font-size: 0.92rem;
  text-decoration: none;
  transition: text-decoration 0.15s ease;
}

a.cs3-portfolio-card:hover .cs3-portfolio-card-cta {
  text-decoration: underline;
}

.cs3-featured-case {
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  padding: clamp(16px, 2.6vw, 24px);
  background:
    radial-gradient(120% 150% at 10% -20%, rgba(255, 184, 0, 0.08) 0%, transparent 40%),
    rgba(12, 12, 12, 0.82);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.2);
  display: grid;
  gap: clamp(14px, 2vw, 20px);
}

.cs3-featured-head {
  padding-inline: clamp(4px, 1vw, 8px);
}

.cs3-featured-title {
  margin: 0 0 6px;
  font-size: clamp(1.2rem, 3vw, 1.65rem);
}

.cs3-featured-intro {
  margin: 0;
  color: var(--text-gray);
  line-height: 1.6;
}

.cs3-hero-meta--featured {
  margin-top: 0;
}

@media (min-width: 720px) {
  .cs3-portfolio-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  a.cs3-portfolio-card--featured {
    grid-column: 1 / -1;
  }
}

@media (prefers-reduced-motion: reduce) {
  a.cs3-portfolio-card {
    transition: none;
  }
  a.cs3-portfolio-card:hover {
    transform: none;
  }
}

.cs3-breadcrumb {
  font-size: 0.85rem;
  color: var(--text-gray);
  margin-bottom: clamp(8px, 1.5vw, 14px);
}

.cs3-breadcrumb a {
  color: var(--primary-yellow);
  text-decoration: none;
}

.cs3-breadcrumb a:hover {
  text-decoration: underline;
}

.cs3-breadcrumb-current {
  color: rgba(255, 255, 255, 0.72);
}

.cs3-back-link {
  margin: clamp(12px, 2vw, 20px) 0 0;
  text-align: center;
}

.cs3-back-link a {
  color: var(--primary-yellow);
  font-weight: 600;
  text-decoration: none;
}

.cs3-back-link a:hover {
  text-decoration: underline;
}
