@import url("https://fonts.googleapis.com/css2?family=Clicker+Script&family=Poppins:wght@300;400;500;600&display=swap");
/* LIGHT MODE (default) */
:root {
  --bg-black-900: #f2f2fc;
  --bg-black-100: #fdf9ff;
  --bg-black-50: #e8dfec;
  --text-black-900: #302e4d;
  --text-black-700: #504e70;
}

html,
body {
  max-width: 100vw;
  overflow-x: hidden;
}

html {
  scroll-behavior: smooth;
}

html.dark-mode-preload body {
  background-color: #151515; /* Same as your dark background */
  color: white;
}

/* DARK MODE (when body has class 'dark') */
body.dark {
  --bg-black-900: #151515;
  --bg-black-100: #222222;
  --bg-black-50: #393939;
  --text-black-900: #ffffff;
  --text-black-700: #cccccc;
}

/* Ensure text in Education and Experience is white in dark mode */
.about .about-content .timeline h4,
.about .about-content .timeline p,
.about .about-content .timeline span,
.about .about-content .title {
  color: var(--text-black-900); /* White text in dark mode */
}

/* Ensure text in other sections is white in dark mode */
.about .about-content .timeline h4,
.about .about-content .timeline p,
.about .about-content .timeline span,
.about .about-content .title {
  color: var(--text-black-900); /* White text in dark mode */
}

body.dark .btn:hover {
  color: var(--bg-black-900); /* makes text visible in dark mode */
}

body {
  margin: 0;
  padding: 0;
  line-height: 1.5;
  font-size: 16px;
}

*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  text-decoration: none;
  outline: none;
}

::before,
::after {
  box-sizing: border-box;
}
ul {
  list-style: none;
}
/* Slide Transition Fix */
.section.back-section {
  z-index: 1;
}
.section {
  background-color: var(--bg-black-900);
  min-height: 100vh;
  padding: 0px 30px;
  position: fixed; /* Changed from fixed */
  top: 0;
  left: 270px;
  right: 0;
  bottom: 0;
  overflow-y: auto;
  overflow-x: hidden;
  opacity: 0;
  visibility: hidden;
  transform: translateX(100%);
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.section.active {
  opacity: 1;
  transform: translateX(0);
  visibility: visible;
  pointer-events: auto;
}

@keyframes slideIn {
  from {
    transform: translateX(100%);
  }
  to {
    transform: translateX(0%);
  }
}

/* Ensure the current (leaving) section sits underneath */
.section.back-section {
  z-index: 1;
}

/* aside */
.aside {
  width: 270px;
  background-color: var(--bg-black-100);
  position: fixed;
  left: 0;
  top: 0;
  padding: 30px;
  border-right: 10px solid var(--bg-black-100);
  z-index: 999;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.aside .logo {
  position: absolute;
  top: 50px;
  font-size: 30px;
  text-transform: capitalize;
}

.aside .logo a {
  color: var(--text-black-900);
  font-weight: 700;
  padding: 15px 20px;
  font-size: 30px;
  letter-spacing: 5px;
  position: relative;
}

.aside .logo a span {
  font-family: "Clicker Script", cursive;
  font-size: 40px;
}

.aside .logo a:before {
  content: "";
  position: absolute;
  width: 20px;
  height: 20px;
  border-bottom: 5px solid var(--skin-color);
  border-left: 5px solid var(--skin-color);
  bottom: 0;
  left: 0;
}

.aside .logo a:after {
  content: "";
  position: absolute;
  width: 20px;
  height: 20px;
  border-top: 5px solid var(--skin-color);
  border-right: 5px solid var(--skin-color);
  top: 0;
  right: 0;
}

.nav-toggle.hide {
  display: none;
}

.aside .nav-toggle {
  height: 40px;
  width: 45px;
  border: 1px solid var(--bg-black-50);
  cursor: pointer;
  position: fixed;
  left: 300px;
  top: 20px;
  border-radius: 5px;
  background: var(--bg-black-100);
  display: none;
  justify-content: center;
  align-items: center;
}

.aside .nav-toggle span {
  height: 2px;
  width: 18px;
  background: var(--skin-color);
  display: inline-block;
  position: relative;
}

.aside .nav-toggle span::before {
  content: "";
  height: 2px;
  width: 18px;
  background: var(--skin-color);
  position: absolute;
  top: -6px;
  left: 0;
}

.aside .nav-toggle span::after {
  content: "";
  height: 2px;
  width: 18px;
  background: var(--skin-color);
  position: absolute;
  top: 6px;
  left: 0;
}
.aside .nav {
  margin-top: 50px;
}

.aside .nav li {
  margin-bottom: 20px;
  display: block;
}

.aside .nav li a {
  font-size: 16px;
  font-weight: 600;
  display: block;
  color: var(--text-black-900);
  padding: 5px 15px;
  border-bottom: 1px solid var(--bg-black-50);
}

.aside .nav li a.active {
  color: var(--skin-color);
}

.aside .nav li a i {
  margin-right: 15px;
}

/*home section  */
.home .home-img img {
  height: 400px;
  margin: auto;
  border-radius: 5px;
}

.container {
  max-width: 1100px;
  width: 100%;
  margin: auto;
}

.padd-15 {
  padding-left: 15px;
  padding-right: 15px;
  flex: 0 0 100%;
  max-width: 100%;
}

.row {
  display: flex;
  flex-wrap: wrap;
  margin-left: -15px;
  margin-right: -15px;
  position: relative;
}

.home {
  height: 400px;
  display: flex;
  color: var(--text-black-900);
}

.home .home-info {
  flex: 0 0 60%;
  max-width: 60%;
}

.home .home-img {
  flex: 0 0 40%;
  max-width: 40%;
  text-align: center;
  position: relative;
}

.home-img::after {
  content: "";
  position: absolute;
  width: 80px;
  height: 80px;
  right: 20px;
  bottom: 0px;
  border-bottom: 10px solid var(--skin-color);
  border-right: 10px solid var(--skin-color);
}

.home-img::before {
  content: "";
  position: absolute;
  width: 80px;
  height: 80px;
  left: -20px;
  top: -40px;
  border-top: 10px solid var(--skin-color);
  border-left: 10px solid var(--skin-color);
}

.home-img:hover img {
  transform: scale(1.05); /* Slight grow */
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2); /* Optional depth */
}

h3.hello {
  font-size: 28px;
  margin: 15px 0;
}

h3.hello span {
  font-family: "Clicker Script", cursive;
  font-size: 30px;
  font-weight: 700;
  color: var(--skin-color);
}

h3.my-pofession {
  font-size: 30px;
  margin: 15px 0;
}

.typing {
  color: var(--skin-color);
}

.home-info p {
  margin-bottom: 70px;
  font-size: 20px;
  color: var(--text-black-900);
}

.btn {
  font-size: 16px;
  font-weight: 500;
  padding: 12px 35px;
  color: white;
  border-radius: 40px;
  display: inline-block;
  white-space: nowrap;
  background: var(--skin-color);
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  background: linear-gradient(to right, var(--skin-color), #ff5757);
  border: none;
}

.btn:hover {
  background: var(--text-black-900);
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2); /* More lift */
}

/* about section */

.hidden {
  display: none;
}

.section .container {
  padding-top: 60px;
  padding-bottom: 70px;
}

.section-title {
  flex: 0 0 100%;
  max-width: 100%;
  margin-bottom: 60px;
}

.section-title h2 {
  font-size: 40px;
  color: var(--text-black-900);
  font-weight: 700;
  position: relative;
}

.section-title h2::before {
  content: "";
  height: 4px;
  width: 50px;
  background-color: var(--skin-color);
  position: absolute;
  top: 100%;
  left: 0;
}

.section-title h2::after {
  content: "";
  height: 4px;
  width: 25px;
  background-color: var(--skin-color);
  position: absolute;
  top: 100%;
  left: 0;
  margin-top: 8px;
}

.about .about-content {
  display: flex; /* Ensure flexbox is applied */
  flex-wrap: wrap; /* Allow wrapping if needed */
  gap: 30px; /* Optional: Add spacing between items */
}

.about .about-content .about-text {
  flex: 0 0 100%;
  max-width: 100%;
}

.about .about-content .about-text h3 {
  font-size: 24px;
  color: var(--text-black-900);
  margin-bottom: 15px;
  font-weight: 700;
}

.about .about-content .about-text h3 span {
  color: var(--skin-color);
}

.about .about-content .about-text p {
  font-size: 16px;
  line-height: 25px;
  color: var(--text-black-700);
}

.about .about-content .personal-info {
  flex: 0 0 60%;
  max-width: 60%;
  margin-top: 40px;
}

.about .about-content .skills {
  flex: 0 0 40%;
  max-width: 40%;
  margin-top: 40px;
}

.about .about-content .personal-info .info-item {
  flex: 0 0 50%;
  max-width: 50%;
}

.about .about-content .personal-info .info-item p {
  font-weight: 600;
  padding: 10px 0;
  font-size: 16px;
  color: var(--text-black-900);
  border-bottom: 1px solid var(--bg-black-50);
  margin-left: 4px;
  display: inline-block;
}

.about .about-content .personal-info .buttons {
  flex: 0 0 100%;
  max-width: 100%;
  margin-top: 30px;
}

.about .about-content .personal-info .buttons .btn {
  margin-right: 20px;
  margin-top: 10px;
}

.about .about-content .personal-info .info-item p span {
  font-weight: 400;
  color: var(--text-black-700);
}

.about .about-content .skills .skill-item {
  flex: 0 0 40%;
  max-width: 40%;
  margin-top: 40px;
  margin-bottom: 25px;
  position: relative; /* For positioning skill-percent */
}

.skill-item {
  flex: 0 0 50%;
  max-width: 50%;
  position: relative; /* keep this */
}

.skill-item h5 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 5px;
  color: var(--text-black-900);
}

.skill-percent {
  position: absolute;
  top: 0;
  right: 15px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-black-700);
}

.progress {
  background-color: var(--bg-black-50);
  height: 10px;
  width: 100%;
  border-radius: 10px;
  overflow: hidden;
  position: relative;
  margin-top: 20px;
}

.progress-in {
  background-color: var(--skin-color);
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
  transition: width 0.6s ease;
}

.about .about-content .row.full-width {
  display: flex;
  flex-wrap: wrap;
  width: 100%;
  margin-top: 30px;
}

.about .about-content .education,
.about .about-content .experience {
  flex: 1; /* takes up equal space */
  padding: 20px;
}

.about .about-content .h3 .title {
  font-size: 24px;
  color: var(--text-black-900);
  margin-bottom: 30px;
  font-weight: 700;
}

.about .about-content .timeline-box {
  flex: 0 0 100%;
  max-width: 100%;
}

.about .about-content .timeline {
  background-color: var(--bg-black-100);
  padding: 30px 15px;
  border: 1px solid var(--bg-black-50);
  border-radius: 10px;
  width: 100%;
  position: relative;
}

.shadow-dark {
  box-shadow: 0 0 20px rgba(48, 46, 77, 0.15);
}

.about
  .about-content
  .timeline
  .timeline-items
  .timeline-item.timeline-item:last-child {
  margin-bottom: 0;
}
.about .about-content .timeline .timeline-items {
  position: relative;
  padding-left: 30px;
}

.about .about-content .timeline .timeline-items::before {
  content: "";
  position: absolute;
  width: 2px;
  height: 100%;
  background-color: var(--skin-color);
  left: 0;
  top: 0;
}

.about .about-content .timeline .timeline-items .timeline-item .circle-dot {
  position: absolute;
  left: 0;
  top: 0;
  height: 15px;
  width: 15px;
  border-radius: 50%;
  background-color: var(--skin-color);
  transform: translate(-40%, -50%);
}

.about .about-content .timeline span {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-black-700);
  margin-bottom: 10px;
}

.about .about-content .timeline .fa {
  margin-right: 5px;
}

.about .about-content .timeline h4 {
  color: var(--text-black-900); /* This should switch to white in dark mode */
  font-weight: 700;
  font-size: 18px;
  margin-bottom: 15px;
  text-transform: capitalize;
}

/* Services Section */
.section .container {
  padding: 40px;
}
.service .service-item {
  margin-bottom: 30px;
  flex: 0 0 33.33%;
  max-width: 33.33%;
}

.section .service-item .service-item-inner {
  background-color: var(--bg-black-100);
  padding: 30px 15px;
  border: 1px solid var(--bg-black-50);
  border-radius: 10px;
  position: relative;
  box-shadow: 0 0 20px rgba(48, 46, 77, 0.15);
  text-align: center;
  transition: all 0.3s ease;
}

.service-item .service-item-inner:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2); /* Optional depth */
}

.section .service-item .service-item-inner .icon {
  height: 60px;
  width: 60px;
  border-radius: 50%;
  display: block;
  margin: 0 auto 30px;
  text-align: center;
  transition: all 0.3s ease;
}

.section .service-item .service-item-inner .icon .fa {
  font-size: 40px;
  line-height: 60px;
  color: var(--skin-color);
  transition: all 0.3s ease;
}

.section .service-item .service-item-inner:hover .icon {
  background: var(--skin-color);
}
.section .service-item .service-item-inner:hover .icon .fa {
  font-size: 25px;
  color: white;
}

.section .service-item .service-item-inner h4 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 15px;
  color: var(--text-black-900);
  text-transform: capitalize;
}
.section .service-item .service-item-inner p {
  font-size: 16px;
  color: var(--text-black-700);
  line-height: 25px;
}

/* Contact Section */

.contact-title {
  color: var(--skin-color);
  text-align: center;
  font-size: 25px;
  margin-bottom: 20px;
}

.contact-sub-title {
  color: var(--text-black-900);
  text-align: center;
  font-size: 15px;
  margin-bottom: 60px;
}

.contact .contact-info-item {
  flex: 0 0 25%;
  max-width: 25%;
  margin-bottom: 60px;
  text-align: center;
}

.contact .contact-info-item .icon {
  display: inline-block;
}

.contact .contact-info-item .icon .fa {
  font-size: 25px;
  color: var(--skin-color);
}

.contact .contact-info-item .icon .fa:hover {
  color: var(--text-black-900);
}

.contact .contact-info-item h4 {
  font-size: 18px;
  color: var(--text-black-900);
  margin: 15px 0 5px;
  font-weight: 700;
  text-transform: capitalize;
}

.contact .contact-info-item p {
  font-size: 16px;
  color: var(--text-black-700);
  line-height: 25px;
  font-weight: 400;
}

.contact .contact-form {
  flex: 0 0 100%;
  max-width: 100%;
}

.contact .contact-form .col-6 {
  flex: 0 0 50%;
  max-width: 50%;
}

.contact .contact-form .col-12 {
  flex: 0 0 100%;
  max-width: 100%;
}

.contact .contact-form .form-item {
  margin-bottom: 30px;
}

.contact .contact-form .form-item .form-control {
  width: 100%;
  height: 50px;
  border-radius: 25px;
  background: var(--bg-black-100);
  border: 1px solid var(--bg-black-50);
  padding: 10px 25px;
  font-size: 16px;
  color: var(--text-black-700);
  transition: all 0.3 ease;
}

.contact .contact-form .form-item .form-control:focus {
  box-shadow: 0 0 20px rgba(48, 46, 77, 0.15);
}

.contact .contact-form .form-item textarea.form-control {
  height: 140px;
}

.contact .contact-form .btn {
  height: 50px;
  padding: 0 50px;
}

.projects .row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px;
}

.projects-item {
  width: 100%;
  display: flex;
  justify-content: center;
}

.projects-item-inner {
  width: 70vw;
  min-width: 300px; /* force a minimum width */
  max-width: 600px; /* optional: cap it for bigger screens */
  background-color: var(--bg-black-100);
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
  text-align: center;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.main-content {
  background-color: var(--bg-black-900); /* Default background color */
  transition: background-color 0.3s ease; /* Smooth transition */
}

@media (max-width: 1199px) {
  .aside {
    left: -270px;
  }

  .aside.open {
    left: 0;
  }

  .aside .nav-toggle {
    display: flex;
    left: 20px;
  }

  .aside .nav-toggle.open {
    margin-left: 270px;
  }
  .section {
    left: 0;
  }
  .main-content {
    margin-left: 0;
  }

  .about .about-content .personal-info .info-item p span {
    display: block;
    margin-left: 0;
  }
}

@media (max-width: 911px) {
  .contact .contact-info-item,
  .projects .project-item .service .service-item {
    flex: 0 0 50%;
    max-height: 50%;
  }
  .about .about-content .education,
  .home .home-info {
    flex: 0 0 100%;
    max-height: 100%;
  }
  .home .home-img {
    display: none;
  }
}

@media (max-width: 900px) {
  .contact .contact-info-item {
    flex: 0 0 50%;
    max-width: 50%;
  }
}

@media (max-width: 767px) {
  .home-img::before,
  .home-img::after {
    display: none;
  }
}

@media (max-width: 767px) {
  .home {
    flex-direction: column;
    align-items: center;
    height: auto;
    padding: 40px 20px;
    text-align: center;
  }

  .home .home-info {
    flex: 0 0 100%;
    max-width: 100%;
    margin-bottom: 20px;
  }

  .home .home-img {
    flex: 0 0 auto;
    max-width: 80%;
    display: block;
  }

  .home .home-img img {
    width: 100%;
    height: auto;
  }
}

@media (max-width: 767px) {
  .projects .row {
    flex-direction: column;
    align-items: center;
    padding: 0 10px;
  }

  .projects-item {
    width: 100%;
    display: flex;
    justify-content: center;
    padding: 10px 0;
  }

  .projects-item-inner {
    width: 70vw; /* 🧠 This makes the card take 70% of the screen */
    max-width: 450px; /* Optional: caps width for tablets */
    background-color: var(--bg-black-100);
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
    text-align: center;
    box-sizing: border-box;
  }

  .projects-item-inner img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    object-fit: cover;
  }

  .projects-info h4 {
    font-size: 18px;
    margin: 10px 0 5px;
    color: var(--text-black-900);
  }

  .projects-info p {
    font-size: 14px;
    color: var(--text-black-700);
    margin-bottom: 10px;
  }

  .projects-info .btn {
    width: 100%;
    padding: 10px 0;
    font-size: 16px;
  }

  .skill-percent {
    display: none;
  }

  .about .about-content .personal-info {
    flex-direction: column;
    flex-wrap: wrap;
  }

  .about .about-content .personal-info .info-item {
    max-width: 100%;
    flex: 0 0 100%;
  }

  .about .about-content .personal-info .info-item p {
    white-space: normal; /* let text wrap naturally */
    word-break: break-word; /* prevents long URLs/emails from overflowing */
  }

  .service .service-item {
    flex: 0 0 100%;
    max-width: 100%;
  }

  .section .service-item .service-item-inner {
    text-align: center;
    padding: 25px;
  }
  .contact .contact-info-item {
    flex: 0 0 100%;
    max-width: 100%;
  }

  .contact .contact-info-item p {
    word-break: break-word; /* Prevent long email/URLs from breaking layout */
    text-align: center;
  }

  .contact .contact-info-item h4 {
    text-align: center;
  }

  .contact .contact-info-item .icon {
    display: block;
    margin: 0 auto;
  }
}
