/* Homepage-only safeguards layered over the restored b3cbea7 hero. */
.rs-hero {
  margin-top: 32px;
  overflow: hidden;
  isolation: isolate;
}

.elementor-6 .elementor-element.elementor-element-ef5dcef.rs-hero {
  background-image: none;
}

.rs-hero__artwork {
  position: absolute;
  inset: 0;
  z-index: 0;
  --rs-hero-parallax-x: 0px;
  --rs-hero-parallax-y: 0px;
  --rs-hero-scroll-y: 0px;
  transform: translate3d(
    var(--rs-hero-parallax-x),
    calc(var(--rs-hero-parallax-y) + var(--rs-hero-scroll-y)),
    0
  );
}

.rs-hero__artwork-breathe {
  position: absolute;
  inset: 0;
  background-image: url("/assets/img/hero/hero-fresco-clean.webp");
  background-position: center 25%;
  background-repeat: no-repeat;
  background-size: cover;
  transform: scale(1);
  transform-origin: center center;
}

.rs-hero__renaissance-light {
  position: absolute;
  inset: -50px;
  background: radial-gradient(
    ellipse 42% 48% at 28% 30%,
    rgba(255, 224, 169, 0.035) 0%,
    rgba(255, 218, 151, 0.016) 42%,
    rgba(255, 210, 140, 0) 76%
  );
  pointer-events: none;
}

@media (min-width: 1101px) and (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  .rs-hero__artwork {
    inset: -3px;
  }
}

.rs-hero__portrait-layer {
  position: absolute;
  inset: 0;
  z-index: 0;
  --rs-hero-parallax-x: 0px;
  --rs-hero-parallax-y: 0px;
  --rs-hero-scroll-y: 0px;
  overflow: hidden;
  pointer-events: none;
  transform: translate3d(
    var(--rs-hero-parallax-x),
    calc(var(--rs-hero-parallax-y) + var(--rs-hero-scroll-y)),
    0
  );
}

.rs-hero__portrait-drift {
  position: absolute;
  inset: 0;
}

.rs-hero .rs-hero__portrait {
  position: absolute;
  top: 16%;
  bottom: auto;
  left: 5%;
  display: block;
  width: clamp(375px, 34.18vw, 875px);
  max-width: none;
  height: auto;
  filter: saturate(0.94) contrast(0.97) brightness(0.99) sepia(0.035)
    drop-shadow(0 10px 18px rgba(67, 44, 25, 0.14));
  transform: translateY(48px);
}

@media (min-width: 1101px) {
  .rs-hero .rs-hero__title {
    width: 46vw;
    max-width: none;
    font-size: clamp(38px, 3.516vw, 90px);
  }
}

@media (min-width: 2049px) {
  .elementor-6 .elementor-element.elementor-element-ef5dcef.rs-hero > .elementor-container {
    max-width: min(58.594vw, 1500px);
  }
}

.elementor-6 .elementor-element.elementor-element-ef5dcef.rs-hero > .elementor-background-overlay {
  z-index: 1;
}

.rs-hero__grain {
  position: absolute;
  inset: 0;
  z-index: 1;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180' viewBox='0 0 180 180'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.78' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url%28%23noise%29' opacity='.72'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 180px 180px;
  mix-blend-mode: soft-light;
  opacity: 0.028;
  pointer-events: none;
}

.elementor-6 .elementor-element.elementor-element-ef5dcef.rs-hero > .elementor-container {
  position: relative;
  z-index: 2;
  --rs-hero-scroll-content-y: 0px;
  --rs-hero-scroll-content-opacity: 1;
  opacity: var(--rs-hero-scroll-content-opacity);
  transform: translate3d(0, var(--rs-hero-scroll-content-y), 0);
}

@media (prefers-reduced-motion: no-preference) {
  .rs-hero__artwork {
    animation: rs-hero-artwork-entrance 1200ms cubic-bezier(0.22, 1, 0.36, 1) both;
  }

  .rs-hero__artwork-breathe {
    animation: rs-hero-artwork-breathe 24s ease-in-out infinite;
  }

  .rs-hero__renaissance-light {
    animation: rs-hero-renaissance-light 22s ease-in-out infinite;
  }

  .rs-hero.rs-hero--motion-paused .rs-hero__artwork-breathe,
  .rs-hero.rs-hero--motion-paused .rs-hero__renaissance-light,
  .rs-hero.rs-hero--motion-paused .rs-hero__portrait-drift {
    animation-play-state: paused;
  }

  .rs-hero__portrait-layer {
    animation: rs-hero-portrait-entrance 900ms cubic-bezier(0.22, 1, 0.36, 1) 160ms both;
  }

  .rs-hero__portrait-drift {
    animation: rs-hero-portrait-drift 16s ease-in-out infinite;
  }

  .rs-hero__eyebrow,
  .rs-hero .hero-skills,
  .rs-hero .hero-description,
  .rs-hero .elementor-element-3efdf8d {
    animation: rs-hero-content-entrance 720ms cubic-bezier(0.22, 1, 0.36, 1) both;
  }

  .rs-hero__eyebrow {
    animation-delay: 440ms;
  }

  .rs-hero__title-line-inner {
    animation: rs-hero-title-line-reveal 740ms cubic-bezier(0.22, 1, 0.36, 1) both;
  }

  .rs-hero__title-line:nth-child(1) .rs-hero__title-line-inner {
    animation-delay: 560ms;
  }

  .rs-hero__title-line:nth-child(2) .rs-hero__title-line-inner {
    animation-delay: 645ms;
  }

  .rs-hero__title-line:nth-child(3) .rs-hero__title-line-inner {
    animation-delay: 730ms;
  }

  .rs-hero__title-line:nth-child(4) .rs-hero__title-line-inner {
    animation-delay: 815ms;
  }

  .rs-hero .hero-skills {
    animation-delay: 920ms;
  }

  .rs-hero .hero-description {
    animation-delay: 1040ms;
  }

  .rs-hero .elementor-element-3efdf8d {
    animation-delay: 1160ms;
  }
}

@keyframes rs-hero-artwork-entrance {
  from {
    opacity: 0;
    transform: translate3d(
      var(--rs-hero-parallax-x),
      calc(var(--rs-hero-parallax-y) + var(--rs-hero-scroll-y)),
      0
    ) scale(1.012);
  }

  to {
    opacity: 1;
    transform: translate3d(
      var(--rs-hero-parallax-x),
      calc(var(--rs-hero-parallax-y) + var(--rs-hero-scroll-y)),
      0
    ) scale(1);
  }
}

@keyframes rs-hero-artwork-breathe {
  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.015);
  }
}

@keyframes rs-hero-portrait-entrance {
  from {
    opacity: 0;
    transform: translate3d(
      var(--rs-hero-parallax-x),
      calc(var(--rs-hero-parallax-y) + var(--rs-hero-scroll-y) + 12px),
      0
    ) scale(0.99);
  }

  to {
    opacity: 1;
    transform: translate3d(
      var(--rs-hero-parallax-x),
      calc(var(--rs-hero-parallax-y) + var(--rs-hero-scroll-y)),
      0
    ) scale(1);
  }
}

@keyframes rs-hero-renaissance-light {
  0%,
  100% {
    transform: translate3d(-20px, 5px, 0);
  }

  50% {
    transform: translate3d(20px, -5px, 0);
  }
}

@keyframes rs-hero-portrait-drift {
  0%,
  100% {
    transform: translate3d(0, 0, 0);
  }

  50% {
    transform: translate3d(1px, -2px, 0);
  }
}

@keyframes rs-hero-content-entrance {
  from {
    opacity: 0;
    transform: translateY(12px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes rs-hero-title-line-reveal {
  from {
    opacity: 0;
    transform: translateY(105%);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.rs-hero__title-line {
  display: block;
  overflow: hidden;
}

.rs-hero__title-line-inner {
  display: inline-block;
  max-width: 100%;
}

.elementor-6 .elementor-element.elementor-element-c0c06a9 .hero-skills {
  font-size: 18px;
  font-weight: 600;
  line-height: 1.5;
}

.elementor-6 .elementor-element.elementor-element-c0c06a9 .hero-description {
  font-size: 17.5px;
  line-height: 1.55;
}

.rs-hero .rs-hero__eyebrow {
  font-family: "Rubik", sans-serif;
}

#hero-linkedin-cta:focus-visible {
  outline: 3px solid #f9c349 !important;
  outline-offset: 4px !important;
}

.rs-hero__cta {
  transition:
    transform 220ms cubic-bezier(0.22, 1, 0.36, 1),
    color 220ms ease,
    background-color 220ms ease,
    border-color 220ms ease;
}

.rs-hero__cta-arrow {
  display: inline-block;
  transition: transform 220ms cubic-bezier(0.22, 1, 0.36, 1);
}

@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  .rs-hero__cta:hover {
    transform: translateY(-1px);
  }

  .rs-hero__cta:hover .rs-hero__cta-arrow {
    transform: translateX(5px);
  }
}

@media (prefers-reduced-motion: no-preference) {
  .rs-hero__cta:focus-visible {
    transform: translateY(-1px);
  }

  .rs-hero__cta:focus-visible .rs-hero__cta-arrow {
    transform: translateX(5px);
  }
}

/* Keep the original desktop artwork; adapt only when its composition breaks. */
@media (max-width: 1100px) {
  .elementor-6 .elementor-element.elementor-element-ef5dcef.rs-hero {
    display: flex;
    min-height: max(880px, 100svh);
    margin-top: 29px;
    padding: 0;
  }

  .rs-hero__artwork-breathe {
    background-position: 14% 25%;
  }

  .rs-hero .rs-hero__portrait {
    top: clamp(112px, 16vw, 150px);
    bottom: auto;
    left: clamp(-44px, -5vw, -18px);
    width: min(110vw, 720px);
  }

  .elementor-6 .elementor-element.elementor-element-ef5dcef.rs-hero > .elementor-background-overlay {
    opacity: 1;
    background: linear-gradient(
      180deg,
      rgba(27, 31, 41, 0.08) 0%,
      rgba(27, 31, 41, 0.12) 38%,
      rgba(27, 31, 41, 0.5) 64%,
      rgba(27, 31, 41, 0.74) 100%
    );
    mix-blend-mode: normal;
  }

  .elementor-6 .elementor-element.elementor-element-ef5dcef.rs-hero > .elementor-container {
    align-items: flex-end;
    width: 100%;
    max-width: none;
    min-height: inherit;
    margin: 0;
    padding: 0 clamp(32px, 6vw, 52px) clamp(48px, 6vh, 72px);
    box-sizing: border-box;
  }

  .elementor-6 .elementor-element.elementor-element-a2c7bce.elementor-column {
    width: 100%;
  }

  .elementor-6 .elementor-element.elementor-element-a2c7bce > .elementor-widget-wrap {
    align-content: flex-end;
    width: min(100%, 700px);
    margin: 0;
    padding: 0;
  }

  .elementor-6 .elementor-element.elementor-element-267eeb7 .elementor-heading-title {
    font-size: clamp(2.7rem, 6.4vw, 3.35rem);
    line-height: 1.22;
  }
}

@media (min-width: 922px) and (max-width: 1100px) {
  .elementor-6 .elementor-element.elementor-element-a2c7bce > .elementor-widget-wrap {
    width: min(100%, 780px);
  }
}

@media (max-width: 560px) {
  .elementor-6 .elementor-element.elementor-element-ef5dcef.rs-hero {
    min-height: max(780px, 100svh);
    margin-top: 18px;
  }

  .rs-hero__artwork-breathe {
    background-position: 12% 25%;
  }

  .rs-hero .rs-hero__portrait {
    top: 115px;
    left: -22px;
    width: min(110vw, 520px);
  }

  .elementor-6 .elementor-element.elementor-element-ef5dcef.rs-hero > .elementor-background-overlay {
    background: linear-gradient(
      180deg,
      rgba(27, 31, 41, 0.06) 0%,
      rgba(27, 31, 41, 0.1) 36%,
      rgba(27, 31, 41, 0.46) 60%,
      rgba(27, 31, 41, 0.72) 100%
    );
  }

  .elementor-6 .elementor-element.elementor-element-ef5dcef.rs-hero > .elementor-container {
    padding: 0 24px calc(34px + env(safe-area-inset-bottom));
  }

  .elementor-6 .elementor-element.elementor-element-267eeb7 .elementor-heading-title {
    font-size: clamp(2.15rem, 10vw, 2.5rem);
    line-height: 1.3;
    letter-spacing: -0.025em;
  }

  .elementor-6 .elementor-element.elementor-element-c0c06a9 .hero-skills {
    font-size: 15px;
  }

  .elementor-6 .elementor-element.elementor-element-c0c06a9 .hero-description {
    font-size: 15.5px;
  }

  .elementor-6 .elementor-element.elementor-element-3efdf8d .elementor-button {
    min-height: 48px;
    padding: 15px 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .rs-hero__artwork,
  .rs-hero__portrait-layer,
  .rs-hero__eyebrow,
  .rs-hero .hero-skills,
  .rs-hero .hero-description,
  .rs-hero .elementor-element-3efdf8d {
    animation: none;
    opacity: 1;
    transform: none;
  }

  .rs-hero__title-line {
    overflow: visible;
  }

  .rs-hero__title-line-inner {
    animation: none;
    opacity: 1;
    transform: none;
  }

  .rs-hero__artwork-breathe {
    animation: none;
    transform: none;
  }

  .rs-hero__renaissance-light {
    animation: none;
    display: none;
    transform: none;
  }

  .rs-hero__portrait-drift {
    animation: none;
    transform: none;
  }

  .elementor-6 .elementor-element.elementor-element-ef5dcef.rs-hero > .elementor-container {
    opacity: 1;
    transform: none;
  }

  .rs-hero__cta,
  .rs-hero__cta-arrow {
    transition: none;
  }
}
