/* Referral Program — v6.0.9 premium editorial redesign (F banner, ink + ivory + gold). */
.walsh-ref-page {
  --g: #c9a96a;
  --g-deep: #9c7d45;
  --ink: #0d0d0d;
  --ink-2: #161616;
  --ivory: #f6f1e8;
  --paper: #fff;
  --text: #3a3a3a;
  --wrap: min(1180px, calc(100% - 80px));
  --pad: 104px;
  overflow: clip;
  background: var(--paper);
  color: var(--text);
  font-family: var(--walsh-font-body);
}
.walsh-ref-page *, .walsh-ref-page *::before, .walsh-ref-page *::after { box-sizing: border-box; }
.walsh-ref-page p { margin: 0 0 16px; }
.walsh-ref-page p:last-child { margin-bottom: 0; }
.walsh-ref-page h1, .walsh-ref-page h2, .walsh-ref-page h3 {
  margin-top: 0;
  color: var(--ink);
  font-family: var(--walsh-font-heading);
  font-weight: 600;
  letter-spacing: 0;
}
.walsh-ref-page figure { margin: 0; }
.walsh-ref-page img { display: block; max-width: 100%; }

/* Shared heading rule */
.walsh-ref-copy h2, .walsh-ref-work__copy > h2, .walsh-ref-centered h2, .walsh-ref-participate h2 {
  position: relative;
  padding-bottom: 22px;
  margin-bottom: 28px;
  font-size: 42px;
  line-height: 1.15;
}
.walsh-ref-copy h2::after, .walsh-ref-work__copy > h2::after, .walsh-ref-centered h2::after, .walsh-ref-participate h2::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 64px;
  height: 2px;
  background: var(--g);
}
.walsh-ref-centered h2::after, .walsh-ref-participate h2::after { left: 50%; transform: translateX(-50%); }

/* 1. F banner */
.walsh-ref-hero {
  position: relative;
  display: flex;
  height: 300px;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: var(--ink);
}
.walsh-ref-hero > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 35%; animation: walshRefZoom 14s ease-out forwards; transform: scale(1.06); }
@keyframes walshRefZoom { to { transform: scale(1); } }
.walsh-ref-hero__shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(13,13,13,.55), rgba(13,13,13,.72)); }
.walsh-ref-hero h1 {
  position: relative;
  z-index: 2;
  max-width: calc(100% - 48px);
  margin: 0;
  padding: 22px 56px;
  border: 1px solid var(--g);
  background: rgba(13, 13, 13, .45);
  color: #fff;
  font-size: 46px;
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: .08em;
  text-align: center;
  text-transform: uppercase;
}
/* Old markup safety: if intro still sits inside the banner, hide it there. */
.walsh-ref-hero__copy { position: relative; z-index: 2; display: contents; }
.walsh-ref-hero .walsh-ref-eyebrow, .walsh-ref-hero .walsh-ref-hero__intro { display: none; }

/* 2. Lead */
.walsh-ref-lead {
  padding: 88px max(24px, calc((100% - 860px) / 2)) 92px;
  background: var(--ivory);
  text-align: center;
}
.walsh-ref-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  margin: 0 0 26px !important;
  color: var(--g-deep);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .3em;
  line-height: 1.4;
  text-transform: uppercase;
}
.walsh-ref-eyebrow::before, .walsh-ref-eyebrow::after { content: ""; width: 44px; height: 1px; background: var(--g); }
.walsh-ref-hero__intro { color: #242424; font-family: var(--walsh-font-heading); font-size: 23px; font-weight: 400; line-height: 1.65; }
.walsh-ref-hero__intro p + p { margin-top: 20px; color: #555; font-family: var(--walsh-font-body); font-size: 16px; font-weight: 300; line-height: 1.8; }

/* 3. Split sections (Why? + Selling) */
.walsh-ref-split {
  display: grid;
  width: var(--wrap);
  margin: 0 auto;
  padding: var(--pad) 0;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
  gap: 88px;
}
.walsh-ref-media { position: relative; aspect-ratio: 5 / 4; }
.walsh-ref-media::before {
  content: "";
  position: absolute;
  inset: 22px -22px -22px 22px;
  border: 1px solid var(--g);
  pointer-events: none;
}
.walsh-ref-media img { position: relative; z-index: 1; width: 100%; height: 100%; object-fit: cover; }
.walsh-ref-copy { min-width: 0; font-size: 16px; font-weight: 300; line-height: 1.85; }
.walsh-ref-split--selling { background: transparent; }
.walsh-ref-split--selling .walsh-ref-media { order: 2; }
.walsh-ref-split--selling .walsh-ref-media::before { inset: 22px 22px -22px -22px; }

/* 4. Video + selling intro: one continuous dark block */
.walsh-ref-video {
  position: relative;
  width: 100%;
  margin: 0;
  padding: var(--pad) max(40px, calc((100% - 1180px) / 2)) 0;
  background: var(--ink);
}
.walsh-ref-video::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 50%;
  background: var(--paper);
}
.walsh-ref-video__media {
  position: relative;
  z-index: 1;
  width: 100%;
  aspect-ratio: 16 / 8;
  object-fit: cover;
  object-position: center;
  border: 1px solid var(--g);
  box-shadow: 0 40px 80px -40px rgba(0, 0, 0, .6);
  background: #111;
}
.walsh-ref-video__photo { aspect-ratio: auto; height: auto; object-fit: contain; background: transparent; }
.walsh-ref-video__play {
  position: absolute;
  z-index: 2;
  top: calc(50% + var(--pad) / 2);
  left: 50%;
  display: grid;
  width: 84px;
  height: 84px;
  place-items: center;
  padding: 0 0 0 5px;
  border: 1px solid var(--g);
  border-radius: 50%;
  background: rgba(13, 13, 13, .55);
  color: var(--g);
  font: inherit;
  font-size: 22px;
  cursor: pointer;
  transform: translate(-50%, -50%);
  transition: background-color .25s ease, opacity .25s ease;
}
.walsh-ref-video__play:hover, .walsh-ref-video__play:focus-visible { background: rgba(13, 13, 13, .85); }
.walsh-ref-video.is-playing .walsh-ref-video__play { opacity: 0; pointer-events: none; }
.walsh-ref-centered {
  padding: 88px max(24px, calc((100% - 820px) / 2)) var(--pad);
  background: var(--ink);
  text-align: center;
}
.walsh-ref-centered h2 { display: inline-block; color: #fff; }
.walsh-ref-centered div { color: rgba(255, 255, 255, .74); font-size: 17px; font-weight: 300; line-height: 1.85; }

/* 5. How it works */
.walsh-ref-work {
  display: grid;
  width: 100%;
  margin: 0;
  padding: var(--pad) max(40px, calc((100% - 1180px) / 2));
  grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
  align-items: center;
  gap: 80px;
  background: var(--ivory);
  counter-reset: walshref;
}
.walsh-ref-work__copy { min-width: 0; }
.walsh-ref-detail {
  position: relative;
  margin-top: 22px;
  padding: 30px 32px 30px 96px;
  border: 1px solid rgba(201, 169, 106, .35);
  background: var(--paper);
  color: #4a4a4a;
  font-size: 15px;
  font-weight: 300;
  line-height: 1.75;
  counter-increment: walshref;
  transition: border-color .3s ease, box-shadow .3s ease;
}
.walsh-ref-detail:hover { border-color: var(--g); box-shadow: 0 24px 48px -32px rgba(0, 0, 0, .35); }
.walsh-ref-detail::before {
  content: "0" counter(walshref);
  position: absolute;
  top: 28px;
  left: 32px;
  color: var(--g);
  font-family: var(--walsh-font-heading);
  font-size: 30px;
  line-height: 1;
}
.walsh-ref-detail h3 { margin-bottom: 10px; font-size: 21px; line-height: 1.35; }
.walsh-ref-work__media { position: relative; aspect-ratio: 4 / 5; }
.walsh-ref-work__media::before { content: ""; position: absolute; inset: -18px 18px 18px -18px; border: 1px solid var(--g); pointer-events: none; }
.walsh-ref-work__media img { position: relative; z-index: 1; width: 100%; height: 100%; object-fit: cover; }

/* 6. How to participate */
.walsh-ref-participate { position: relative; display: grid; min-height: 420px; place-items: center; overflow: hidden; padding: 90px 0; }
.walsh-ref-participate__bg { position: absolute; inset: -75vh 0; background-image: var(--walsh-ref-participate-image); background-position: center; background-size: cover; transform: translate3d(0, var(--walsh-ref-fixed-y, 0), 0); will-change: transform; }
.walsh-ref-participate__shade { position: absolute; inset: 0; background: rgba(13, 13, 13, .76); }
.walsh-ref-participate__copy { position: relative; z-index: 1; width: min(780px, calc(100% - 48px)); color: #fff; text-align: center; }
.walsh-ref-participate h2 { display: inline-block; color: #fff; }
.walsh-ref-participate p { color: rgba(255, 255, 255, .86); font-family: var(--walsh-font-heading); font-size: 21px; font-weight: 400; line-height: 1.7; }

/* 7. Opportunities */
.walsh-ref-opportunities { padding: var(--pad) 40px; background: var(--ink); }
.walsh-ref-opportunities__inner { display: grid; width: min(1180px, 100%); margin: 0 auto; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px; }
.walsh-ref-opportunity {
  position: relative;
  padding: 52px 44px 48px;
  border: 1px solid rgba(201, 169, 106, .28);
  background: var(--ink-2);
  color: rgba(255, 255, 255, .72);
  font-size: 15.5px;
  font-weight: 300;
  line-height: 1.8;
  transition: border-color .35s ease, transform .35s ease;
}
.walsh-ref-opportunity::after { content: ""; position: absolute; top: -1px; left: -1px; width: 88px; height: 3px; background: var(--g); transition: width .45s ease; }
.walsh-ref-opportunity:hover { border-color: rgba(201, 169, 106, .7); transform: translateY(-4px); }
.walsh-ref-opportunity:hover::after { width: calc(100% + 2px); }
.walsh-ref-opportunity::before { display: block; margin-bottom: 18px; color: var(--g); font-family: var(--walsh-font-heading); font-size: 34px; line-height: 1; }
.walsh-ref-opportunity:nth-child(1)::before { content: "01"; }
.walsh-ref-opportunity:nth-child(2)::before { content: "02"; }
.walsh-ref-opportunity h2 { margin-bottom: 20px; color: #fff; font-size: 28px; line-height: 1.3; }

/* Centered alignment option */
.walsh-ref-page--center .walsh-ref-copy, .walsh-ref-page--center .walsh-ref-work__copy > h2 { text-align: center; }
.walsh-ref-page--center .walsh-ref-copy h2::after, .walsh-ref-page--center .walsh-ref-work__copy > h2::after { left: 50%; transform: translateX(-50%); }

/* Tablet */
@media (max-width: 1023px) {
  .walsh-ref-page { --wrap: calc(100% - 64px); --pad: 76px; }
  .walsh-ref-hero { height: 260px; }
  .walsh-ref-hero h1 { padding: 20px 36px; font-size: 36px; }
  .walsh-ref-lead { padding: 68px 48px 72px; }
  .walsh-ref-hero__intro { font-size: 20px; }
  .walsh-ref-copy h2, .walsh-ref-work__copy > h2, .walsh-ref-centered h2, .walsh-ref-participate h2 { font-size: 34px; }
  .walsh-ref-split { grid-template-columns: 1fr; gap: 64px; }
  .walsh-ref-split .walsh-ref-media, .walsh-ref-split--selling .walsh-ref-media { order: 0; width: calc(100% - 22px); aspect-ratio: 16 / 10; }
  .walsh-ref-video { padding-left: 32px; padding-right: 32px; }
  .walsh-ref-split--selling .walsh-ref-media { margin-left: 22px; }
  .walsh-ref-work { grid-template-columns: 1fr; gap: 64px; padding-left: 32px; padding-right: 32px; }
  .walsh-ref-work__media { order: -1; width: calc(100% - 18px); margin-left: 18px; aspect-ratio: 16 / 10; }
  .walsh-ref-participate { min-height: 380px; }
  .walsh-ref-opportunities { padding: var(--pad) 32px; }
  .walsh-ref-opportunities__inner { gap: 22px; }
  .walsh-ref-opportunity { padding: 44px 30px 40px; }
  .walsh-ref-opportunity h2 { font-size: 24px; }
}

/* Mobile */
@media (max-width: 767px) {
  .walsh-ref-page { --wrap: calc(100% - 40px); --pad: 60px; }
  .walsh-ref-hero { height: 190px; }
  .walsh-ref-hero h1 { max-width: calc(100% - 40px); padding: 14px 18px; font-size: 21px; letter-spacing: .06em; }
  .walsh-ref-lead { padding: 52px 22px 56px; }
  .walsh-ref-eyebrow { gap: 10px; font-size: 11px; letter-spacing: .22em; }
  .walsh-ref-eyebrow::before, .walsh-ref-eyebrow::after { width: 22px; }
  .walsh-ref-hero__intro { font-size: 18px; line-height: 1.6; }
  .walsh-ref-hero__intro p + p { font-size: 15px; }
  .walsh-ref-copy h2, .walsh-ref-work__copy > h2, .walsh-ref-centered h2, .walsh-ref-participate h2 { padding-bottom: 18px; margin-bottom: 22px; font-size: 28px; line-height: 1.2; }
  .walsh-ref-split { gap: 48px; }
  .walsh-ref-split .walsh-ref-media, .walsh-ref-split--selling .walsh-ref-media { width: calc(100% - 14px); aspect-ratio: 4 / 3; }
  .walsh-ref-media::before { inset: 14px -14px -14px 14px; }
  .walsh-ref-split--selling .walsh-ref-media { margin-left: 14px; }
  .walsh-ref-split--selling .walsh-ref-media::before { inset: 14px 14px -14px -14px; }
  .walsh-ref-copy { font-size: 15px; line-height: 1.8; }
  .walsh-ref-video { padding: var(--pad) 20px 0; }
  .walsh-ref-video__media { aspect-ratio: 16 / 10; }
  .walsh-ref-page img.walsh-ref-video__photo { aspect-ratio: auto; }
  .walsh-ref-video::before { display: none; }
  .walsh-ref-video__play { width: 60px; height: 60px; font-size: 17px; }
  .walsh-ref-centered { padding: 56px 22px var(--pad); }
  .walsh-ref-centered div { font-size: 15px; }
  .walsh-ref-work { gap: 48px; padding: var(--pad) 20px; }
  .walsh-ref-work__media { width: calc(100% - 14px); margin-left: 14px; aspect-ratio: 4 / 3; }
  .walsh-ref-work__media::before { inset: -14px 14px 14px -14px; }
  .walsh-ref-detail { padding: 68px 22px 26px; }
  .walsh-ref-detail::before { top: 24px; left: 22px; font-size: 26px; }
  .walsh-ref-detail h3 { font-size: 19px; }
  .walsh-ref-participate { min-height: 0; padding: 72px 0; }
  .walsh-ref-participate__bg { inset: -45vh 0; }
  .walsh-ref-participate__copy { width: calc(100% - 40px); }
  .walsh-ref-participate p { font-size: 18px; }
  .walsh-ref-opportunities { padding: var(--pad) 20px; }
  .walsh-ref-opportunities__inner { grid-template-columns: 1fr; gap: 20px; }
  .walsh-ref-opportunity { padding: 40px 24px 34px; font-size: 15px; }
  .walsh-ref-opportunity h2 { font-size: 23px; }
}

@media (prefers-reduced-motion: reduce) {
  .walsh-ref-hero > img { animation: none; transform: none; }
  .walsh-ref-page .walsh-reveal { opacity: 1; transform: none; transition: none; }
}
