/* Bootsrap icons */
@import url("https://cdn.jsdelivr.net/npm/bootstrap-icons@1.13.1/font/bootstrap-icons.min.css");

/* MOBILE FIRST APPROACH */
/* 1. Navbar section */
/* 2. MacBook: section 2*/

/* Defining variable in :root */
:root {
  --common-gap: 1.4rem;
  --background-color: hsla(0, 0%, 0%, 0.726);
  --btn-color: #0077ed;
}

/* Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  /* font-family: "Segoe UI", sans-serif; */
}

body {
  /* background-color: #0f0e0e; */
  /* color: #fff; */
  font-size: 16px;
  font-family: "Poppins", Arial, Helvetica, sans-serif;
}

.containerBox {
  max-width: 1400px;
  width: 100%;
  /* background-color: rgb(165, 70, 70); */
  transition: 0.3s ease;
  margin: auto;
  padding-top: 2rem;
}

/* Navbar section */
.navbar {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: var(--common-gap);
  width: 100vw;
  font-size: 1.1rem;
  padding: 0.5rem 1.5rem;
  background-color: rgb(16, 16, 15);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
}

.navbar .logo {
  display: flex;
  flex: 1;
  align-items: center;
}

.navbar .menu {
  position: absolute;
  /* display: none;  animation doesn't work with display: none*/
  top: 100%;
  left: 0;
  display: flex;
  flex-direction: column;
  justify-content: start;
  align-items: start;
  overflow: hidden;
  background-color: rgb(38, 38, 35);
  width: 100%;
  line-height: 2rem;
  padding-left: 2rem;
  opacity: 0;
  height: 0;
  transition: 0.3s ease;
  z-index: 1;
}

.menu.show {
  display: flex;
  flex-direction: column;
  opacity: 1;
  height: 18rem;
}

.menu a:hover {
  color: yellow;
}

.navbar a:hover {
  color: yellow;
}

/* .menu .navlist > li:active a {
  transform: scale(0.9);
}

.submenuIphone > li:active {
  transform: scale(1.2);
} */

/* .navlist > li:active {
  transform: scale(1.2);
} */

.navbar .menu .navlist {
  list-style: none;
}

.navbar .icons {
  display: flex;
  gap: 1rem;
}

.navbar a {
  color: white;
  text-decoration: none;
  font-weight: 300;
}

.icon-search-cart {
  display: flex;
  gap: var(--common-gap);
  align-items: center;
}

.closeOpenIcons {
  display: inline-block;
  gap: 1rem;
}

#closeX {
  display: none;
  font-size: 1rem;
}

/* submenu */
.iphone {
  position: relative;
  display: flex;
  justify-content: space-between;
  /* background-color: rgb(138, 138, 92); */
  cursor: pointer;
}

.iphone::after {
  content: ">";
  display: inline-flex;
}
.submenuIphone {
  position: absolute;
  left: 6.4rem;
  padding-left: 1rem;
  top: 0;
  /* display: none; */
  font-size: 0.9rem;
  flex-direction: column;
  flex-wrap: nowrap;
  list-style: none;
  /* background-color: red; */
  width: 10rem;
  display: block;
  opacity: 0;
  max-height: 0;
  pointer-events: none;
  color: white;
  /* transform: scaleY(0); */
  transition: all 0.4s ease;
}

.iphone:hover .submenuIphone {
  /* display: flex; */
  opacity: 1;
  max-height: 540px;
  pointer-events: auto;
  /* transform: scaleY(1); */
}

.submenuIphone li:hover {
  color: yellow;
}
/* =========================================== */
/* body part */
/* Section 2: MacBook Pro */
.model {
  color: black;
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: 1rem auto 0 auto;
}

.model .slogan {
  font-size: 1.7rem;
}

.model .btn button {
  background-color: var(--btn-color);
  border: 0.1px solid transparent;
  cursor: pointer;
  font-size: 1rem;
  padding: 0.5rem;
  border-radius: 1rem;
  margin: 1rem 0.5rem;
  color: white;
}

.btn button::after {
  content: ">";
  margin-left: 0.5rem;
}

.model .btn button:hover {
  background-color: transparent;
  border: 0.1px solid;
  border-color: var(--btn-color);
  color: black;
}

/* ============================================= */
/* Section 2: iPhone 11 Pro */

.iphone11pro .model {
  padding-top: 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  color: white;
  background-image: url(../images/home/iphone11-pro-bg.jpg);
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  height: 70vh;
  width: 100%;
}

.iphone11pro .model .slogan {
  font-size: 1rem;
}

.iphone11pro .model .price {
  color: grey;
  font-size: 0.8rem;
  font-style: italic;
}

.iphone11pro .btn button:hover {
  background-color: transparent;
  border: 0.1px solid;
  border-color: var(--btn-color);
  color: white;
}

/* Section 3: iPhone 11 */

.iphone11 .model {
  padding-top: 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  color: black;
  background-image: url(../images/home/iphone11-bg.jpg);
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  height: 70vh;
}

.iphone11 .model .slogan {
  font-size: 1rem;
}

.iphone11 .model .price {
  color: grey;
  font-size: 0.8rem;
  font-style: italic;
}

/* =================================================== */
/* Section: Electronics part => All devices */
/* Section 4: Watch Series */

.watch {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  background-image: url(../images/home/watch-series-5.jpg);
  background-position: center;
  background-repeat: no-repeat;
  height: 90vh;
  margin: 1rem auto;
}

.watch .links {
  display: flex;
  gap: 0.5rem;
}

.watch .links a::after {
  content: ">";
  margin-left: 0.5rem;
}
.watch .links a {
  text-decoration: none;
  background-color: var(--btn-color);
  border: 0.1px solid transparent;
  cursor: pointer;
  font-size: 1rem;
  padding: 0.4rem 0.5rem;
  border-radius: 1rem;
  margin: 1rem 0.5rem;
  color: white;
}

.watch .links a:hover {
  background-color: transparent;
  border: 0.1px solid blue;
  color: black;
  border-color: var(--btn-color);
}

/* Section 5:card */

.card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  background-image: url(../images/home/apple-card.jpg);
  background-position: center;
  background-repeat: no-repeat;
  height: 90vh;
  margin: 1rem auto;
}

.card .links {
  display: flex;
  gap: 0.5rem;
}

.card .links a::after {
  content: ">";
  margin-left: 0.5rem;
}
.card .links a {
  text-decoration: none;
  background-color: var(--btn-color);
  border: 0.1px solid transparent;
  cursor: pointer;
  font-size: 1rem;
  padding: 0.4rem 0.5rem;
  border-radius: 1rem;
  margin: 1rem 0.5rem;
  color: white;
}

.card .links a:hover {
  background-color: transparent;
  border: 0.1px solid blue;
  color: black;
  border-color: var(--btn-color);
}

/* Section 6:Apple TV */

.tv {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  background-image: url(../images/home/apple-tv-background.jpg);
  background-position: center;
  background-repeat: no-repeat;
  height: 90vh;
  margin: 1rem auto;
  padding: 1rem 0;
}

.tv .links a {
  text-decoration: none;
  cursor: pointer;
  font-size: 1rem;
}

.tv .links a:hover {
  background-color: transparent;
  color: black;
}

/* Section 7:Airpod Pro */

.airpod {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  height: 90vh;
  margin: 1rem auto;
  color: white;
  background-color: black;
  overflow: hidden;
}

.airpod .links {
  display: flex;
  gap: 0.5rem;
}

.airpod .links a::after {
  content: ">";
  margin-left: 0.5rem;
}
.airpod .links a {
  text-decoration: none;
  background-color: var(--btn-color);
  border: 0.1px solid transparent;
  cursor: pointer;
  font-size: 1rem;
  padding: 0.4rem 0.5rem;
  border-radius: 1rem;
  margin: 1rem 0.5rem;
  color: white;
}

.airpod .links a:hover {
  background-color: transparent;
  border: 0.1px solid blue;
  color: white;
  border-color: var(--btn-color);
}

/* Section 8: MacBook Pro */

.macbook {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  /* height: 90vh; */
  margin: 1rem auto;
  overflow: hidden;
}

.macbook .links {
  display: flex;
  gap: 0.5rem;
}

.macbook .links a::after {
  content: ">";
  margin-left: 0.5rem;
}
.macbook .links a {
  text-decoration: none;
  background-color: var(--btn-color);
  border: 0.1px solid transparent;
  cursor: pointer;
  font-size: 1rem;
  padding: 0.4rem 0.5rem;
  border-radius: 1rem;
  margin: 1rem 0.5rem;
  color: white;
}

.macbook .links a:hover {
  background-color: transparent;
  border: 0.1px solid blue;
  color: black;
  border-color: var(--btn-color);
}

/* Section 9: iPad */

.ipad {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.7rem;
  height: 90vh;
  margin: 1rem auto;
  overflow: hidden;
  background-image: url(../images/home/new-ipad.jpg);
  background-position: bottom;
  background-repeat: no-repeat;
  background-size: cover;
}

.ipad .links {
  display: flex;
  gap: 0.5rem;
}

.ipad .links a::after {
  content: ">";
  margin-left: 0.5rem;
}
.ipad .links a {
  text-decoration: none;
  background-color: var(--btn-color);
  border: 0.1px solid transparent;
  cursor: pointer;
  font-size: 1rem;
  padding: 0.4rem 0.5rem;
  border-radius: 1rem;
  margin: 1rem 0.5rem;
  color: white;
}

.ipad .links a:hover {
  background-color: transparent;
  border: 0.1px solid blue;
  color: black;
  border-color: var(--btn-color);
}

/* section 10: Footer */
footer {
  background-color: hsla(240, 11%, 96%, 0.692);
  text-align: justify;
  font-size: 0.7rem;
  font-family: Arial, Helvetica, sans-serif;
  color: #86868b;
  padding: 1rem;
}
footer .paragraph {
  margin: 1rem auto;
}
.footerBlocks {
  margin: 1rem auto;
}

.footerBlocks .footerHeader {
  color: black;
  cursor: pointer;
}

.footerBlocks .footerHeader::after {
  content: "\F282";
  font-family: "bootstrap-icons";
  text-align: start;
  transform: translateY(10%);
  float: right;
  transition: transform 0.4s ease;
}

.footerBlocks .lists {
  max-height: 0;
  opacity: 0;
  pointer-events: none;
  transition: all 0.5s ease;
  overflow: hidden;
}

.footerBlocks.active .lists {
  max-height: fit-content;
  opacity: 1;
  overflow: hidden;
  pointer-events: all;
  transition: all 0.5s ease;
}

.footerBlocks.active .footerHeader::after {
  content: "\F282";
  font-family: "bootstrap-icons";
  text-align: start;
  transform: translateY(10%);
  float: right;
  transform: rotate(180deg);
}

.footerBlocks ul {
  list-style: none;
  padding: 0.5rem;
}

.footerBlocks ul li {
  line-height: 1.3rem;
}

.footerBlocks ul li a {
  text-decoration: none;
  color: hsla(240, 2%, 54%, 0.79);
}

.footerBlocks ul li a:hover {
  text-decoration: underline;
  color: hsl(240, 2%, 54%);
}

.suggestion {
  margin: 0 auto;
}

.ending .address {
  margin: 1rem auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  justify-content: center;
  align-items: center;
}

.address .us-flag {
  display: flex;
  gap: 0.5rem;
}

.address .us-flag img {
  transform: translateY(-10%);
}

.address .ending-links ul {
  list-style: none;
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.address .ending-links ul li a {
  text-decoration: none;
  color: hsla(240, 2%, 54%, 0.79);
  padding-right: 1rem;
  border-right: 2px solid hsla(240, 2%, 54%, 0.79);
}

.address .ending-links ul li:last-child a {
  border-right: none;
  padding-right: 0;
}

.address .ending-links ul a:hover {
  text-decoration: underline;
  color: hsl(240, 2%, 54%);
}

.copyright {
  text-align: center;
}


/* ================================ */
/* MEDIA QUERUES */
/* ================================ */
/* mobile phone */
/* @media (max-width: 600px) {
  .wrapper {
    max-width: 100%;
  }
} */
/* small tablets and above */
@media only screen and (max-width: 599px) {
  html,
  body {
    width: 100%;
    overflow-x: hidden;
  }
}
/* Mobile phone */
@media (min-width: 600px) {
  :root {
    --common-gap: 1.6rem;
  }

  .containerBox {
    /* background-color: rgb(16, 16, 15); */
    width: 540px;
    padding-top: 2rem;
  }
  .navbar {
    display: flex;
    justify-content: center;
    gap: var(--common-gap);
    align-items: center;
    width: 100vw;
    font-size: 0.9rem;
    position: fixed;

    /* overflow: visible; */
  }

  .navbar .menu {
    position: static;
    opacity: 1;
    height: auto;
    background-color: transparent;
    padding-left: 0;
    width: fit-content;
  }

  .navbar .menu .navlist {
    display: flex !important;
    position: static;
    top: auto;
    flex-direction: row !important;
    gap: var(--common-gap);
    opacity: 1 !important;
    height: auto !important;
    overflow: visible;
    padding-left: 0;
  }

  .navbar .logo,
  .navbar .icon-search-cart {
    flex: 0;
  }

  .closeOpenIcons {
    display: none;
  }

  /* submenu */

  /* .navbar, .menu, .navlist {
    overflow: visible;
  } */

  .iphone {
    position: static;
    display: flex;
    justify-content: space-between;
    /* background-color: rgb(138, 138, 92); */
    cursor: pointer;
  }

  .iphone::after {
    content: "\F282";
    display: inline-flex;
    font-size: 0.7rem;
    margin-left: 0.3rem;
    font-family: "bootstrap-icons";
  }

  .submenuIphone {
    position: absolute;
    top: 90%;
    left: 0;
    padding-left: 10rem;
    display: flex;
    font-size: inherit;
    flex-direction: column;
    flex-wrap: nowrap;
    list-style: none;
    background-color: rgb(32, 30, 30);
    width: 100%;
    /* width: 100%; */
    opacity: 0;
    max-height: 0;
    pointer-events: none;
    transition: all 0.7s ease;
    z-index: -1;
  }

  .iphone:hover .submenuIphone {
    opacity: 1;
    max-height: 540px;
    pointer-events: auto;
  }

  /* Make grid for body part */
  .electronics {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin: 2rem;
  }

  .electronics > * {
    width: 100%;
    max-width: 100%;
    overflow: hidden;
  }

  html,
  body {
    width: 100%;
    overflow-x: visible;
  }

  /* footer links */

  .allFooterLinks {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1rem;
    text-align: left;
  }

  .footerBlocks .lists {
    max-height: fit-content;
    opacity: 1;
    pointer-events: all;
    transition: all 0.5s ease;
    overflow: hidden;
  }

  .footerBlocks .footerHeader::after {
    content: none;
  }

  .footerBlocks.active .footerHeader::after {
    content: none;
  }

  .footerBlocks hr {
    display: none;
  }

  .ending #address {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: space-between;
  }
}

/* standard tablets and above */
@media (min-width: 768px) {
  .containerBox {
    /* background-color: hsl(120, 68%, 5%); */
    width: 708px;
  }
  :root {
    --common-gap: 2rem;
  }
}

/* large tablets and above */
@media (min-width: 992px) {
  .containerBox {
    /* background-color: hsl(243, 100%, 75%); */
    width: 932px;
  }
  :root {
    --common-gap: 4rem;
  }
}

/* small desktops/laptops */
@media (min-width: 1200px) {
  .containerBox {
    /* background-color: hsl(0, 100%, 90%); */
    width: 1140px;
  }
  :root {
    --common-gap: 4rem;
  }
}

/* large destops */
@media (min-width: 1440px) {
  .containerBox {
    /* background-color: rgb(53, 49, 49); */
    width: 1380px;
  }
  :root {
    --common-gap: 4.2rem;
  }
}
