.portfolio-hero-v2 {
  position: relative;
  overflow: hidden;
  padding: 54px 0 34px;
  background:
    radial-gradient(circle at 78% 18%, rgba(199,168,107,.12), transparent 28rem),
    linear-gradient(180deg, rgba(255,255,255,.015), transparent 45%),
    #0a0a09;
}

.portfolio-hero-v2::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: .28;
  background-image:
    linear-gradient(rgba(255,255,255,.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.028) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(to bottom, rgba(0,0,0,.9), transparent 80%);
}

.portfolio-hero-layout {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0,1.08fr) minmax(360px,.92fr);
  gap: clamp(28px, 5vw, 78px);
  align-items: center;
}

.portfolio-hero-copyblock {
  min-width: 0;
  padding: 28px 0 24px;
}

.portfolio-hero-v2 .portfolio-title {
  max-width: 8.3ch;
  font-size: clamp(68px, 8.1vw, 122px);
  line-height: .84;
}

.portfolio-hero-lead-v2 {
  max-width: 660px;
  margin-top: 34px;
  font-size: clamp(18px, 1.7vw, 25px);
  line-height: 1.45;
  color: rgba(242,239,232,.88);
}

.portfolio-hero-actions-v2 {
  margin-top: 24px;
}

.portfolio-hero-v2 .portfolio-proof-strip {
  margin-top: 34px;
}

.portfolio-hero-visual {
  position: relative;
  min-height: 690px;
  isolation: isolate;
}

.portfolio-hero-portrait-card {
  position: absolute;
  inset: 20px 0 54px 56px;
  overflow: hidden;
  border: 1px solid rgba(242,239,232,.14);
  border-radius: 28px;
  background: #11110f;
  box-shadow: 0 38px 120px rgba(0,0,0,.42);
}

.portfolio-hero-portrait-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(0,0,0,.02) 35%, rgba(0,0,0,.42) 100%),
    radial-gradient(circle at 70% 18%, rgba(199,168,107,.12), transparent 34%);
  pointer-events: none;
}

.portfolio-hero-portrait {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: 50% 28%;
  filter: saturate(.82) contrast(1.03) brightness(.92);
  transform: scale(1.01);
}

.portfolio-hero-portrait-caption {
  position: absolute;
  z-index: 2;
  left: 20px;
  right: 20px;
  bottom: 18px;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  color: #fff;
}

.portfolio-hero-portrait-caption span {
  font-family: 'DM Mono', monospace;
  font-size: 9px;
  letter-spacing: .13em;
}

.portfolio-hero-portrait-caption strong {
  font-family: 'Playfair Display', serif;
  font-weight: 500;
  font-size: 26px;
}

.portfolio-hero-mini-frame {
  position: absolute;
  z-index: 3;
  width: 170px;
  aspect-ratio: 4/5;
  left: 0;
  bottom: 0;
  overflow: hidden;
  border: 1px solid rgba(242,239,232,.16);
  border-radius: 18px;
  background: #11110f;
  box-shadow: 0 28px 80px rgba(0,0,0,.38);
  transform: rotate(-4deg);
}

.portfolio-hero-mini-frame img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.portfolio-hero-mini-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 48%, rgba(0,0,0,.62));
}

.portfolio-hero-mini-frame span {
  position: absolute;
  z-index: 2;
  left: 12px;
  bottom: 12px;
  font-family: 'DM Mono', monospace;
  font-size: 8px;
  letter-spacing: .12em;
  color: #fff;
}

.portfolio-hero-coordinate {
  position: absolute;
  z-index: 3;
  top: 3px;
  right: 10px;
  display: flex;
  gap: 14px;
  color: rgba(242,239,232,.48);
  font-family: 'DM Mono', monospace;
  font-size: 8px;
  letter-spacing: .12em;
}

.portfolio-hero-local-pill {
  position: absolute;
  z-index: 4;
  right: 18px;
  top: 38px;
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 0 12px;
  border: 1px solid rgba(242,239,232,.16);
  border-radius: 999px;
  background: rgba(10,10,9,.66);
  backdrop-filter: blur(14px);
  color: rgba(242,239,232,.82);
  font-family: 'DM Mono', monospace;
  font-size: 8px;
  letter-spacing: .12em;
}

.portfolio-hero-local-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #85d389;
  box-shadow: 0 0 0 5px rgba(133,211,137,.08);
}

.portfolio-hero-meta-row {
  position: relative;
  z-index: 1;
  margin-top: 12px;
  padding-top: 22px;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  border-top: 1px solid rgba(242,239,232,.1);
}

@media (hover: hover) {
  .portfolio-hero-portrait-card,
  .portfolio-hero-mini-frame {
    transition: transform .45s cubic-bezier(.2,.7,.2,1), border-color .3s ease, box-shadow .3s ease;
  }

  .portfolio-hero-visual:hover .portfolio-hero-portrait-card {
    transform: translateY(-5px) rotate(.35deg);
    border-color: rgba(199,168,107,.28);
    box-shadow: 0 46px 140px rgba(0,0,0,.48);
  }

  .portfolio-hero-visual:hover .portfolio-hero-mini-frame {
    transform: translate(-4px,-7px) rotate(-6deg);
    border-color: rgba(199,168,107,.3);
  }
}

@media (max-width: 980px) {
  .portfolio-hero-layout {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .portfolio-hero-v2 .portfolio-title {
    max-width: none;
    font-size: clamp(70px, 14vw, 112px);
  }

  .portfolio-hero-visual {
    min-height: 620px;
    margin-top: 8px;
  }

  .portfolio-hero-portrait-card {
    inset: 18px 34px 54px 64px;
  }
}

@media (max-width: 560px) {
  body {
    padding-bottom: calc(76px + env(safe-area-inset-bottom));
  }

  .portfolio-site {
    overscroll-behavior-x: none;
  }

  .portfolio-nav {
    padding-top: env(safe-area-inset-top);
    background: linear-gradient(180deg, rgba(10,10,9,.96), rgba(10,10,9,.78));
    border-bottom-color: rgba(242,239,232,.08);
  }

  .portfolio-nav-links {
    position: fixed;
    z-index: 60;
    left: 12px;
    right: 12px;
    bottom: calc(10px + env(safe-area-inset-bottom));
    width: auto;
    min-height: 58px;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 4px;
    padding: 5px;
    border: 1px solid rgba(242,239,232,.14);
    border-radius: 19px;
    background: rgba(14,14,12,.84);
    box-shadow: 0 20px 60px rgba(0,0,0,.42), inset 0 1px 0 rgba(255,255,255,.04);
    backdrop-filter: blur(22px) saturate(1.15);
    -webkit-backdrop-filter: blur(22px) saturate(1.15);
  }

  .portfolio-nav-links a {
    min-width: 0;
    min-height: 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 5px;
    border-radius: 14px;
    color: rgba(242,239,232,.68);
    font-family: 'DM Mono', monospace;
    font-size: 8px;
    letter-spacing: .04em;
    text-align: center;
    text-transform: uppercase;
    touch-action: manipulation;
  }

  .portfolio-nav-links a:last-child {
    color: #0d0d0b;
    background: #f2efe8;
  }

  .portfolio-nav-links a:active,
  .portfolio-btn:active,
  .portfolio-language button:active {
    transform: scale(.97);
  }

  .portfolio-hero-v2 {
    padding: 24px 0 28px;
  }

  .portfolio-hero-copyblock {
    padding-top: 10px;
    display: flex;
    flex-direction: column;
  }

  .portfolio-hero-v2 .portfolio-kicker {
    order: 1;
    margin-bottom: 16px;
  }

  .portfolio-hero-v2 .portfolio-title {
    order: 2;
    max-width: 7.2ch;
    font-size: clamp(54px, 17.4vw, 74px);
    line-height: .88;
  }

  .portfolio-hero-copyblock::after {
    content: "";
    order: 3;
    display: block;
    width: calc(100% + 8px);
    height: 292px;
    margin: 22px -4px 0;
    overflow: hidden;
    border: 1px solid rgba(242,239,232,.14);
    border-radius: 22px;
    background:
      linear-gradient(180deg, rgba(0,0,0,.01) 32%, rgba(0,0,0,.38) 100%),
      radial-gradient(circle at 72% 14%, rgba(199,168,107,.1), transparent 32%),
      url('/portfolio/nicolas-portrait.webp') center 23% / cover no-repeat;
    box-shadow: 0 28px 78px rgba(0,0,0,.38), inset 0 1px 0 rgba(255,255,255,.035);
  }

  .portfolio-hero-lead-v2 {
    order: 4;
    margin-top: 22px;
    font-size: 16.5px;
    line-height: 1.52;
  }

  .portfolio-hero-actions-v2 {
    order: 5;
    margin-top: 20px;
  }

  .portfolio-hero-v2 .portfolio-proof-strip {
    order: 6;
    margin-top: 24px;
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 5px;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
  }

  .portfolio-hero-v2 .portfolio-proof-strip::-webkit-scrollbar {
    display: none;
  }

  .portfolio-hero-v2 .portfolio-proof-item {
    flex: 0 0 auto;
    scroll-snap-align: start;
    white-space: nowrap;
  }

  .portfolio-hero-visual {
    display: none;
  }

  .portfolio-hero-meta-row {
    margin-top: 16px;
    padding-top: 16px;
    align-items: start;
    flex-direction: column;
  }

  #work .portfolio-shell {
    width: min(calc(100% - 24px), var(--pf-max));
  }

  .portfolio-work {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    margin: 0 -12px;
    padding: 0 12px 14px;
    border: 0;
    background: transparent;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: 12px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  .portfolio-work::-webkit-scrollbar {
    display: none;
  }

  .portfolio-work .portfolio-card {
    flex: 0 0 min(86vw, 338px);
    scroll-snap-align: center;
    overflow: hidden;
    border: 1px solid rgba(242,239,232,.13);
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(255,255,255,.018), transparent 42%), var(--pf-bg);
    box-shadow: 0 18px 52px rgba(0,0,0,.22);
  }

  .portfolio-work .portfolio-card-media {
    aspect-ratio: 4 / 3;
  }

  .portfolio-work .portfolio-card-body {
    min-height: 205px;
  }

  .portfolio-video {
    width: calc(100% + 8px);
    margin-left: -4px;
    border-radius: 16px;
    box-shadow: 0 24px 70px rgba(0,0,0,.32);
  }

  .portfolio-section-head {
    margin-bottom: 26px;
  }

  .portfolio-offer-box,
  .portfolio-portrait-wrap,
  .portfolio-instagram-grid {
    border-radius: 18px;
  }

  .portfolio-btn,
  .portfolio-language button,
  .portfolio-card-media,
  .portfolio-instagram-grid {
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
  }

  .portfolio-foot {
    padding-bottom: 22px;
  }
}

@media (max-width: 390px) {
  .portfolio-nav-links {
    left: 8px;
    right: 8px;
  }

  .portfolio-nav-links a {
    font-size: 7.5px;
  }

  .portfolio-hero-copyblock::after {
    height: 276px;
  }

  .portfolio-work .portfolio-card {
    flex-basis: 84vw;
  }
}

@media (prefers-reduced-motion: reduce) {
  .portfolio-hero-portrait-card,
  .portfolio-hero-mini-frame {
    transition: none;
  }

  .portfolio-hero-visual:hover .portfolio-hero-portrait-card,
  .portfolio-hero-visual:hover .portfolio-hero-mini-frame {
    transform: none;
  }

  .portfolio-nav-links,
  .portfolio-work,
  .portfolio-hero-v2 .portfolio-proof-strip {
    scroll-behavior: auto;
  }
}
