html {
  scroll-behavior: smooth;
  scrollbar-width: thin;

  font-size: 68.75%;
}

body, * {
  font-family: sans-serif;
}

* {
  line-height: 1.6;
}

*::selection {
  background-color: black;
  color: white;
}

a {
  text-decoration: none;
}

.video-frame video {
  width: 100% !important;
  height: 100% !important;
  scale: 1.5;
}

.tag {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 1rem;
  font-size: 1rem;
  cursor: pointer;
}

.tag:not(.live) {
  background-color: #eee;
  color: #333;
}

.container video {
  display: block;
}

/* start nav */

nav {
  width: fit-content;
  backdrop-filter: blur(16px);
  background-color: rgba(232, 229, 228, 0.5);
  margin: 2rem auto;
  padding: 0.25rem;
  border-radius: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 3px;
  position: fixed !important;
  
  /* to center a positioned element */
  left: 0;
  right: 0;
  top: 0;
  z-index: 1;
  outline: none;

  & * {
    outline: none;
  }
}

nav a {
  font-size: small;
  padding: 0.6rem 1.5rem;
  border-radius: calc(2rem + 0.3rem);
}

nav a:hover {
  color: initial;
}

nav a.active {
  background-color: white;
}

nav a button,
nav a img,
nav a button:active,
nav a button:focus,
nav a img:active,
nav a img:focus {
  background-color: inherit;
  color: black initial !important;
  border: none !important;
}

/* end nav */

/* start header */

header.home {
  width: 85%;
}

header {
  min-height: 30rem;
  width: 90%;
  margin: 1vh auto -5vh auto;
} 

header > div {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  height: 60vh;
  margin-top: 6rem;
}

header > div > .tags {
  margin-top: 2rem;
  margin-bottom: 3rem;
  display: none !important;
  overflow: hidden;
  
  @media (min-width: 768px) {
    display: flex !important;
    justify-content: center;
    gap: 1rem;
  }
}

header > div p {
  width: 80%;
  margin-bottom: 1rem;
  font-size: 72px;
}

/* end header */

/* start projects */

.project {
  position: relative;
  transition: 0.4s;
}

.project.locked .texts {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

@media (min-width: 1200px) {
  .project.locked .texts {
    display: block;
  }
}

.project .anchor {
  display: none;
}

@media (min-width: 1200px) {
  .project .anchor {
    position: absolute;
    display: block;
    top: 0;
    right: 0;
    background-color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 50%;
    width: 2.6rem;
    height: 2.6rem;
    margin: 3rem;
    opacity: 0;
    transition: 0.4s;
    z-index: 2;
  }
}

.project .texts p {
  font-size: 1rem !important;
  margin: 0;
}

.project .texts {
  padding-top: 1rem;
  font-size: 0.8rem;
  opacity: 0;
  transition: 0.4s;
  color: black;
}

.project .frame {
  height: 100%;
}

@media (max-width: 576px) {
  .project > .frame {
    height: 82% !important;
  }
}

@media (max-width: 1200px) {
  .project > .frame {
    height: 90%;
  }

  .project .texts {
    opacity: 1;
  }
}

@media (min-width: 1200px) {
  .project .texts {
    position: absolute;
    top: 0;
    color: white;
    padding: 1rem;
  }

  .project:hover {
    background: rgba(0, 0, 0, 0.3);
  }

  .project:hover .texts {
    opacity: 1;
    z-index: 2;
  }

  .project:hover .anchor {
    opacity: 1;
    margin: 1.5rem;
  }

  .project:hover > .frame {
    filter: blur(16px);
  }
}

@media (min-width: 1200px) {
  .project > .frame {
    filter: blur(0);
    transition: 0.4s;
    width: 100%;
    height: 100%;
    display: block;
  }
}

.project > .frame > * {
  width: 100%;
}

.project:has(.frame) {
  height: 100%;
}

.project > .frame video {
  height: 100%;
  scale: 1.3;
}

/* end projects */

/* start contact */

.contact {
  height: 30vh;
  margin: 8rem auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  
  & > * {
    font-size: 2.5rem !important;
    line-height: 1.2 !important;
    font-weight: 500;
  }

  @media (max-width: 576px) {
    & > * {
      font-size: 2rem !important;
    }
  }
}

/* end contact */

/* start footer */

footer .item > img {
  width: 2rem;
}

footer .item > ul {
  list-style: none;
  padding: 0;
  margin: 0;

  & li {
    display: contents;

    &:hover {
      color: #888 !important;
    }
  }

  & a {
    color: unset;
    text-decoration: none;
  }
}

.item.social ul {
  justify-content: center;
  flex-wrap: wrap;
}

/* Amr khaled's code */
h2.mainText {
  width: 90%;
}

@media only screen and (max-width: 576px) {
  .mainText {
    font-size: 2em;
  }
}

@media only screen and (min-width: 576px) {
  .mainText {
    font-size: 3em;
  }
}

@media only screen and (min-width: 768px) {
  .mainText {
    font-size: 4em;
  }
}
