/* Overrides on top of all.css (the old site's stylesheet, kept as-is) for things the
   old jQuery plugins used to do with inline styles. */

/* Pictures replace Picturefill's <span>s; keep them out of the inline flow. */
picture { display: block; }
.portfolio img, .slide img { max-width: none; }

/* Desktop dropdowns open on hover (the TouchNav plugin added a .hover class). */
@media only screen and (min-width: 768px) {
  #nav > li:hover > .drop { left: -26px; }
  #nav .drop li:hover > .drop { left: 100%; }
}

/* On phones the menu shows the Home link even on the home page. */
@media only screen and (max-width: 767px) {
  #nav a.home-link { display: block; }
}

/* Slideshows: stack the slides in one grid cell so the box takes the image's height
   (the old code measured it with JavaScript), and fade between them. */
.slideshow-home,
.lightbox .slideshow { height: auto; }
.slideshow .slideset { display: grid; }
.slideshow-home .slide,
.lightbox .slideshow .slide {
  position: relative;
  grid-area: 1 / 1;
  height: auto;
  opacity: 0;
  transition: opacity 0.5s ease;
}
.slideshow .slide.active { opacity: 1; }

/* The lightbox's image box keeps the jewelry photos' 3:2 shape. */
.lightbox .slideshow .slide img { width: 100%; height: auto; }
.lightbox { max-width: 100%; }

/* Portfolio category menu: on phones it opens from the "open" button. */
@media only screen and (max-width: 767px) {
  .menu-holder:not(.active) .menu-box { display: none; }
}

/* The four C's clarity and color pickers. */
.box-button .visual[hidden],
#colors .visual[hidden] { display: none; }

/* all.css sized the grid around the whitespace between the template's <li>s
   (margin:-3px); React renders none, so drop the negative margin. */

.portfolio { font-size: 0; }
.portfolio li { margin: 0; vertical-align: bottom; }
