*,
*:after,
*:before {
	box-sizing: border-box;
}
html,
body {
	width: 100%;
	height: 100%;
	padding: 0;
	margin: 0;
	font-size: 19px;
	scroll-behavior: smooth;

  font-family: sans-serif;

  background: gray;
}
@media screen and (max-width: 1366px) {
    html, body {
      font-size: 18px;
    }
  }

  @media screen and (max-width: 1280px) {
    html, body {
      font-size: 16px;
    }
  }
  @media screen and (max-width: 960px) {
    html, body {
      font-size: 15px;
    }
  }
h1 {
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
}
header h1 img {
    width: 4rem;
    margin-right: 1rem;
}
h1 span {
    margin-top: 0.5rem;
    position: absolute;
    margin-left: 1rem;
  }
  main {
    min-height: 80%;
  }
header {
    height: 5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#sss-aisle {
    display: flex;
    flex-wrap: wrap;
    flex-direction: row;
    min-height: 90%;
}
#sss-aisle[data-direction="descending"] {
    flex-wrap: wrap-reverse;
    flex-direction: row-reverse;
}
#sss-options {
    display: flex;
    align-items: center;
    padding: 0.5rem;
}
.sss-product {
    width: calc(100% / 4);
    padding: 0.5rem;
    display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  position: relative;
}

.sss-order-option {
    aspect-ratio: 1/1;
    background: rgba(0,0,0,0);
    border: none;
    cursor: pointer;
}

.sss-order-option {
  background-size: 75%;
  background-repeat: no-repeat;
  background-position: center;
  width: 2rem;
}

.sss-cost {
  font-size: 1.25rem;
  font-weight: bold;
  margin: 0.5rem 0;  
  width: max-content;
  display: none;
}
.sss-cost.active {
  display: block;
}
.sss-description {
  font-size: 0.75rem;
  margin: 0;  
  margin-bottom: 0.5rem;  
  display: none;
}

.sss-order-option[data-order-type="price"][data-order-direction="descending"] {
  background-image: url(../data/layout/icon-order-price-down.png);
}
.sss-order-option[data-order-type="price"][data-order-direction="ascending"] {
  background-image: url(../data/layout/icon-order-price-up.png);
}
.sss-order-option[data-order-type="rank"][data-order-direction="descending"] {
  background-image: url(../data/layout/icon-order-star-down.png);
}
.sss-order-option[data-order-type="rank"][data-order-direction="ascending"] {
  background-image: url(../data/layout/icon-order-star-up.png);
}
.sss-order-option[data-order-type="type"][data-order-direction="descending"] {
  background-image: url(../data/layout/icon-order-type-down.png);
}
.sss-order-option[data-order-type="type"][data-order-direction="ascending"] {
  background-image: url(../data/layout/icon-order-type-up.png);
}
.sss-aisle[data-order="rank"] .sss-product[data-order-rank='0'] {order: 11 !important;}
.sss-aisle[data-order="rank"] .sss-product[data-order-rank='1'] {order: 10 !important;}
.sss-aisle[data-order="rank"] .sss-product[data-order-rank='2'] {order: 9 !important;}
.sss-aisle[data-order="rank"] .sss-product[data-order-rank='3'] {order: 8 !important;}
.sss-aisle[data-order="rank"] .sss-product[data-order-rank='4'] {order: 7 !important;}
.sss-aisle[data-order="rank"] .sss-product[data-order-rank='5'] {order: 6 !important;}
.sss-aisle[data-order="rank"] .sss-product[data-order-rank='6'] {order: 5 !important;}
.sss-aisle[data-order="rank"] .sss-product[data-order-rank='7'] {order: 4 !important;}
.sss-aisle[data-order="rank"] .sss-product[data-order-rank='8'] {order: 3 !important;}
.sss-aisle[data-order="rank"] .sss-product[data-order-rank='9'] {order: 2 !important;}
.sss-aisle[data-order="rank"] .sss-product[data-order-rank='10'] {order: 1 !important;}

.sss-aisle[data-order="type"] .sss-product[data-order-type='A'] {order: 1 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='B'] {order: 2 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='C'] {order: 3 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='D'] {order: 4 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='E'] {order: 5 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='F'] {order: 6 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='G'] {order: 7 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='H'] {order: 8 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='I'] {order: 9 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='J'] {order: 10 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='K'] {order: 11 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='L'] {order: 12 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='M'] {order: 13 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='N'] {order: 14 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='O'] {order: 15 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='P'] {order: 16 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='Q'] {order: 17 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='R'] {order: 18 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='S'] {order: 19 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='T'] {order: 20 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='U'] {order: 21 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='V'] {order: 22 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='W'] {order: 23 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='X'] {order: 24 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='Y'] {order: 25 !important;}
.sss-aisle[data-order="type"] .sss-product[data-order-type='Z'] {order: 26 !important;}

.sss-product[data-state="hidden"] {
    display: none;
}

.sss-images {
  width: 100%;
  aspect-ratio: 5/4;
  position: relative;
  background: var(--white);
}

.sss-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
}
.sss-image-hidden {
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 0;
  opacity: 0;
  pointer-events: none;
}
.sss-images-nav {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1000;
  display: none;
}
.sss-maximize {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}
.sss-minimize {
  display: none;
}

.sss-images-prev,
.sss-images-next {
  position: absolute;
  top: 0;
  left: 0;
  width: 50%;
  height: 100%;
  background: transparent;
  border-radius: 0;
  font-size: 1.5rem;
  text-align: left;
  cursor: pointer;
}
.sss-images-next {
left: 50%;
text-align: right;
}
.sss-warning-cart {
  height: 100%;
  border-radius: 50%;
  padding: 0.5rem;
  z-index: 1000;
  position: absolute;
  bottom: 0;
  left: 0;
}
.sss-information {
  position: absolute;
  bottom: 0.5rem;
  padding: 0.5rem 1rem;
  width: calc(100% - 1rem);
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
}
.sss-name {
  margin: 0;
  width: max-content;
}
.sss-time {
  font-size: 0.75rem;
  margin: 0; 
  margin-bottom: 0.5rem;
}
.sss-type,
.sss-tags {
  display: none;
}
.sss-options {
  width: 100%;
  margin: 0.5rem 0;  
  display: none;
}
.sss-button-add {
  width: 100%; 
  display: none;
  text-align: center;
  font-size: 1.25rem;
}

.sss-cart-item {
  display: flex;
  align-items: center;
}

.sss-cart-image {
  width: 3rem;
  margin-right: 0.5rem;
}

.sss-cart-item {
  padding: 0.25rem 0.5rem;
  border: 2px solid black;
  border-radius: 0.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
#sss-cart {
  padding: 0.5rem;
}

.sss-cart-less {
  margin-right: 0.5rem;
  margin-left: auto;
}
.sss-cart-more {
  margin-left: 0.5rem;
  margin-right: auto;
}

.sss-cart-total-cost {
  width: 20%;
  text-align: right;
}
.sss-cart-cost {
  width: 20%;
  text-align: left;
}
.sss-cart-title {
  margin-right: 0.5rem;
  width: 20%;
  text-align: left;
}

#sss-success-message {
  position: fixed;
  top: 50%;
  left: 50%;
  translate: -50% -50%;
  text-align: center;
  background: white;
  padding: 1rem;
  pointer-events: none;
  opacity: 0;
}

#sss-success-message[data-status="active"] {
  animation: sss-success 5s ease both 1;
}
@keyframes sss-success {
  0%    {opacity: 0; translate: -50% calc(-50% + 1rem);}
  10%   {opacity: 1; translate: -50% -50%;}
  90%   {opacity: 1; translate: -50% -50%;}
  100%  {opacity: 0; translate: -50% calc(-50% - 1rem);}
}

#sss-cost {
  padding: 1rem;
  font-weight: bold;
}

#sss-form {
  padding: 1rem;
}

#sss-form details h2 {
  width: 100%;
  margin: 0;
  padding: 0 2rem 0 0;
  position: relative;
}
#sss-form details summary {
  padding: 0;
  position: relative;
  cursor: pointer;
}
#sss-form details summary::marker {
  display: none;
  content: " ";
}
#sss-form details summary::after {
  content: "+";
  position: absolute;
  top: 50%;
  right: 0;
  translate: 0 -50%;
  font-size: 2rem;
  font-weight: bold;
}
#sss-form details[open=""] summary::after {
  content: "-";
}
#sss-form input[type="text"], 
#sss-form input[type="email"], 
#sss-form textarea {
  width: 100%;
  padding: 0.25rem 0.5rem;
  font-size: 1.25rem;
  margin: 0 0 0.5rem 1rem;
}
label {
  width: 100%;
  display: block;
}
#sss-cost-cashier {
  font-size: 2rem;
  margin: 0;
}
#form-submit-purchase {
  display: block;
  clear: both;
  font-size: 2rem;
  padding: 0.5rem 1rem;
  margin-top: 1rem;
}

#sss-form {
  width: 50%;
}

#form-submit-purchase[disabled=""] {
  opacity: 0.5;
  pointer-events: none;
}
#sss-warning {
  position: fixed;
  bottom: 1rem;
  left: 1rem;
  overflow: hidden;
  width: 3rem;
  height: 3rem;

  z-index: 100000;
}

#sss-warning-message {
  position: absolute;
  overflow: hidden;
  width: 12rem;
  height: 3rem;
  display: flex;
  align-items: center;
  left: 1rem;
  padding: 0.5rem 0.5rem 0.5rem 2.5rem;
}
.sss-images .sss-image {
  opacity: 0;
  pointer-events: none;
  transition: all 0.25s ease;
}
.sss-images[data-current-image="0"] .sss-image[data-image="0"]{opacity: 1;}
.sss-images[data-current-image='0'] .sss-image[data-image='0']{opacity: 1;}
.sss-images[data-current-image='1'] .sss-image[data-image='1']{opacity: 1;}
.sss-images[data-current-image='2'] .sss-image[data-image='2']{opacity: 1;}
.sss-images[data-current-image='3'] .sss-image[data-image='3']{opacity: 1;}
.sss-images[data-current-image='4'] .sss-image[data-image='4']{opacity: 1;}
.sss-images[data-current-image='5'] .sss-image[data-image='5']{opacity: 1;}
.sss-images[data-current-image='6'] .sss-image[data-image='6']{opacity: 1;}
.sss-images[data-current-image='7'] .sss-image[data-image='7']{opacity: 1;}
.sss-images[data-current-image='8'] .sss-image[data-image='8']{opacity: 1;}
.sss-images[data-current-image='9'] .sss-image[data-image='9']{opacity: 1;}
.sss-images[data-current-image='10'] .sss-image[data-image='10']{opacity: 1;}
.sss-images[data-current-image='11'] .sss-image[data-image='11']{opacity: 1;}
.sss-images[data-current-image='12'] .sss-image[data-image='12']{opacity: 1;}
.sss-images[data-current-image='13'] .sss-image[data-image='13']{opacity: 1;}
.sss-images[data-current-image='14'] .sss-image[data-image='14']{opacity: 1;}
.sss-images[data-current-image='15'] .sss-image[data-image='15']{opacity: 1;}
.sss-images[data-current-image='16'] .sss-image[data-image='16']{opacity: 1;}
.sss-images[data-current-image='17'] .sss-image[data-image='17']{opacity: 1;}
.sss-images[data-current-image='18'] .sss-image[data-image='18']{opacity: 1;}
.sss-images[data-current-image='19'] .sss-image[data-image='19']{opacity: 1;}

.sss-maximum {
  position: fixed;
  top: 0;
  left: 0;
  background: var(--dark);
  width: 100vw;
  height: 100vh;
  z-index: 100000;
}
.sss-product:target {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: var(--dark);
  z-index: 100000;
  padding: 0;
  display: flex;;
}
.sss-product:target .sss-maximize {
  display: none;
}
.sss-product:target  .sss-images {
  width: calc(100% / 3 * 2);
  aspect-ratio: initial;
}
.sss-product:target .sss-information {
  position: relative;
  width: calc(100% / 3);
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-end;
  padding-top: 3rem;
}

.sss-product:target .sss-name{
margin-top: auto;
}
.sss-product:target .sss-description,
.sss-product:target .sss-options,
.sss-product:target .sss-time,
.sss-product:target .sss-button-add {
  display: block;
}

.sss-product:target .sss-images-nav {
  display: block;
}


.sss-product:target .sss-minimize {
  display: block;
  position: absolute;
  top: 0;
  left: calc(100% / 3 * 2);
  width: 3rem;
  height: 3rem;
  background-size: 50%;
  background-position: center center;
  background-repeat: no-repeat;
  background-image: url(../data/layout/icon-back.png);
}
.sss-exit-cart {
  position: absolute;
  top: 0;
  left: 0;
  width: 3rem;
  height: 3rem;
  background-size: 50%;
  background-position: center center;
  background-repeat: no-repeat;
  background-image: url(../data/layout/icon-back.png);
}

#cart {
  display: none;
}
#cart:target {
  display: block;
  padding: 3rem 1rem 1rem 1rem;
  position: fixed;
  top: 0;
  left: 0;
  background: var(--dark);
  width: 100%;
  height: 100%;
  overflow: auto;
  z-index: 200000;
}

footer {

	padding: 1rem 4rem;
	width: 100%;
	display: flex;
	flex-direction: row;
	justify-content: space-between;
  flex-wrap: wrap;
}
#footer-logo {
	width: 6rem;
	order: 3;
}
#copyright {
  width: 100%;
  order: 4;
  padding: 0.5rem;
  margin: 1rem auto;
  text-align: center;
}
@media (orientation: portrait) {
  header {
    flex-direction: column;
    align-items: flex-start;
    height: auto; 
  }
  #sss-options {
    flex-direction: column;
    align-items: flex-start;
  }
  .sss-product {
    width: calc(100% / 2);
  }
  #sss-form input[type="text"], 
  #sss-form input[type="email"], 
  #sss-form textarea {
    width: 100%
  }
  #sss-form {
    padding: 1rem;
    width: 100%;
  }
  #sss-search-bar {
    width: 100%;
  }
  #sss-options {
    width: 100%;
  }
  .sss-product:target {
    flex-direction: column;
    flex-wrap: nowrap;
    overflow: auto;
  }
  .sss-product:target .sss-minimize {
    left: 0;
  }
  .sss-product:target .sss-images {
    margin-top: 3rem;
    width: 100%;
    aspect-ratio: 5/4;
  }
  .sss-product:target .sss-information {
    width: 100%;
    padding-top: 1rem;
  }
  footer {
    flex-direction: column;
    text-align: center;
  }
  #footer-logo {
    width: 80%;
    margin: 1rem auto;
  }
}
