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

:root {
  --darker-blue: #080c20;
  --dark-blue: #091235;
  --light-blue: #0592f0;
}

body {
  background: var(--darker-blue);
  color: #fff;
  font-family: Montserrat, Arial, Helvetica, sans-serif;
  font-size: 1rem;
  line-height: 1.5;
  position: relative;
}

html {
  scroll-behavior: smooth;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  text-decoration: none;
  list-style: none;
  scroll-behavior: smooth;
}

/* width */
::-webkit-scrollbar {
  width: 5px;
}

/* Track */
::-webkit-scrollbar-track {
  background: #00b1e5;
}

/* Handle */
::-webkit-scrollbar-thumb {
  background: #ddd;
}

/* Handle on hover */
::-webkit-scrollbar-thumb:hover {
  background: #fff;
}

h1 {
  font-size: 4rem;
  margin-bottom: 1rem;
}

h2 {
  font-size: 2rem;
}

img {
  width: 100%;
  user-select: none;
  -moz-user-select: none;
  -webkit-user-drag: none;
  -webkit-user-select: none;
  -ms-user-select: none;
}

.btn {
  display: inline-block;
  font-size: 1.3rem;
}

.bg-transition {
  transition: background 0.3s ease-in-out;
}

.color-transition {
  transition: color 0.3s ease-in-out;
}

.container {
  width: 100%;
  max-width: 1080px;
  height: 100%;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.max-width-400 {
  max-width: 400px;
}

.max-width-600 {
  max-width: 600px;
}

.fade-in {
  opacity: 0;
  transition: opacity 1s ease-in;
}

.fade-in.appear {
  opacity: 1;
}

.custom-padding {
  padding: 7% 0;
}

/* --------------- nav ---------------*/
nav {
  padding: 1rem 0;
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 10;
  transition: 0.5s;
}

nav .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.brand {
  font-size: 1.2rem;
  font-weight: bold;
  cursor: pointer;
}

.brand a,
nav ul {
  color: #fff;
  display: flex;
  align-items: center;
}

.logo {
  width: 35px;
  margin-right: 1rem;
}

nav ul li a {
  color: #ddd;
  transition: color 0.3s ease-in-out;
}

nav ul li a:hover {
  color: #fff;
}

nav ul li {
  padding: 0 1rem;
}

nav ul li:first-child {
  padding-left: 0;
}

nav ul li:last-child {
  padding-right: 0;
}

.menu {
  width: 25px;
  display: none;
}

/* --------------- Showcase --------------- */
#showcase {
  height: 100vh;
  width: 100%;
  position: relative;
  z-index: 1;
}

#showcase .container {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
}

#showcase h1 {
  line-height: 1.2;
  margin-top: 15%;
  margin-bottom: 2rem;
  position: relative;
  z-index: 1;
  -webkit-animation: mainFadeIn 0.5s forwards;
  -o-animation: mainFadeIn 0.5s forwards;
  animation: mainFadeIn 0.5s forwards;
  animation-delay: 0.5s;
  opacity: 0;
  align-self: flex-start; /* move to bottom */
}

.content{
  align-self: flex-end; /* move to bottom */
}

.content p {
  animation: secFadeIn 1s forwards;
  animation-delay: 1s;
  opacity: 0;
}

.btn {
  margin: 2rem 0;
  padding: 0.5rem 1.3rem;
  color: #fff;
  position: relative;
  z-index: 1;
}

.btn-work {
  animation: btnFadeIn 2s forwards;
  animation-delay: 2s;
  opacity: 0;
}

.btn::after {
  background: var(--light-blue);
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 55%;
  height: 100%;
  z-index: -1;
  transition: width 0.3s ease-in-out;
}

.btn:hover::after {
  width: 100%;
}

/* --------------- About --------------- */
#about {
  height: 100%;
  position: relative;
}

#about .container {
  display: flex;
  align-items: center;
}

h5 {
  margin-bottom: 0.5rem;
  color: #ddd;
}

.profile {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 2rem;
}

.profile-img {
  display: inline-block;
  order: 2;
  opacity: 0.75;
  transition: opacity 0.2s ease-in-out;
  border-radius: 0.25rem;
}

.profile-img:hover {
  opacity: 1;
}

.profile-content {
  width: 100%;
  height: 100%;
}

.profile-content h2 {
  margin-bottom: 2rem;
}

.profile-content p {
  margin: 1rem 0;
}

.techs {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.techs li::before {
  content: "\2713";
  color: var(--light-blue);
  font-weight: bold;
  display: inline-block;
  width: 1em;
  margin-right: 0.3rem;
}

/* --------------- Portfolio --------------- */
#work {
  height: 100%;
}

#work p {
  margin-bottom: 2rem;
}

.cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
}

.cards img{
   max-height: 535px;
   display: block;
}

.card {
  border-radius: 0.5rem;
  overflow: hidden;
}

.card-bg {
  background: var(--dark-blue);
  position: relative;
  width: 100%;
  height: 100%;
}

.card-bg:hover .description {
  bottom: 0;
}

.card-bg a,
.card p {
  color: #ddd;
}

.card-bg img {
  height: 100%;
}

.info {
  position: absolute;
  top: 0;
  left: 0;
  padding: 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  z-index: 1;
}

.info a:first-child {
  margin-right: 1.3rem;
}

.info a:hover {
  color: #fff;
}

.description {
  width: 100%;
  position: absolute;
  bottom: -9rem;
  padding: 0.5rem 1rem;
  transition: bottom 0.25s ease-in-out;
  background: rgb(9, 18, 53, 0.95);
}

.description ul {
  display: flex;
}

.description ul li {
  margin-right: 1rem;
}

.more-btn {
  margin: 3rem 0 0;
}

/* --------------- Contact --------------- */
.contact-wrapper {
  display: flex;
  justify-content: space-between;
}

#contact p {
  color: #ddd;
  margin-top: 1rem;
}

.contact-btn {
  border: 1px solid var(--light-blue);
}

.contact-btn::after {
  width: 0;
}

.message,
.message-info {
  flex: 3;
}

.message-info {
  background: var(--dark-blue);
  height: 100%;
}

.message-info li {
  padding-bottom: 1.5rem;
  padding: 1rem;
  border-bottom: 1px solid var(--darker-blue);
}

.message-info li:last-child {
  border-bottom: none;
}

/* --------------- Footer --------------- */
footer {
  padding: 7% 0 2%;
}
footer .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.brand div {
  display: flex;
  align-items: center;
}

.brand p {
  font-size: 0.8rem;
  margin-top: 0.3rem;
}

.social-media {
  display: flex;
  align-self: start;
}

.social-media a {
  font-size: 1.1rem;
  padding: 0 1rem;
  color: #ddd;
}

.social-media a:hover {
  color: #fff;
}

/* FadeIn Animation */

@keyframes btnFadeIn {
  0% {
    opacity: 0;
  }

  100% {
    opacity: 1;
  }
}

@keyframes mainFadeIn {
  0% {
    opacity: 0;
  }

  100% {
    opacity: 1;
  }
}

@keyframes secFadeIn {
  0% {
    opacity: 0;
  }

  100% {
    opacity: 0.75;
  }
}

@media (max-width: 880px) {
  nav ul {
    background: var(--dark-blue);
    position: absolute;
    top: 67px;
    right: -15rem;
    flex-direction: column;
    transition: right 0.5s ease-in-out;
    padding: 1rem;
    z-index: 10;
  }

  nav ul li {
    padding: 1.5rem 0;
  }

  .menu {
    display: block;
    cursor: pointer;
    z-index: 30;
  }

  nav ul.active {
    right: 0;
  }

  #showcase .container {
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    padding-top: 2%;
  }

  #showcase .btn {
    margin-bottom: 0;
  }
}

@media (max-width: 780px) {
  .profile {
    grid-template-columns: 1fr;
  }

  .profile-img {
    max-width: 300px;
  }
}

@media (max-width: 596px) {
  body {
    font-size: 0.9rem;
  }

  .container{
    padding: 0 3rem;
  }

  h1 {
    font-size: 3.5rem;
    margin-top: 0;
  }

  .showcase h1, .content{
    align-self:auto;
  }

  .cards{
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .cards img{
    max-height: 400px;
  }

  h2 {
    font-size: 1.5rem;
  }

  .btn {
    font-size: 1.1rem;
  }

  .contact-wrapper,
  footer .container {
    flex-direction: column;
    align-items: flex-start;
  }

  .message,
  .message-info{
      width: 100%;
  }

  .social-media {
    margin-top: 1rem;
  }

  .social-media a:first-child {
    padding-left: 0;
  }
}

@media (max-width: 375px) {
  h1 {
    font-size: 2.5rem;
  }

  .brand {
    font-size: 1rem;
  }

  .logo {
    width: 25px;
  }
}
