/*================= GOOGLE FONTS =================*/
@import url("https://fonts.googleapis.com/css2?family=Montagu+Slab:wght@500&family=Montserrat:wght@400;500;600&display=swap");

/*================= VARIABELS CSS =================*/
:root {
  --header-height: 3.5rem;

  /*================= Colors =================*/
  /*Color mode HSL (hue, saturation, lightness)*/
  --first-color: hsl(230, 62%, 56%);
  --title-color: hsl(230, 70%, 16%);
  --text-color: hsl(230, 16%, 45%);
  --border-color: hsl(230, 50%, 90%);
  --white-color: hsl(0, 0%, 100%);
  --body-color: hsl(230, 100%, 96%);
  --container-color: hsl(230, 100%, 97%);

  /*================= Font and typography =================*/
  /*.5rem = 8px / 1rem = 16px ... */
  --body-font: "Montserrat", sans-serif;
  --second-font: "Montagu Slab", serif;

  --biggest-font-size: 2rem;
  --h1-font-size: 1.5rem;
  --h2-font-size: 1.25rem;
  --h3-font-size: 1rem;
  --normal-font-size: 0.938rem;
  --small-font-size: 0.813rem;
  --normaller-font-size: 0.75rem;

  /*================= Font Weight =================*/
  --font-regular: 400;
  --font-medium: 500;
  --font-semi-bold: 600;

  /*================= z index =================*/
  --z-tooltip: 10;
  --z-fixed: 100;
}
/*================= Responsive Typography =================*/
@media screen and (min-width: 1150px) {
  :root {
    --biggest-font-size: 3.5rem;
    --h1-font-size: 2.25rem;
    --h2-font-size: 1.5rem;
    --h3-font-size: 1.25rem;
    --normal-font-size: 1rem;
    --small-font-size: 0.875rem;
    --normaller-font-size: 0.813rem;
  }
}

/*================= BASE =================*/
* {
  box-sizing: border-box;
  padding: 0;
  margin: 0;
}

html {
  scroll-behavior: smooth;
}
body,
inputm button {
  font-family: var(--body-font);
  font-size: var(--normal-font-size);
}

body {
  background-color: var(--body-color);
  transition: background-color 0.4s;
}

input,
button {
  border: none;
  outline: none;
}

h1,
h2,
h3,
h4 {
  color: var(--text-color);
  font-family: var(--second-font);
  font-weight: var(--font-medium);
}

ul {
  list-style: none;
}

a {
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

/*================= THEME =================*/
/*================= Variabels Dark theme =================*/
/*================= 
    Color changes in some part of
    the website, in dark them
 =================*/

/*================= RESUABLE CSS CLASSES =================*/
.container {
  max-width: 1220px;
  margin-inline: 1.5rem;
}

.grid {
  display: grid;
  gap: 1.5rem;
}

.section {
  padding-block: 5rem 1rem;
}

.section__title {
  text-align: center;
  font-size: var(--h1-font-size);
  font-family: var(--second-font);
  margin-bottom: 2rem;
}

.main {
  overflow: hidden; /* For animation ScrollReveal */
}

/*================= HEADER & NAV =================*/
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: var(--body-color);
  z-index: var(--z-fixed);
  transition: box-shadow 0.4s, bacground-color 0.4s;
}

.nav {
  height: var(--header-height);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav__logo {
  display: inline-flex;
  align-items: center;
  column-gap: 0.5rem;
  color: var(--first-color);
  font-weight: var(--font-medium);
}

.nav__logo i {
  font-size: 1.2rem;
}
/* Navigation for mobile devices */
@media screen and (max-width: 1150px) {
  .nav__menu {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    background-color: var(--body-color);
    box-shadow: 0 -8px 32px hsla(0, 0%, 0%, 0.1);
    padding: 1.25rem 4rem;
    transition: background-color 0.4s;
  }
}

.nav__list {
  display: flex;
  justify-content: space-between;
}

.nav__link {
  color: var(--text-color);
  transition: color 0.4s;
}

.nav__link span {
  display: none;
}

.nav__link i {
  font-size: 1.25rem;
}

.nav__link:hover {
  color: var(--first-color);
}

.nav__actions {
  display: flex;
  align-items: center;
  column-gap: 1rem;
}

.nav__actions i {
  font-size: 1.25rem;
  color: var(--title-color);
  cursor: pointer;
  transition: color 0.4s;
}

.nav__actions i:hover {
  color: var(--first-color);
}

/* Add shadow header */
.shadow-header {
  box-shadow: 0 2px 16px hsla(0, 0%, 0%, 0.1);
}

/* Active link*/
.active-link {
  color: var(--first-color);
}

/*=============== LOGIN ===============*/
.login {
  position: fixed;
  top: -100%;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: var(--z-fixed);
  background-color: hsla(230, 12%, 96%, 0.6);
  backdrop-filter: blur(16px);
  align-items: center;
  padding: 1.5rem;
  text-align: center;
  transition: top 0.4s;
}

.login__form {
  background-color: var(--container-color);
  padding: 2rem 1.5rem;
  border: 2px solid var(--border-color);
  row-gap: 1.25rem;
}

.login__title {
  font-size: var(--h2-font-size);
}

.login__group {
  row-gap: 1.25rem;
}

.login__label {
  display: block;
  text-align: initial;
  color: var(--text-color);
  font-weight: var(--font-medium);
  margin-bottom: 0.25rem;
}

.login__input {
  width: 100%;
  background-color: var(--container-color);
  border: 2px solid var(--border-color);
  padding: 1rem;
  color: var(--text-color);
}

.login__signup,
.login__forgot {
  display: block;
  font-size: var(--small-font-size);
}

.login__signup {
  margin-bottom: 0.5rem;
}

.login__signup a {
  color: var(--first-color);
  font-weight: var(--font-medium);
}

.login__forgot {
  color: var(--first-color);
  margin-bottom: 1.25rem;
}

.login__button {
  width: 30%;
  cursor: pointer;
}

.login__close {
  position: absolute;
  top: 2rem;
  right: 2rem;
  font-size: 2rem;
  color: var(--title-color);
  cursor: pointer;
}

/* Show login */
.show-login {
  top: 0;
}

/*=============== Login Success ===============*/
.btn {
  height: 35px;
  background: rgba(76, 68, 182, 0.808);
  border: 0;
  border-radius: 5px;
  color: #fff;
  font-size: 15px;
  cursor: pointer;
  transition: all 0.3s;
  margin-top: 10px;
  padding: 0px 10px;
}
.right-links a {
  padding: 0 10px;
}
.box {
  background: #fdfdfd;
  display: flex;
  flex-direction: column;
  padding: 25px 25px;
  border-radius: 20px;
  box-shadow: 0 0 128px 0 rgba(0, 0, 0, 0.1),
    0 32px 64px -48px rgba(0, 0, 0, 0.5);
}
main {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 20px;
}
.main-box {
  width: 50%;
}
.main-box .top {
  justify-content: space-between;
}
.bottom {
  width: 100%;
  margin-top: 20px;
}

.mid {
  width: 100%;
  margin-top: 20px;
}
@media only screen and (max-width: 840px) {
  .main-box .top {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
  }
  .top .box {
    margin: 10px 10px;
  }
  .bottom {
    margin-top: 0;
  }
}
.message {
  text-align: center;
  background: #f9eded;
  padding: 15px 0px;
  border: 1px solid #699053;
  border-radius: 5px;
  margin-bottom: 10px;
  color: red;
}

/*=============== HOME ===============*/
.home__swiper {
  margin: initial;
}

.home__container {
  padding-top: 1rem;
  row-gap: 2.5rem;
}

.home__data {
  text-align: center;
}

.home__title {
  font-size: var(--biggest-font-size);
  margin-bottom: 5rem;
}

.home__description {
  margin-bottom: 2rem;
}

.home__images {
  display: grid;
}

.home__article,
.home__img {
  width: 220px;
  transition: scale 0.4s;
}

.home__article {
  scale: 0.8;
}
/* Swiper class */
.swiper-slide-active,
.swiper-slide-duplicate-active {
  scale: 1;
}

/*=============== BUTTON ===============*/
.button {
  display: inline-block;
  background-color: var(--first-color);
  color: var(--white-color);
  font-weight: var(--font-semi-bold);
  padding: 1rem 1.5rem;
  transition: box-shadow 0.4s;
}

.button:hover {
  box-shadow: 0 4px 32px hsla(230, 72%, 32%, 4);
}

/* Swiper class */

/*=============== NEW ===============*/
.new__card {
  display: flex;
  align-items: center;
  column-gap: 2.5rem;
  background-color: var(--container-color);
  padding: 1.5rem 1rem;
  color: var(--text-color) brown2px solod var(--border-color);
  transition: border 0.1s, background-color 0.4s;
}

.new__card:hover {
  border: 1px solid var(--text-color);
}

.new__img {
  width: 100px;
}

.new__title {
  font-size: var(--h2-font-size);
  margin-bottom: 0.5rem;
}

.new__price {
  display: flex;
  align-items: center;
  column-gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.new_discount {
  color: var(--title-color);
}

.new__price {
  font-size: var(--small-font-size);
  text-decoration: line-through;
}

.new__swiper:nth-child(1) {
  margin-bottom: 2rem;
}

/*=============== FOOTER ===============*/
/*Footer*/

footer {
  background-color: var(--body-color);
  text-align: center;
  padding: 1rem 0;
  margin-top: 3rem;
  justify-content: space-between;
  display: flex;
}

footer .socials {
  padding: 1rem 0;
  margin-right: 1rem;
  margin-top: 0.2rem;
}

footer .credit p {
  color: var(--first-color);
  align-items: ce;
  margin-left: 4rem;
  margin-top: 4rem;
  font-size: 15px;
}

.footer__copy {
  display: block;
  margin-bottom: 0rem;
  text-align: center;
  font-size: var(--small-font-size);
}
/*=============== SCROLL BAR ===============*/
::-webkit-scrollbar {
  width: 0.6rem;
  border-radius: 0.5rem;
  background-color: hsl(230, 16%, 85%);
}
--webkit-scrollbar {
  width: 0.6rem;
  border-radius: 0.5rem;
  background-color: hsl(230, 16%, 85%);
}
::-webkit-scrollbar-thumb {
  border-radius: 0.5rem;
  background-color: hsl(230, 16%, 65%);
}

::-webkit-scrollbar-thumb:hover {
  border-radius: 0.5rem;
  background-color: hsl(230, 16%, 55%);
}

/*=============== BREAKPOINTS ===============*/
/* For small devices */
@media screen and (max-width: 320px) {
  .container {
    margin-inline: 1rem;
  }

  .nav__menu {
    padding-inline: 3rem;
  }

  .new__card {
    flex-direction: column;
  }
}

/* For medium devices */
@media screen and (min-width: 450px) {
  .new__card {
    width: 390px;
  }
}

@media screen and (min-width: 576px) {
  .search__form {
    width: 500px;
    margin-inline: auto;
  }

  .loginform__ {
    width: 400px;
    justify-self: center;
  }

  .search__close,
  .login__close {
    width: max-content;
    top: 3rem;
    left: 0;
    right: 0;
    margin-inline: auto;
  }

  .nav__menu {
    width: 500px;
    margin-inline: auto;
  }

  .home__container {
    grid-template-columns: 420px;
    justify-content: center;
  }
}

@media screen and (min-width: 768px) {
  .home__container {
    grid-template-columns: 580px;
  }

  .home__data {
    width: 420px;
    justify-self: center;
  }
}
/* For large devices */
@media screen and (min-width: 1150px) {
  .section {
    padding-block: 7rem 2rem;
  }

  .nav {
    height: calc(var(--header-height) + 2rem);
    column-gap: 4rem;
  }

  .nav__link i {
    display: none;
  }

  .nav__link span {
    display: block;
  }

  .nav__menu {
    width: initial;
    margin-inline: auto 0;
  }

  .nav__list {
    column-gap: 4rem;
  }

  .nav__link {
    font-weight: var(--font-medium);
  }

  .home__data {
    width: initial;
  }
  @media screen and (min-width: 1150px) {
    .section {
      padding-block: 7rem 2rem;
    }

    .nav {
      height: calc(var(--header-height) + 2rem);
      column-gap: 4rem;
    }

    .nav__link i {
      display: none;
    }

    .nav__link span {
      display: block;
    }

    .nav__menu {
      width: initial;
      margin-inline: auto 0;
    }

    .nav__list {
      column-gap: 4rem;
    }

    .nav__link {
      font-weight: var(--font-medium);
    }

    .home__data {
      width: initial;
    }

    .new__card {
      padding: 1.5rem;
    }

    .new__img {
      width: 120px;
    }

    .new__title {
      font-size: var(--h3-font-size);
    }
  }

  @media screen and (min-width: 1220px) {
    .container {
      margin-inline: auto;
    }
    .home__container {
      grid-template-columns: 435px 745px;
      align-items: center;
      padding-block: 0.5rem 2rem;
    }

    .home__data {
      text-align: initial;
    }

    .home__title {
      margin-bottom: 0.5rem;
    }

    .home__description {
      margin-bottom: 4rem;
    }

    .home__article,
    .home__img {
      width: 290px;
    }
  }
}
