:root {
  /* --primary-clr: #1d3c26; */
  --primary-clr: #000;
  --secondary-clr: #f0ebce;
  --accent-clr: #921416;

  --text-clr: #fff;
}

html {
  height: 100vh;
}

body {
  display: flex;
  flex-flow: column;
  min-height: 100vh;
  position: relative;
  color: var(--primary-clr);
}

.header {
  flex: 0 1 70px;
}

.footer {
  flex: 0 1 auto;
}

.main {
  flex: 1 1 auto;
}

/* UTILITY CLASSES */
*,
ul,
ol,
h1,
h2,
h3,
h4,
h5,
h6 {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

.container {
  max-width: min(1320px, min(100% - 2rem));
  margin: auto;
}

.btn,
.btn-primary {
  box-shadow: none;
}

/* HEADER */
header {
  height: 4.5rem;
  background-color: var(--primary-clr);
}

.header-menu {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo-img {
  height: 4.5rem;
}

.header-menu-wrapper {
  display: flex;
  gap: 1.5rem;
  align-items: center;
  color: var(--text-clr);
}

.header-icons {
  font-size: 1.3rem;
  color: var(--text-clr);
}

/* MAIN */
.nav-menu {
  background-color: var(--secondary-clr);
  border-bottom: 1px solid var(--primary-clr);
  position: sticky;
  top: 0;
}

#nav-menu-wrapper {
  padding: 0.5rem 0;
  overflow: hidden;
  max-height: 3rem;
  transition: max-height 0.2s ease-out;
}

.dropdown-toggle {
  cursor: pointer;
}

#showmenu:checked + #nav-menu-wrapper {
  max-height: 500px;
  transition: max-height 0.2s ease-in;
}

.nav-ul {
  list-style: none;
}

.nav-item {
  margin-top: 0.7rem;
}

.nav-item.active > a {
  color: var(--accent-clr);
}

.nav-item > a {
  color: var(--primary-clr);
}

.menu-btn {
  box-shadow: none;
  padding: 6px 12px;
}

.dropdown-toggle {
  float: right;
  background: none;
  border: none;
  margin-top: 1px;
  color: var(--primary-clr);
}

/* CATEGORIES PAGE */
.main-container {
  padding: 3rem 0;
}

.categories-wrapper {
  display: grid;
  margin: auto;
  --grid-gap: 2rem;
  gap: var(--grid-gap);
  --max-gap-width: calc(4 * var(--grid-gap));
  --max-columns-width: calc(1296px - var(--max-gap-width));
  /* --max-padding: calc(2 * 10px); */
  /* --max-grid-width: calc((var(--max-columns-width) + var(--max-gap-width))); */
  max-width: 1296px;
  grid-template-columns: repeat(
    auto-fit,
    minmax(150px, calc(var(--max-columns-width) / 5))
  );
  justify-content: center;
}

.category {
  /* max-width: 216px; */
  border-radius: 1rem;
  box-shadow: 0px 12px 38px -11px rgba(0, 0, 0, 0.28);
  -webkit-box-shadow: 0px 12px 38px -11px rgba(0, 0, 0, 0.28);
  -moz-box-shadow: 0px 12px 38px -11px rgba(0, 0, 0, 0.28);
}

.category:hover {
  background-color: var(--secondary-clr);
}

.category-img {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
}

.category-name {
  color: var(--primary-clr);
  font-weight: bold;
  text-align: center;
  margin: 1rem 0;
}

/* CART SECTION */
.cart {
  background-color: var(--secondary-clr);
  height: max-content;
}

.delete-cart {
  background-color: var(--accent-clr);
  color: #fff;
}

.cart-action-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.cart-orderitem {
    padding: 0.5em 0 !important;
    border-bottom: 1px solid #afafaf;
}
.sum {
    margin: 1em 0 1em 0 !important;
}

.checkout-btn {
  flex-grow: 1;
}

#finish-order-form input,
#finish-order-form textarea {
  color: var(--primary-clr);
}

.aditionals-form {
  height: max-content;
  visibility: visible;
}

.aditionals-form.hide {
  height: 0;
  visibility: hidden;
}

.aditionals.hide {
  display: none;
}

/* PRODUCTS PAGES */
.category-title {
  color: var(--accent-clr);
}

.products-wrapper {
  gap: 3rem;
}

.product {
  row-gap: 1rem;
}

.product-staff {
  align-items: center;
  text-transform: uppercase;
}

.img-thumbnail {
  aspect-ratio: 1 / 1;
  max-width: 254px;
}

.options-btns-wrapper {
  display: flex;
  gap: 1rem;
}

.options-btn b {
  font-size: 1rem;
}

/* FOOTER */
.footer {
  background-color: var(--primary-clr);
}

.footer-wrapper {
  justify-content: space-between;
  padding: 3rem 0;
  color: var(--text-clr);
  gap: 2rem;
}

.footer-info {
  text-align: right;
}

.social-icons-wrapper {
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
}

.social-icon {
  font-size: 2.5rem;
  cursor: pointer;
}

.location-map {
  display: flex;
  justify-content: right;
  max-width: 100%;
  max-height: 100%;
}

.location-map iframe {
  width: 100%;
  height: 100%;
}

.highlight-title {
  font-weight: bold;
}

#showmenu {
  display: none;
}

/* SOCIAL AUTH PAGE */
.social-auth-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
  width: 200px;
  margin: 0 auto;
}

.social-auth-button {
  color: #fff;
  width: 200px;
}

.social-auth-button:hover {
  color: #fff;
  transform: scale(1.1);
}

.social-auth-instagram {
  background: #f09433;
  background: -moz-linear-gradient(
    45deg,
    #f09433 0%,
    #e6683c 25%,
    #dc2743 50%,
    #cc2366 75%,
    #bc1888 100%
  );
  background: -webkit-linear-gradient(
    45deg,
    #f09433 0%,
    #e6683c 25%,
    #dc2743 50%,
    #cc2366 75%,
    #bc1888 100%
  );
  background: linear-gradient(
    45deg,
    #f09433 0%,
    #e6683c 25%,
    #dc2743 50%,
    #cc2366 75%,
    #bc1888 100%
  );
  filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#f09433', endColorstr='#bc1888',GradientType=1 );
}

@media only screen and (min-width: 576px) {
  .nav-menu-wrapper {
    display: flex;
    gap: 2rem;
    align-items: center;
  }

  .nav-ul {
    display: inline-block;
  }

  .nav-ul > li {
    display: inline-block;
    margin-right: 1rem;
    line-height: 0.5rem;
  }

  .dropdown-toggle {
    display: none;
  }

  .footer-info {
    text-align: left;
  }

  .social-icons-wrapper {
    display: flex;
    gap: 1rem;
    justify-content: flex-start;
  }
}

@media only screen and (min-width: 768px) {
  .nav-menu {
    z-index: 2;
  }
}

@media only screen and (max-width: 767px) {
  .cart {
    position: fixed;
    top: 100vh;
    left: 0;
    z-index: 1;
    visibility: hidden;
    transition: all 0.2s ease-in;
    height: 100vh;
    overflow: scroll;
  }

  #cart:target {
    top: 0;
    visibility: visible;
    transition: all 0.2s ease-in;
  }

  .open-cart-btn-bottom {
    position: sticky;
    bottom: 0;
    box-shadow: none;
    background-color: var(--accent-clr);
    border-radius: 0;
    height: 3rem;
    line-height: 1.75rem;
  }

  .open-cart-btn-top {
    position: relative;
  }

  .orderitems-counter {
    position: absolute;
    top: -0.5rem;
    right: -0.5rem;
    z-index: 1;
    color: #fff;
    border-radius: 50%;
    width: 1rem;
    height: 1rem;
    font-size: 0.7rem;
    text-align: center;
  }

  .checkout-btn {
    flex: 1 1 100%;
  }

  .delete-cart.all,
  .cart-return-btn {
    flex: 1 1 calc(calc(100% - 0.5rem) / 2);
  }
}
