* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  text-decoration: none;
  scroll-behavior: smooth;
  font-family: "Poppins";
}

:root {
  --bg-color: #0f172a;
  --second-bg-color: #1e293b;
  --text-color: #f8fafc;
  --main-color: #38bdf8;
}

html {
  font-size: 60%;
  overflow-x: hidden;
}

body {
  background-color: var(--bg-color);
  color: var(--text-color);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

:focus-visible {
  outline: 3px solid var(--main-color);
  outline-offset: 4px;
}

span {
  background: linear-gradient(270deg, #0284c7 10%, #38bdf8 100%);
  background-clip: text;
  color: transparent;
}

::-webkit-scrollbar {
  width: 20px;
}

::-webkit-scrollbar-thumb {
  background-color: var(--main-color);
}

::-webkit-scrollbar-track {
  background-color: var(--bg-color);
}

.header {
  position: fixed;
  width: 100%;
  top: 0;
  left: 0;
  padding: 4rem 15%;
  background: rgba(0, 0, 0, 0.3);
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 1000;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.logo {
  font-size: 3rem;
  color: var(--text-color);
  font-weight: 800;
  cursor: pointer;
  transition: 0.3s;
}

.logo:hover {
  transform: scale(1.1);
}

#menu-icon {
  font-size: 3.5rem;
  color: var(--main-color);
  display: none;
}

.navbar a {
  font-size: 1.8rem;
  color: var(--text-color);
  margin-left: 4rem;
  font-weight: 500;
  transition: 0.3s ease-in-out;
  border-bottom: 3px solid transparent;
}

.navbar a:hover {
  color: var(--main-color);
  border-bottom: 3px solid var(--main-color);
}

.header-right {
  display: flex;
  align-items: center;
  gap: 3rem;
}

.lang-switch {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--text-color);
}

.lang-switch a {
  color: var(--text-color);
  opacity: 0.5;
  transition: 0.3s;
}

.lang-switch a.active,
.lang-switch a:hover {
  opacity: 1;
  color: var(--main-color);
}

.lang-switch span {
  color: var(--text-color);
  opacity: 0.3;
  background: none;
  -webkit-text-fill-color: initial;
}

.gradient-btn {
  font-size: 1.8rem;
  padding: 1rem 2rem;
  border-radius: 3rem;
  background: linear-gradient(270deg, #0284c7 10%, #38bdf8 100%);
  letter-spacing: 1px;
  cursor: pointer;
  transition: 0.3s ease-in-out;
  color: white;
  border: none;
  text-wrap: nowrap;
}

.gradient-btn:hover {
  transform: scale(1.05);
}

.btn-group {
  display: flex;
  gap: 1.5rem;
}

.btn {
  display: inline-block;
  padding: 1rem 3rem;
  background-color: var(--main-color);
  box-shadow: 0 4px 10px rgba(56, 189, 248, 0.3);
  border-radius: 3rem;
  font-size: 1.8rem;
  color: black;
  border: 2px solid transparent;
  font-weight: 600;
  transition: 0.3s ease-in-out;
}

.btn:hover {
  transform: scale(1.05);
  box-shadow: 0 0 15px rgba(56, 189, 248, 0.6);
}

.btn-group a:nth-of-type(2) {
  background-color: transparent;
  color: var(--main-color);
  border: 2px solid var(--main-color);
  box-shadow: 0 0 25px transparent;
}

.btn-group a:nth-of-type(2):hover {
  box-shadow: 0 0 25px var(--main-color);
  background-color: var(--main-color);
  color: var(--bg-color);
}

section {
  min-height: 100vh;
  padding: 10rem 15%;
}

.heading {
  text-align: center;
  font-size: 7rem;
  margin: 5rem 0;
  word-wrap: break-word;
}

.home {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15rem;
}

.home-content {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  text-align: right;
}

.home-content h1 {
  font-size: 8rem;
  font-weight: 700;
  margin-top: 1.5rem;
  line-height: 1;
}

.home-content h3 {
  margin: 1rem 0;
  font-size: 4rem;
}

.home-content p {
  font-size: 1.5rem;
  font-weight: 500;
  line-height: 1.8;
}

.home-img img {
  width: 32vw;
  border-radius: 50%;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.4);
  transition: 0.4s ease-in-out;
}

.home-img img:hover {
  box-shadow: 0 0 25px rgba(56, 189, 248, 0.6);
}

.social-icons a {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  font-size: 3rem;
  padding: 1rem;
  background: transparent;
  border: 2px solid var(--main-color);
  border-radius: 50%;
  color: var(--main-color);
  margin: 3rem 0.5rem;
  transition: 0.3s ease-in-out;
}

.social-icons a:hover {
  color: var(--text-color);
  background-color: var(--main-color);
  transform: scale(1.2)translateY(-5px);
  box-shadow: 0 0 15px rgba(56, 189, 248, 0.5);
}

.about {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10rem;
  background: var(--second-bg-color);
}

.about-img img {
  width: 32vw;
  border-radius: 50%;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.4);
  transition: 0.4s ease-in-out;
}

.about-img img:hover {
  box-shadow: 0 0 25px rgba(56, 189, 248, 0.6);
}

.about-content h2 {
  font-size: 7rem;
  text-align: left;
}

.about-content p {
  font-size: 1.8rem;
}

.about-content .btn {
  margin: 3rem 0;
}

.about-desc {
  font-size: 1.6rem;
  margin-bottom: 3rem;
  line-height: 1.8;
  color: var(--text-color);
  text-align: left;
}

.education-timeline {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  margin-bottom: 4rem;
}

.timeline-item {
  display: flex;
  align-items: center;
  gap: 2.5rem;
  background-color: var(--bg-color);
  padding: 2rem;
  border-radius: 1.5rem;
  border-left: 4px solid var(--main-color);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  transition: 0.3s ease-in-out;
}

.timeline-item:hover {
  transform: translateX(10px);
  box-shadow: 0 4px 15px rgba(56, 189, 248, 0.3);
}

.timeline-item i {
  font-size: 4.5rem;
  color: var(--main-color);
}

.timeline-content {
  text-align: left;
}

.timeline-content h3 {
  font-size: 2.2rem;
  margin-bottom: 0.5rem;
  color: var(--text-color);
}

.timeline-content p {
  font-size: 1.4rem;
  color: #94a3b8;
  font-weight: 400;
}

.skills {
  padding: 10rem 15%;
  background-color: var(--bg-color);
}

.skills .heading span {
  color: var(--main-color);
}

.skills-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  align-items: stretch;
  gap: 3rem;
}

.skill-box {
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: var(--second-bg-color);
  border-radius: 3rem;
  cursor: pointer;
  border: 2px solid transparent;
  transition: 0.4s ease-in-out;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  height: auto;
  min-height: 400px;
  padding: 4rem 2rem;
}

.skill-box:hover {
  border: 2px solid var(--main-color);
  transform: translateY(-10px);
  box-shadow: 0 10px 25px rgba(56, 189, 248, 0.2);
}

.skill-info {
  display: flex;
  flex-direction: column;
  text-align: center;
  justify-content: flex-start;
  align-items: center;
  padding: 4rem 3rem;
  height: 100%;
}

.skill-info i {
  font-size: 6rem;
  color: var(--main-color);
  margin-bottom: 1.5rem;
}

.skill-info h4 {
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
  color: var(--text-color);
}

.skill-info p {
  font-size: 1.4rem;
  font-weight: 400;
  line-height: 1.6;
  color: #94a3b8;
  margin-bottom: 2rem;
}

.skill-list {
  list-style: none;
  width: 100%;
  text-align: center;
}

.skill-list li {
  font-size: 1.5rem;
  color: var(--text-color);
  padding: 0.8rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.skill-list li:last-child {
  border-bottom: none;
}

.projects {
  background-color: var(--second-bg-color);
}

.projects-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
  padding: 0 7rem;
}

.projects-box {
  display: flex;
  overflow-x: auto;
  gap: 3rem;
  padding: 3rem 2rem 5rem;
  scroll-behavior: smooth;
  scroll-snap-type: x mandatory;
  scrollbar-width: auto;
  justify-content: flex-start;
  width: 100%;
}

.projects-box::-webkit-scrollbar {
  display: block;
  height: 18px;
}

.projects-box::-webkit-scrollbar-track {
  background: var(--bg-color);
  border-radius: 10px;
}

.projects-box::-webkit-scrollbar-thumb {
  background: var(--main-color);
  border-radius: 20px;
  border: 4px solid var(--bg-color);
}

.projects-box::-webkit-scrollbar-thumb:hover {
  background: #0284c7;
}

.projects-card {
  flex: 0 0 calc((100% - 6rem) / 3);
  min-height: 450px;
  background: var(--bg-color);
  border: 2px solid transparent;
  padding: 4rem 3rem;
  border-radius: 4rem;
  scroll-snap-align: center;
  transition: 0.5s ease;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.projects-card:hover {
  border-color: var(--main-color);
  transform: scale(1.03);
  box-shadow: 0 0 30px rgba(56, 189, 248, 0.2);
}

.projects-card .card-content {
  display: flex;
  flex-direction: column;
}

.projects-card .card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 2.5rem;
}

.projects-card .card-header i {
  font-size: 5rem;
  color: var(--text-color);
  transition: 0.3s;
}

.projects-card:hover .card-header i {
  color: var(--main-color);
}

.tech-tag {
  background: rgba(56, 189, 248, 0.1);
  color: var(--main-color);
  padding: 0.6rem 1.5rem;
  border-radius: 2rem;
  font-size: 1.3rem;
  font-weight: 600;
  border: 1px solid rgba(56, 189, 248, 0.3);
  letter-spacing: 1px;
}

.projects-card h3 {
  font-size: 2.6rem;
  margin-bottom: 1.5rem;
  color: var(--text-color);
  text-transform: capitalize;
}

.projects-card p {
  font-size: 1.5rem;
  color: #94a3b8;
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 3rem;
}

.projects-card .btn {
  width: 100%;
  text-align: center;
}

.projects-card:last-child {
  margin-right: 2rem;
}

.projects-box::after {
  content: '';
  flex: 0 0 1px;
}

.scroll-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: var(--main-color);
  color: var(--bg-color);
  border: none;
  width: 5rem;
  height: 5rem;
  border-radius: 50%;
  font-size: 3rem;
  cursor: pointer;
  z-index: 10;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: 0.3s;
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.5);
}

.scroll-btn:hover {
  transform: translateY(-50%) scale(1.1);
  box-shadow: 0 0 20px var(--main-color);
}

.scroll-btn.left {
  left: -2rem;
}

.scroll-btn.right {
  right: -2rem;
}

.projects-card.github-more-card {
  background: linear-gradient(145deg, var(--second-bg-color), var(--bg-color));
  border: 2px dashed var(--main-color);
  text-align: center;
  justify-content: center;
}

.projects-card.github-more-card i {
  font-size: 10rem;
  margin-bottom: 2rem;
  color: var(--main-color);
  filter: drop-shadow(0 0 10px rgba(56, 189, 248, 0.5));
}

.contact {
  background-color: var(--bg-color);
}

.contact-container {
  display: flex;
  gap: 5rem;
  align-items: center;
  justify-content: center;
  margin-top: 5rem;
}

.contact-info {
  flex: 1;
  max-width: 500px;
}

.contact-info h3 {
  font-size: 3.5rem;
  color: var(--text-color);
  margin-bottom: 2rem;
}

.contact-info p {
  font-size: 1.6rem;
  color: #94a3b8;
  line-height: 1.6;
  margin-bottom: 4rem;
}

.info-item {
  display: flex;
  align-items: center;
  gap: 2rem;
  margin-bottom: 3rem;
}

.info-item i {
  font-size: 3.5rem;
  color: var(--main-color);
  background: rgba(56, 189, 248, 0.1);
  padding: 1.5rem;
  border-radius: 50%;
  transition: 0.3s ease;
}

.info-item:hover i {
  background: var(--main-color);
  color: var(--bg-color);
  transform: scale(1.1);
}

.info-item h4 {
  font-size: 1.8rem;
  color: var(--text-color);
  margin-bottom: 0.5rem;
}

.info-item p {
  font-size: 1.5rem;
  color: #94a3b8;
  margin-bottom: 0;
}

.contact-form {
  flex: 1;
  background: var(--second-bg-color);
  padding: 5rem 4rem;
  border-radius: 3rem;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
}

.contact-form .input-box {
  display: flex;
  gap: 2rem;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 2rem;
  font-size: 1.6rem;
  color: var(--text-color);
  background-color: var(--bg-color);
  border-radius: 1.5rem;
  border: 2px solid transparent;
  margin-bottom: 2rem;
  transition: 0.3s;
  outline: none;
}

.contact-form input:focus,
.contact-form textarea:focus {
  border-color: var(--main-color);
  box-shadow: 0 0 10px rgba(56, 189, 248, 0.2);
}

.contact-form textarea {
  resize: none;
  height: 200px;
}

.contact-form .btn {
  width: 100%;
  cursor: pointer;
  text-align: center;
}

.footer {
  background-color: var(--second-bg-color);
  padding: 4rem 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}

.footer .list {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 3rem;
  list-style: none;
  margin-bottom: 1rem;
}

.footer .list li a {
  font-size: 1.6rem;
  color: var(--text-color);
  transition: 0.3s;
  opacity: 0.8;
}

.footer .list li a:hover {
  color: var(--main-color);
  opacity: 1;
}

.footer .copyright {
  font-size: 1.4rem;
  color: #94a3b8;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 2rem;
  width: 80%;
  text-align: center;
}

@media (max-width: 1400px) {
  .scroll-btn {
    display: none;
  }
  .projects-wrapper {
    padding: 0;
  }
}

@media (max-width: 1285px) {
  .header {
    padding: 2rem 5%;
  }
  .logo {
    flex: 1;
  }
  #menu-icon {
    display: block;
    cursor: pointer;
    order: 3;
  }
  .header-right {
    order: 2;
    gap: 2rem;
    margin-right: 2.5rem;
  }
  .header-right .gradient-btn {
    display: none;
  }
  .navbar {
    position: absolute;
    top: 100%;
    right: 0;
    width: 50%;
    padding: 1rem 3rem;
    background: rgba(0, 0, 0, 0.8);
    border-bottom-left-radius: 2rem;
    border-left: 2px solid var(--main-color);
    border-bottom: 2px solid var(--main-color);
    display: none;
  }
  .navbar.active {
    display: block;
  }
  .navbar a {
    display: block;
    font-size: 2rem;
    margin: 3rem 0;
    color: var(--text-color);
  }
  .home {
    flex-direction: column-reverse;
    margin: 5rem 0;
    gap: 5rem;
  }
  .home-content {
    align-items: center;
    text-align: center;
  }
  .home-img img {
    width: 56vw;
  }
  .about {
    flex-direction: column-reverse;
    text-align: center;
  }
  .about h2 {
    text-align: center;
    margin: 2rem 0;
  }
  .about img {
    width: 52vw;
  }
}

@media (max-width: 1024px) {
  .projects-card {
    flex: 0 0 calc((100% - 3rem) / 2);
  }
  .contact-container {
    flex-direction: column;
  }
  .contact-info,
  .contact-form {
    max-width: 100%;
    width: 100%;
  }
  .contact-form .input-box {
    flex-direction: column;
    gap: 0;
  }
}

@media (max-width: 768px) {
  .lang-switch {
    background: rgba(56, 189, 248, 0.1);
    padding: 0.5rem 1.2rem;
    border-radius: 2rem;
    border: 1px solid rgba(56, 189, 248, 0.2);
  }
  .lang-switch a {
    font-size: 1.4rem;
  }
  .lang-switch a.active {
    text-shadow: 0 0 8px var(--main-color);
  }
  .projects-card {
    flex: 0 0 100%;
  }
  .heading {
    font-size: 5rem;
  }
}

@media (max-width: 450px) {
  .header-right {
    gap: 1rem;
    margin-right: 1.5rem;
  }
  .lang-switch {
    font-size: 1.4rem;
  }
  .heading {
    font-size: 4rem;
    margin: 3rem 0;
  }
  .footer .list {
    gap: 1.5rem;
  }
}