/* Local Nirvana fixes. Baseline styles use the existing published r153 assets. */
/* Product-gallery videos share the image stage's explicit bounds. A portrait
   video's intrinsic grid minimum must not enlarge the child past the clipped
   slide. Contain preserves the entire recording and its native aspect ratio. */
.nv-pdp .nv-gallery__slide--video {
    min-width: 0;
    min-height: 0;
}
.nv-pdp .nv-gallery__slide--video > video {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    min-width: 0;
    min-height: 0;
    max-width: 100%;
    max-height: 100%;
    margin: 0;
    padding: 0;
    object-fit: contain;
    object-position: center;
    transform: none;
}

/* Borderless product video on phones/tablets: native desktop controls remain. */
.nv-video-controls[hidden] { display: none; }
@media (max-width: 1023px) {
  .nv-pdp .nv-gallery__slide--video,
  .nv-pdp .nv-gallery__slide--video > video { border: 0; outline: 0; box-shadow: none; border-radius: 0; }
  .nv-pdp .nv-video-controls { position: absolute; right: .75rem; bottom: .75rem; z-index: 4; display: flex; align-items: center; gap: .5rem; padding: 0; margin: 0; border: 0; background: transparent; box-shadow: none; }
  .nv-pdp .nv-video-controls[hidden] { display: none; }
  .nv-pdp .nv-video-controls button { display: grid; place-items: center; width: 44px; height: 44px; padding: 10px; margin: 0; border: 0; border-radius: 50%; background: rgba(255,255,255,.9); color: #1b1917; box-shadow: none; cursor: pointer; }
  .nv-pdp .nv-video-controls svg { display: block; width: 24px; height: 24px; }
  .nv-pdp .nv-video-controls button:focus-visible { outline: 2px solid var(--nv-action,#9a5b2e); outline-offset: 2px; }
  .nv-pdp .nv-gallery:has(.nv-gallery__thumb--video[aria-selected="true"]) .nv-gallery__counter { top: .75rem; bottom: auto; }
}
/* A product video must be identifiable in the thumbnail rail at every width. */
.nv-pdp .nv-gallery__thumb--video .nv-gallery__play {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: grid;
    place-items: center;
    color: #fff;
    pointer-events: none;
}
.nv-pdp .nv-gallery__thumb--video .nv-gallery__play svg {
    display: block;
    width: 28px;
    height: 28px;
    padding: 6px;
    border: 0;
    border-radius: 50%;
    background: rgba(27,25,23,.82);
    color: #fff;
    fill: currentColor;
}
/* Keep the mobile product player borderless even when the swipe track receives
   focus. Thumbnail and individual control keyboard focus indicators remain. */
@media (max-width: 1023px) {
  .nv-pdp .nv-gallery,
  .nv-pdp .nv-gallery__stage,
  .nv-pdp .nv-gallery__slides,
  .nv-pdp .nv-gallery__slides:focus,
  .nv-pdp .nv-gallery__slides:focus-visible,
  .nv-pdp .nv-gallery__slide--video,
  .nv-pdp .nv-gallery__slide--video > video,
  .nv-pdp .nv-gallery__slide--video > video:focus,
  .nv-pdp .nv-gallery__slide--video > video:focus-visible {
    border: 0 !important;
    outline: none !important;
    box-shadow: none !important;
    border-radius: 0;
  }
}
/* Explicitly clip the right/bottom raster edge of mobile video slides. This
   also clips compositor-edge artifacts which border/outline resets cannot
   remove. Only one rendered pixel of the edge is masked; media bytes and
   object-fit, thumbnail focus and player controls stay unchanged. */
@media (max-width: 1023px) {
  .nv-pdp .nv-gallery__slide--video {
    overflow: hidden;
    isolation: isolate;
    -webkit-clip-path: inset(0 1px 1px 0);
    clip-path: inset(0 1px 1px 0);
  }
}
/* Selected native SKU remains the only source of stock and purchase state. */
.nv-pdp [data-nv-badge-sold][hidden], .nv-pdp [data-nv-badge-sale][hidden] { display: none !important; }
.nv-pdp .nv-tile__media { width: 52px; height: 52px; border-radius: 50%; }
.nv-pdp .nv-tile__media img { border-radius: 50%; object-fit: cover; padding: 0; }
.nv-pdp .nv-tile__name { white-space: normal; overflow: visible; min-height: 2.4em; }

/* Keep the complete product recognisable in its colour thumbnail. */
.nv-pdp .nv-tile__media img { transform: none; object-fit: contain; padding: 4%; }
.nv-pdp .nv-tile[aria-pressed="true"] .nv-tile__media { outline: none !important; outline-offset: 0; }
/* Existing refinements draw the selection with an inset shadow. Keyboard
   focus reuses that one ring, changing its colour instead of adding a ring. */
.nv-pdp .nv-option__values--tiles > .nv-tile:focus-visible .nv-tile__media { outline: none !important; outline-offset: 0; box-shadow: inset 0 0 0 2px var(--nv-ink,#292929) !important; }

/* Match the adjacent collection headers: title left, shop action right. */
.nv-home section[aria-labelledby="NirvanaRangeHeading"] > .nv-section__head {
  display: flex; flex-wrap: nowrap; align-items: flex-end;
  justify-content: space-between; gap: 12px;
}
.nv-home section[aria-labelledby="NirvanaRangeHeading"] > .nv-section__head > div {
  flex: 1 1 auto; width: auto; min-width: 0;
}
.nv-home section[aria-labelledby="NirvanaRangeHeading"] > .nv-section__head > .nv-btn {
  flex: 0 0 auto;
}
@media (max-width: 479px) {
  .nv-home section[aria-labelledby="NirvanaRangeHeading"] > .nv-section__head .nv-h2 { font-size: 1.125rem; }
  .nv-home section[aria-labelledby="NirvanaRangeHeading"] > .nv-section__head .nv-lead { font-size: .75rem; }
  .nv-home section[aria-labelledby="NirvanaRangeHeading"] > .nv-section__head > .nv-btn {
    padding-inline: .625rem; font-size: .6rem; letter-spacing: .04em;
  }
}
