@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;700&display=swap");

* {
  box-sizing: border-box;
  padding: 0;
  margin: 0;
}

body {
  font-family: "Poppins", sans-serif;
  background-color: #f7f7f9;
}

header,
.main-content-container,
.card-container {
  padding: 0 24px;
}

header,
.main-content,
.cards {
  background-color: #fff;
}

header {
  width: 100%;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  padding-top: 20px;
  padding-bottom: 20px;
}

#logo,
.fa-bars {
  color: #6070ff;
}

#logo {
  font-size: 18px;
  font-weight: 700;
  line-height: 20px;
  text-decoration: none;
}

.hamburger {
  position: absolute;
  right: 20px;
  z-index: 10;
  cursor: pointer;
  width: 20px;
  height: 20px;
  background: none;
  border: none;
}

.hamburger-top,
.hamburger-middle,
.hamburger-bottom {
  position: absolute;
  width: 20px;
  height: 2px;
  top: 0;
  left: 0;
  background-color: #6070ff;
  transition: all 0.5s;
}

.hamburger-middle {
  transform: translateY(5px);
}

.hamburger-bottom {
  transform: translateY(10px);
}

/* main section */
.main-content {
  height: 600px;
  display: flex;
  align-items: center;
  background-image: url("asset/header-bg.png");
  background-size: cover;
  background-repeat: no-repeat;
  border-bottom-left-radius: 80px;
}

.main-content h1 {
  font-size: 40px;
  font-weight: 700;
  line-height: 52px;
  color: #172b4d;
  margin-bottom: 10px;
}

.main-content-container p {
  font-size: 16px;
  font-weight: 400;
  line-height: 24px;
  color: #344563;
  margin-bottom: 10px;
}

#social-heading,
#about-heading {
  color: #7f8cff;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.social-icons ul {
  list-style-type: none;
  display: flex;
  flex-direction: row;
}

.social-icons ul li {
  margin-right: 15px;
}

.main-content-container > div {
  overflow-wrap: break-word;
}

/* card-section */
.card-container {
  display: grid;
  grid-template-rows: auto auto auto auto;
  row-gap: 60px;
  padding-top: 50px;
  padding-bottom: 50px;
}

.cards {
  display: flex;
  flex-direction: column;
  justify-content: center;
  border-radius: 16px;
  padding: 16px;
}

.screenshot {
  width: 100%;
}

.card-description {
  display: flex;
  flex-direction: column;
  overflow-wrap: break-word;
}

.card-title {
  color: #172b4d;
  font-weight: 700;
  font-size: 32px;
  line-height: 44px;
}

.card-bg-info {
  width: 100%;
  display: flex;
  flex-direction: row;
  align-items: center;
}

.card-bg-info p {
  color: #344563;
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
}

.card-bg-info ul {
  display: flex;
  margin-left: 30px;
  color: #7a869a;
  font-size: 13px;
  font-weight: 500;
  line-height: 16px;
}

.card-text {
  color: #344563;
  font-size: 15px;
  line-height: 24px;
  font-weight: 400;
  padding-top: 10px;
}

.card-skills {
  padding-top: 10px;
}

.card-skills ul li {
  float: left;
  list-style: none;
  align-items: center;
  margin-right: 8px;
  background: #ebebff;
  color: #6070ff;
  font-size: 12px;
  font-weight: 500;
  line-height: 16px;
  padding: 4px 12px;
  border-radius: 8px;
}

.card-bg-info ul li:nth-child(2) {
  margin-left: 30px;
}

.btn {
  color: #6070ff;
  background: transparent;
  padding: 12px;
  margin-top: 25px;
  border: 1px solid #6070ff;
  border-radius: 8px;
  font-size: 17px;
  font-weight: 500;
  line-height: 24px;
  cursor: pointer;
}

.btn:hover {
  background-color: #6070ff;
  color: #fff;
}

.btn:active {
  background-color: #2230d2;
}

/* About Section */
.about-container {
  display: grid;
  grid-template-rows: auto auto;
  background-color: #fff;
  border-top-right-radius: 80px;
  padding: 114px 24px;
}

.about {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.about h2 {
  font-size: 40px;
  font-weight: 700;
  line-height: 52px;
  color: #172b4d;
}

.about p {
  font-size: 16px;
  color: #344563;
}

#about-heading {
  padding-bottom: 15px;
}

.about .btn {
  margin-top: 0;
}

.skill-container {
  display: flex;
  flex-direction: column;
  padding-top: 20px;
}

.skill-container button {
  margin-right: 15px;
  background: transparent;
  border: none;
  outline: none;
  cursor: pointer;
}

.skill-container ul {
  list-style-type: none;
}

.skill-container > ul {
  display: flex;
  flex-direction: column;
}

.skill-item {
  display: flex;
  justify-content: space-between;
  padding: 24px 12px;
  font-size: 20px;
  font-weight: 500;
}

.language-item p {
  margin-left: 15px;
  color: #253858;
  font-size: 15px;
  font-weight: 500;
  line-height: 20px;
}

.language-list {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.language-item > div {
  display: flex;
  flex-direction: row;
  align-items: center;
}

.bottom-bar {
  border-bottom: 1px solid #dfe1e6;
}

/* Form Section */
#form-section {
  background-color: #fff;
}

#contact-container {
  display: flex;
  flex-direction: column;
  gap: 50px;
  padding: 90px 24px 45px 24px;
  background-image: url(./asset/form-shapes.svg);
  background-position: right;
  background-repeat: no-repeat;
  background-size: contain;
  background-color: #6070ff;
  border-top-left-radius: 80px;
}

.mobile-main-menu ul {
  padding: 80px 28px 0 28px;
  width: 100%;
  list-style-type: none;
  color: white;
}

#form ul {
  list-style: none;
}

#contact-container h2 {
  color: #fff;
  font-style: normal;
  font-weight: 700;
  font-size: 40px;
  line-height: 52px;
  text-align: center;
  margin-bottom: 10px;
}

#contact-container p {
  color: #ebebff;
  font-style: normal;
  font-weight: 400;
  font-size: 20px;
  line-height: 28px;
  text-align: center;
}

#form input,
#form textarea {
  width: 100%;
  border-radius: 8px;
  border: none;
}

#form input {
  height: 48px;
  padding: 10px;
  margin-bottom: 20px;
  font-style: normal;
  font-weight: 400;
  font-size: 17px;
  line-height: 20px;
}

#form textarea {
  padding: 15px 38px 15px 16px;
  height: 170px;
  font-style: normal;
  font-weight: 400;
  font-size: 15px;
  line-height: 24px;
}

#error-message {
  color: red;
  display: none;
}

#form button {
  background-color: #fff;
}

#form .btn:hover {
  background-color: #6070ff;
  color: #fff;
  border: 1px solid #fff;
}

#form .btn:active {
  background-color: #2230d2;
}

/* Media Queries */
@media (max-width: 400px) {
  .cards {
    padding: 16px;
  }
}

@media (max-width: 767px) {
  .nav-links {
    display: none;
  }
}

@media (min-width: 768px) {
  header {
    padding: 1.5% 9%;
  }

  header .fa-bars {
    display: none;
  }

  header #logo {
    display: flex;
    align-items: center;
  }

  header nav ul {
    list-style-type: none;
    display: flex;
  }

  header nav ul li {
    padding: 10px 12px;
  }

  header nav a {
    text-decoration: none;
    font-size: 15px;
    color: #344563;
    font-weight: 500;
    line-height: 20px;
    cursor: pointer;
  }

  header nav button {
    display: none;
  }

  .main-content {
    background-image: url(./asset/header-bg-desktop.svg);
    background-repeat: no-repeat;
    background-size: 97%;
    background-position: 100% 10%;
    justify-content: center;
  }

  .main-content-container {
    width: 70%;
  }

  /* Card Section */

  .card-container {
    padding: 9%;
  }

  .cards {
    flex-direction: row;
    gap: 10px;
  }

  .cards > div {
    width: 50%;
  }

  .cards .screenshot {
    object-fit: cover;
    height: 100%;
  }

  .card-description {
    padding: 1% 2%;
  }

  .card-2,
  .card-4 {
    flex-direction: row-reverse;
  }

  /* About Section */
  .about-container {
    grid-template-columns: 40% 60%;
    padding: 9%;
    column-gap: 15px;
  }

  .skill-container {
    padding-top: 0;
  }

  .skill-item:nth-child(1) {
    padding: 8px 12px 24px 12px;
  }

  .skill-item:nth-child(2),
  .skill-item:nth-child(3) {
    padding: 24px 12px;
  }

  .language-container {
    display: flex;
    flex-direction: column;
  }

  .language-list {
    flex-direction: row;
    gap: 12px;
    margin-left: 12px;
  }

  .language-item div {
    width: 115px;
    height: 100px;
    display: flex;
    flex-direction: column;
    align-items: start;
    background-color: #f7f7f9;
    padding-top: 12px;
    padding-left: 12px;
  }

  .language-item img {
    width: 48px;
  }

  .language-item p {
    margin-left: 0;
    margin-top: 10px;
  }

  /* Contact Form */

  #contact-container {
    padding: 12% 30%;
    background-image: url(./asset/contact-form-bg-desktop.svg);
    background-size: 94%;
    background-position: 60% 30%;
  }

  #btn-container {
    display: flex;
    justify-content: center;
  }

  #form input,
  #form textarea {
    border-radius: 0;
  }

  .form-btn {
    display: flex;
    flex-direction: row;
    justify-content: center;
  }
}

/* laptop L 1440px */

@media (min-width: 1440px) {
  /* Main section */

  .main-content h1 {
    font-size: 3rem;
  }

  .main-content p {
    font-size: 20px;
  }

  #social-heading {
    margin-top: 20px;
  }

  /* About */
  .about p {
    font-size: 18px;
  }

  /* Card */
  .card-title {
    font-size: 40px;
    margin-bottom: 20px;
  }

  .card-bg-info p,
  .card-bg-info li {
    font-size: 18px;
  }

  .card-text {
    font-size: 18px;
    margin: 24px 0 24px 0;
  }

  .card-skills ul li {
    font-size: 15px;
  }
}
