* {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  background-color: #f1f5f9;
  direction: rtl;
  font-family: "Amiri", serif;
  font-size: 20px;
}

:root {
  --main-color: #2196f3;
  --main-alt-color: #1787e0;
  --second-color: #19283f;
  --section-color: #eee;
  --padding-section: 50px 0;
  --transition: 0.5s ease-in-out;
}

a {
  text-decoration: none;
}

ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

/* Header */

.header {
  position: relative;
  background-color: #fff;
}

.header .head {
  gap: 25%;
}

.header .info {
  position: relative;
  cursor: pointer;
}

.header .info img {
  width: 45px;
  height: 45px;
  border-radius: 50%;
  margin: 5px;
}

.header .info ul {
  display: none !important;
  position: absolute;
  background-color: #fff;
  width: 200px;
  top: 70px;
  left: 50%;
  transform: translateX(-50%);
  transition: 0.3s;
  border: 1px solid var(--main-color);
  border-radius: 10px;
  z-index: 2;
}

.header .info ul.open {
  display: block !important;
}

.header .info a {
  display: block;
}

.header ul a {
  padding: 15px 20px;
  color: #000;
  position: relative;
  overflow: hidden;
  font-size: 20px;
  transition: 0.3s;
}

.header ul a::after {
  content: "";
  width: 0;
  height: 4px;
  position: absolute;
  top: 0;
  right: 0;
  background-color: var(--main-color);
  transition: 0.3s;
}

.header ul a:hover::after {
  width: 100%;
}

.header ul a:hover {
  color: var(--main-color);
  background-color: #fafafa;
}

.header .lang {
  padding: 10px 15px;
  background-color: var(--main-color);
  color: #fff;
  border-radius: 20px;
  font-size: 20px;
  transition: 0.3s;
  margin-top: 10px;
  margin-left: 0;
}

.header .lang:hover {
  background-color: var(--main-alt-color);
}

.header button {
  display: none;
}

@media (max-width: 992px) {
  .header .head {
    justify-content: space-between;
  }

  .header button {
    display: block;
    font-size: 25px;
  }

  .header nav {
    position: absolute;
    display: block !important;
    right: 0;
    top: 100%;
    width: 100%;
    border-top: 3px solid var(--main-color);
    background-color: #fff;
    z-index: 2;
    min-height: 287px;
    padding: 10px;
    display: none !important;
  }

  .header nav ul {
    display: block !important;
  }

  .header nav ul a {
    display: block;
  }

  .header nav ul a::after {
    width: 4px !important;
    height: 0;
    right: 0;
  }

  .header ul a:hover::after {
    height: 100%;
  }

  .header .info ul {
    right: -100px;
  }

  .header .lang {
    display: block;
    width: fit-content;
  }

  .header button.open + nav {
    display: block !important;
  }
}
/* Header */

/* Start Words */

.words .content {
  flex-wrap: wrap;
}

.words .card {
  position: relative;
  flex-basis: 200px;
  height: 250px;
  transform-style: preserve-3d;
  transition: transform 0.5s;
  cursor: pointer;
}

.words .card:hover {
  transform: scale(1.2);
}

.words .card.flipped {
  transform: rotateY(180deg);
}

.words .face {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  text-align: center;
  backface-visibility: hidden;
  user-select: none;
}

.words .front img {
  width: 100%;
  height: 200px;
  margin: 25px 0;
}

.words .back {
  background-color: #fff;
  color: #333;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
  border-radius: 5px;
  transform: rotateY(180deg);
  border: 5px solid var(--main-color);
}

.words .back p {
  font-size: 80px;
}

.words .back span {
  color: var(--main-color);
}

/* End Words */
