/* general */
:root {
  --highlight-color: #eb4d4b;
  --dark-color: #172b38;
  --darker-color: #2f4858;
  --grey-color: #CCC;
  --light-color: #E1ECF4;
}

* {
  margin: 0;
  padding: 0;
  border: none;
}

body {
  display: flex;
  height: 100%;
  width: 100%;
}

i {
  color: var(--dark-color);
  transition: color 0.3s ease-in-out;
}

input, p, a, button, li {
  font-family: Georgia, 'Times New Roman', Times, serif;
  text-decoration: none;
  transition: color 0.3s ease-in-out;
}

a {
  color: var(--dark-color);
}

button {
  background: none;
	border: none;
}

h1, h2, h3 {
  font-family: Arial, Helvetica, sans-serif;
}

ul {
  list-style: inside;
  list-style-type: circle;
}

img {
  height: auto;
}

section {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  max-width: 1200px;
  height: 100vh;
  padding: 0 8vw;
}

section > h1 {
  font-size: 4em;
  letter-spacing: 0.06em;
  text-align: center;
  margin: 0.5em;
  font-weight: 900;
}

.highlight {
  color: var(--highlight-color)
}

/* navbar */

nav {
  position: sticky;
  top: 0;
  left: 0;
  padding: 10vh 2.5vw;
  width: 100%;
  max-width: 260px;
  min-width: 200px;
  max-height: 80vh;
  z-index: 20;
  background-color: var(--light-color);
  transform: translateX(0);
  transition: transform .4s, opacity .4s ease-out, box-shadow 0.5s, color 0.3s ease-in-out, background-color 0.3s ease-in-out;
}

nav:hover {
  box-shadow: 2px 0px 20px -3px var(--darker-color);
}

#nav-content {
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  align-items: center;
  height: 100%;
}


#menu-btn {
  font-size: 2em;
  visibility: hidden;
  position: fixed;
  top: 1em;
  right: 8vw;
  height: 50px;
  width: 50px;
  box-shadow: 0px 0px 4px var(--darker-color);
  border-radius: 5px;
  z-index: 12;
}

#menu-btn > i {
  transform: translateY(2px);
}

#profile-pic {
  object-fit: cover;
  width: 100%;
  border-radius: 100%;
  box-shadow: 0 10px 18px -10px var(--darker-color);
  transition: all .4s;
}

#profile-pic:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 22px -5px var(--highlight-color);
}

#nav-links {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 1em;
}

#nav-links > a {
  font-weight: 700;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 1.5em;
}

#nav-links > a > i {
  width: 27px;
  text-align: right;
  margin-right: 4px;
}

#social-links > a {
  font-weight: 700;
  font-size: 3.5em;
  text-align: center;
}

#social-links > a > i:hover,
#nav-links > a:hover i,
#nav-links > a i:hover,
a:hover {
  color: var(--highlight-color);
}

#social-links {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1em;
}

#options {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1em;
}

/* image carousel */
.image-carousel {
  display: grid;
  aspect-ratio: 16/10;
}

.slide-container {
  margin-top: 0.5em;
  position: relative;
  border-radius: 15px;
  box-shadow: 0 10px 18px -10px var(--darker-color);
  overflow: hidden;
}

.slide {
  display: flex;
  justify-content: center;
  position: absolute;
  background-color: var(--darker-color);
  width: 100%;
  height: 100%;
  transition: all 0.5s;
  overflow: hidden;
}

.slide img {
  height: auto;
  object-fit: contain;
}

.slide a {
  display: flex;
  justify-content: center;
}

.btn {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 20%;
  z-index: 10;
  font-size: 18px;
  transition: all 200ms ease;
}

.btn-prev {
  left: 0;
}

.btn-prev:hover {
  box-shadow: inset 20px 0 22px -20px var(--highlight-color);
  cursor: pointer;
}

.btn-next {
  right: 0;
}

.btn-next:hover {
  box-shadow: inset -20px 0 22px -20px var(--highlight-color);
  cursor: pointer;
}
/* start from w3 >>>>>> */
/* rounded toggle slider */
/* The switch - the box around the slider */
.switch {
  justify-self: flex-start;
  position: relative;
  display: inline-block;
  width: 60px;
  height: 34px;
}

/* Hide default HTML checkbox */
.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

/* The slider */
.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: var(--grey-color);
  -webkit-transition: .4s;
  transition: .4s;
}

.slider:hover {
  background-color: var(--highlight-color);
}

.slider:before {
  position: absolute;
  content: "";
  height: 26px;
  width: 26px;
  left: 4px;
  bottom: 4px;
  background-color: var(--light-color);
  -webkit-transition: .4s;
  transition: .4s ease-out;
}

input:checked + .slider {
  background-color: var(--darker-color);
}

input:checked + .slider:before {
  background-color: var(--dark-color);
}

input:checked + .slider:hover {
  background-color: var(--highlight-color);
}

input:focus + .slider {
  box-shadow: 0 0 1px var(--dark-color);
}

input:checked + .slider:before {
  -webkit-transform: translateX(26px);
  -ms-transform: translateX(26px);
  transform: translateX(26px);
}

/* Rounded sliders */
.slider.round {
  border-radius: 34px;
}

.slider.round:before {
  border-radius: 50%;
}
/* end from w3 >>>>>> */

/* intro */
main {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 100%;
  background-color: var(--light-color);
  transition: background-color 0.3s ease-in-out;
}

#top > h1 {
  font-size: 4em;
  letter-spacing: 0.05em;
  margin: 0;
}

/* about me */
#about-me > p {
  font-size: 1.5em;
  text-align: center;
  line-height: 1.4em;
  letter-spacing: 0.07em;
}

/* portfolio */
#projects {
  height: inherit;
  justify-content: flex-start;
  margin: 5em 0em;
}

#works {
  display: flex;
  flex-direction: column;
  gap: 2em;
}

#works h3 {
  margin-top: 1em;
}

.work > h2 {
  font-size: 3em;
  text-align: center;
}

.work > p {
  line-height: 1.4em;
}

/* dark mode */
/* light theme */
.d-background-light {
  background-color: var(--light-color);
}

.d-text-light {
  color: var(--dark-color);
}

.d-button-light {
  background-color: var(--light-color);
}

/* dark theme */
.d-background-dark {
  background-color: var(--dark-color);
}

.d-text-dark {
  color: var(--light-color);
}

.d-button-dark {
  background-color: var(--dark-color);
}

/* utilities */
.fullscreen {
  position: fixed;
  z-index: 100;
  inset: 2em;
}

.fullscreen::before {
  content: '';
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  opacity: 80%;
  background-color: var(--dark-color);
}

/* animations */
.fade-in {
  opacity: 0;
  transform: translateX(-300px);
  transition: transform .4s ease-in, opacity .6s linear;
  transition-delay: 0.5s;
}

.fade-up {
  opacity: 0;
  transform: translateY(300px);
  transition: transform .4s ease-in, opacity .6s linear;
  transition-delay: 0.5s;
}

.scroll-fade-in {
  opacity: 1;
  transform: translateX(0);
}


@media (max-height: 800px) {
  nav {
    padding: 0 2.5vw;
    max-height: 100vh;
  }
}

@media (max-width: 480px) {
  nav {
    padding: 0 1em;
  }

  section {
    padding: 0 1em;
  }

  #menu-btn {
    right: 0.5em;
  }
}

@media (max-width: 980px) {
  nav {
    position: fixed;
    bottom: 0;
    opacity: 0;
    box-shadow: 2px 0px 20px -3px var(--darker-color);
    max-height: inherit;
    transform: translateX(-300px);
  }
  
  #nav-content {
    justify-content: space-evenly;
  }
  
  #menu-btn {
    visibility: visible;
  }
}