/* Thank you Kyle https://youtu.be/9HcxHDS2w1s?feature=shared */

*, *::before, *::after {
  box-sizing: border-box;
}

body {
  background-color:white;
  width: 100%;
  max-width: 500px;
  margin:0 auto;
}    

h1 {
  color: black;
}

figure img {
  width: 100%;
}

figcaption {
  font-size: 50%;
  text-align: center;
}

#outerContainer {
  background-color: var(--gs1-color-lavender);
}

#topContainer {
  height:5.5em;
}

#topNavigation {
  height: 1em;
}

#topNavigation nav {
  font-weight: bold;
  font-size: 2em;
  padding-left: .5em;
}

/* Main images */
img.singleImage {
  width:10em;
  height: 10em;
  object-fit: cover;
  border-radius:10em;
  display:block;
  margin: 0 auto;
}

#carousel {
  width:100%;
  position: relative;
}

#carousel ul {
  padding: 0;
  margin: 0;
  list-style: none;
}

#carousel .slide {
  position: absolute;
  inset:0;
  opacity: 0;
  transition: 200ms opacity ease-in-out;
  transition-delay: 200ms;
}

#carousel .slide[data-active] {
  opacity: 1;
  z-index: 1;
  transition-delay: 0ms;
}

#carousel .slide img {
  width:100%;
  display: block;
  object-fit: cover;
  object-position: center;
  height: 300px;
}

#carousel .carousel-button {
  position: absolute;
  top: 130px;
  z-index: 2;
  width:30px;
  background-color: var(--gs1-color-blue);
  color: white;
  border-radius: 30px;
  cursor: pointer;
  font-size: 10px;
}

#carousel > button.next {
  right: 0;
}

#carousel .carousel-button img {
    width:100%;
}

#carousel .carousel-button:hover, #carousel .carousel-button:focus {
  background-color: var(--gs1-color-slate);
}


main {
  background-color: white;
  border-radius: 3em 3em 0 0;
  border: thin solid black;
  margin: 0;
  padding:7em .5em .5em .5em;
}


#romanceCopy {
  font-size:80%;
}

span.visualBreak { /* defines the little horizontal lines above and below the romance copy */
  background-color: var(--gs1-color-lavender);
  width:20%;
  height: 0.2em;
  display: block;
  margin: 1em 0;
}

/* The 2 lines of info on menu page */

#info .infoI {
  display: block;
  width: 1.5em;
  height: 1.5em;
  border-radius: 1.5em;
  background-color: var(--gs1-color-lavender);
  color: white;
  text-align: center;
  font-weight: bold;
  line-height: 1.5em;
  float:left;
}

#info p {
  margin-left: 3em;
  font-size:80%;
}


/* PIP Page */

div#visualDivider {
  background-color:var(--gs1-color-lavender); 
  color: white;
  margin-top:230px;
  padding:0.5em;
}

div#visualDivider span.imgCell, div#visualDivider span.textCell {
  display:table-cell;
  vertical-align: middle;
}

div#visualDivider span.textCell {
  padding-left: 1em;
}

div#visualDivider span.imgCell img {
  display: block;
}

.productPage {
  border-radius: 0;
  padding:0 0 0 0;
}

.productPage section#product {
  margin-top: .5em;
}

.productPage section#product, .productPage section#info, .productPage section#description, .productPage #certificates, #linkToCerts {
  font-size: .8em;
  padding: 0 .5em;
}

section#product h1 {
  font-size: 1.4em;
}

section#info dl {
  margin-left: 2em;
}

section#info dl div, #certificates div.cert dl div {
  display: table-row;
}

section#info dl dt, section#info dl dd, #certificates div.cert dl div dt, #certificates div.cert dl div dd {
  display: table-cell;
}


#certificates div.cert dl div dd.moreInfo {
  width: 50%;
  text-align: right;

}

#certificates div.cert dl div dd.moreInfo img, .blueCircle img, img.blueCircleImg {
  width: 15px;
}


#certificates div.cert:nth-child(odd) {
  background-color: var(--gs1-color-ui-2);
}


section#info dl dt, #certificates div.cert dl div dt {
  font-weight: bold;
  padding-right: .5em;
}


/* Grid approach */
.linksGrid {
  display: grid;
  grid-template-columns: 1fr 20px;
  gap:0;
}

.linksGridLeft {
  grid-column-start:1;
}

.linksGridRight {
  grid-column-start:2;
}

.productPage section#description {
  background-color: var(--gs1-color-ui-1);
  padding-top: 2px;
}

.productPage section#description h2 {
  font-size: 1em;
  margin-bottom:0; 
  font-weight: bold;
  color: black;
}

.productPage #product p {
  line-height: 1.1em;
  margin:0;
}


/* The navigation links */

#links nav {
  display:grid;
  grid-template-columns: repeat(auto-fit, minmax(65px, 1fr)); 
  gap: 3px;
  background-color: var(--gs1-color-ui-1);
  padding:0.5em 0;
  place-content: stretch space-evenly;
}

#links nav figure.navLinks {
  display: block;
  width:60px;
  margin: 0;
  justify-self: center;
}


/* Footer */

footer {
  background-color: var(--gs1-color-blue);
  color:white;
  margin-top: 0;
  padding-top: .5em;
}

#footerMenu {
  display: block;
  margin: 0 auto;
  width:60px;
}

#footerMenu img {
  width:50px;
  margin: 0 auto;
  display: block;
}

footer a, footer a:hover {
  color: white;
  text-decoration: none;
}
