/* @import url("https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap"); */
@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@400;700&display=swap');

:root {
  --primary-color: #0db75f;
  --primary-color-dark: #0c9a51;
  --text-dark: #030712;
  --text-light: #6b7280;
  --extra-light: #d1d5db;
  --white: #ffffff;
  --max-width: 1200px;
}

* {
  padding: 0;
  margin: 0;
  box-sizing: border-box;
}

.section__container {
  max-width: var(--max-width);
  margin: auto;
  padding: 5rem 1rem;
}

.section__subheader {
  max-width: fit-content;
  padding: 8px;
  margin-bottom: 0.5rem;
  font-size: 1rem;
  font-weight: 600;
  color: var(--primary-color);
  border: 1px solid var(--primary-color);
  border-radius: 100%;
}

.section__header {
  font-size: 2.5rem;
  font-weight: 600;
  line-height: 3.25rem;
  color: var(--text-dark);
}

.section__header span {
  color: var(--primary-color);
}

.section__description {
  color: var(--text-light);
  line-height: 1.5rem;
}

.btn {
  padding: calc(0.75rem + 2px) 1.5rem;
  outline: none;
  border: none;
  font-size: 1rem;
  color: var(--white);
  background-color: var(--primary-color);
  border-radius: 10px;
  transition: 0.3s;
  cursor: pointer;
}

.btn:hover {
  background-color: var(--primary-color-dark);
}

img {
  display: flex;
  width: 100%;
}

a {
  text-decoration: none;
  transition: 0.3s;
}

ul {
  list-style: none;
}

html,
body {
  scroll-behavior: smooth;
}

body {
  font-family: "Nunito", sans-serif;
}

nav {
  position: fixed;
  isolation: isolate;
  width: 100%;
  z-index: 9;
}

.nav__header {
  padding: 1rem;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: var(--primary-color);
}

.nav__logo a span {
  padding: 2px 10px;
  color: var(--primary-color);
  background-color: var(--white);
  border-radius: 5px;
}

.nav__menu__btn {
  font-size: 1.5rem;
  color: var(--white);
  cursor: pointer;
}

.nav__links {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 2rem;
  background-color: var(--primary-color);
  transition: transform 0.5s;
  z-index: -1;
}

.nav__links.open {
  transform: translateY(100%);
}

.nav__links a {
  font-weight: 500;
  color: var(--white);
}

.nav__btn {
  display: none;
}

/* ////////////////////////////// */

.header__container {
  display: grid;
  gap: 4rem 2rem;
  overflow: hidden;
}

.header__image {
  position: relative;
  isolation: isolate;
}

.header__image img {
  max-width: 350px;
  margin-inline: auto;
}

.header__image::before,
.header__image::after {
  position: absolute;
  content: "";
  height: 80%;
  width: 100%;
  max-width: 400px;
}

.header__image::before {
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  background-color: var(--primary-color);
  z-index: -2;
}

.header__image::after {
  bottom: -3rem;
  left: 50%;
  transform: translateX(calc(-50% - 3rem));
  border: 5px solid var(--text-dark);
  opacity: 0.75;
  border-radius: 5px;
  z-index: -1;
}

.header__content .section__subheader {
  margin-inline: auto;
}

.header__content h1 {
  margin-bottom: 2rem;
  font-size: 4rem;
  font-weight: 600;
  line-height: 4.25rem;
  color: var(--text-dark);
  text-align: center;
}

.header__content h1 span {
  color: var(--primary-color);
}

.header__content .section__description {
  margin-bottom: 2rem;
  text-align: center;
}

.header__btns {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2rem;
}

.header__btns a {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 1rem;
  font-weight: 500;
  color: white;
}

.header__btns a span {
  font-size: 1.5rem;
  color: var(--primary-color);
}

.header__btns a:hover {
  color: var(--primary-color);
}

/* /////////////////////////////////// */

.about__container {
  padding: 80px 40vw;
  background-color: #f9f9f9;
  text-align: left;
  border-radius: 16px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}

.about__content {
  max-width: 1100px;
  margin: 0 auto;
  text-align: left;
}
.section__container {
  padding: 80px 0;
  text-align: center;
  margin-bottom: 2%;
}

.about__title {
  font-size: 1.8rem;
  color: #333;
  margin-bottom: 1rem;
  /* padding-left: 99px; */
  text-align: left;
}

.about__description {
  font-size: 1rem;
  color: #555;
  line-height: 1.8;
  margin-bottom: 2rem;
  text-align: left;
}

.about__experience {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}

.experience__block h3 {
  font-size: 1.4rem;
  color: #0db75f;
  margin-bottom: 0.5rem;
}

.experience__block p {
  margin-bottom: 1rem;
  color: #444;
  line-height: 1.7;
}

.about__accordion {
  margin-top: 2rem;
  border-top: 1px solid #e5e5e5;
}

.accordion__item {
  border-bottom: 1px solid #e5e5e5;
}

.accordion__header {
  width: 100%;
  background: none;
  border: none;
  outline: none;
  text-align: left;
  font-size: 1.2rem;
  font-weight: 600;
  padding: 1rem 0;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #0db75f;
  transition: color 0.3s ease;
}

.accordion__header:hover {
  color: #0a8a4b;
}

.accordion__content {

  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease;
  text-align: left; /* <-- add this */
}

.accordion__content p {
  margin-bottom: 1rem;
  color: #444;
  line-height: 1.7;
}

.accordion__item.active .accordion__content {
  max-height: 600px; /* enough space for full content */
}

.accordion__item .arrow {
  font-size: 1.4rem;
  transition: transform 0.3s ease;
}

.accordion__item.active .arrow {
  transform: rotate(45deg);
}



/* ////////////////////////////////////// */

/* ===== Skills Section ===== */
.skill__content {
  margin-bottom: 40px; 
}

.section__container {
  padding: 60px 2%;
  text-align: center;
  margin-bottom: 2%;
}

.skill__container {
  background: #f9f9f9;
  border-radius: 16px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.05);
}

.skill__content .section__subheader {
    font-size: 1.8rem;
    font-weight: 600;
    margin-bottom: 40px;
    color: #333;
    margin-left: 2%;
}

/* === Skills Section Styling === */

#skill {
  padding: 60px 0;
  text-align: center;
  background: #f9f9f9;
}

.section__subheader {
  font-size: 1.8rem;
  font-weight: 600;
  margin-bottom: 40px;
  color: #333;
}

/* Container for all skills */
.skills__grid {
  display: flex;
  flex-wrap: wrap;             
  justify-content: center;      
  align-items: center;           
  gap: 25px;                     
  max-width: 1100px;
  margin: 0 auto;
}

/* Individual skill cards */
.skill__card {
  flex: 1 1 180px;               
  max-width: 200px;              
  background: #fff;
  border-radius: 12px;
  padding: 25px 15px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: all 0.3s ease;
}

.skill__card:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.15);
}

/* Skill icons */
.skill__icon {
  width: 60px;
  height: 60px;
  object-fit: contain;
  margin-bottom: 10px;
}

/* Text under icons */
.skill__card p {
  font-size: 1rem;
  font-weight: 500;
  font-weight: bold;
  color: #333;
}


/* //////////////////////////////////////////// */

.portfolio__container {
  display: flex;
  flex-direction: column;   
  gap: 2rem;
  padding: 40px 10px;       
  max-width: 1100px;        
  margin: 0 auto;            
}

.portfolio__content {
  width: 100%;
}

.portfolio__content .section__header {
  margin-bottom: 1rem;
}

.portfolio__content .section__description {
  margin-bottom: 1rem;
}

/* Dropdown styling */
.project-dropdown {
    display: block;
    margin-top: 1rem;
    width: 100%;
}

.project-dropdown .btn {
    cursor: pointer;
}

.dropdown-content {
    display: none; 
    background-color: #f9f9f9;
    padding: 1rem;
    margin-top: 0.5rem;
    border-radius: 5px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    animation: fadeIn 0.3s ease-in-out;
}

.dropdown-content p, 
.dropdown-content ul {
    margin: 0;
    font-size: 0.9rem;
}

.dropdown-content ul {
    padding-left: 1.2rem;
}

/* Fade in animation */
@keyframes fadeIn {
    from {opacity: 0;}
    to {opacity: 1;}
}

/* Image wrapper & scroll */
.portfolio__image__wrapper {
  overflow-x: auto;
  width: 100%;
  padding-bottom: 1rem;
}

.portfolio__image {
  display: flex;
  gap: 1rem;
  width: max-content;
  animation: scroll 45s linear infinite;
}

.portfolio__image img {
  height: 90vh;
  max-width: 300px;
  box-shadow: 5px 5px 20px rgba(0,0,0,0.05);
}

/* Scroll animation */
@keyframes scroll {
  to {
    transform: translateX(calc(-50% - 0.5rem));
  }
}


/* //////////////////////////////// */

.contact__container {
  text-align: left;
  /* background: #f9f9f9; */
  max-width: 1100px;
  margin: 0 auto;
  border-radius: 16px;
  max-width: 1200px; 
  padding: 2rem 1rem;
}

.contact__info {
  margin-top: 2rem;
  display: flex;
  flex-direction: column;
  align-items: flex-start;          
  gap: 1.2rem;
  padding-left: 1rem;               
}

.contact__item {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  font-size: 1rem;
  color: #333;
  font-weight: bold;                
}

.contact__item i {
  font-size: 1.2rem;
  color: #0940d8;                   
  width: 25px;                     
  text-align: center;              
}

.contact__item a {
  color: #333;
  text-decoration: none;
  transition: color 0.3s;
  font-weight: bold;                
}

.contact__item a:hover {
  color: #007bff;
}

/* Layout for two columns */
.contact__content {
  display: flex;
  align-items: flex-start;
  gap: 3rem;
  margin-top: 2rem;
}

/* Left column (existing) */
.contact__info {
  flex: 0 0 35%;
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
  padding-left: 0;
}

/* Right column (form) */
.contact__form {
  flex: 0 0 60%;
  background: #fff;
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.form__group {
  display: flex;
  flex-direction: column;
  margin-bottom: 1.2rem;
}

.form__group label {
  font-weight: 600;
  color: #333;
  margin-bottom: 0.5rem;
}

.form__group input,
.form__group textarea {
  padding: 0.8rem;
  border: 1px solid #ccc;
  border-radius: 8px;
  font-size: 1rem;
  transition: border-color 0.3s ease;
}

.form__group input:focus,
.form__group textarea:focus {
  border-color: #007bff;
  outline: none;
}

.form__btn {
  background-color: var(--primary-color);
  color: #fff;
  font-weight: 600;
  padding: 0.9rem 1.5rem;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.3s ease;
}

.form__btn:hover {
  background-color: #00b33c;
}

/* Mobile responsive */
@media (max-width: 768px) {
  .contact__content {
    flex-direction: column;
  }

  .contact__info,
  .contact__form {
    flex: 1 1 100%;
    width: 100%;
  }
}


/* //////////////////////////// */

.footer__container {
  padding-block: 2rem;
  display: flex;
  align-items: center;
  gap: 2rem;
  flex-direction: column;
  border-top: 1px solid var(--extra-light);
  padding-bottom: 0;
}

.footer__container p {
  color: var(--text-light);
  text-align: center;
  line-height: 1.5rem;
}

.footer__socials {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

.footer__socials a {
  padding: 6px 8px;
  font-size: 1.125rem;
  color: var(--white);
  background-color: var(--primary-color);
  border-radius: 100%;
}

.footer__socials a:hover {
  background-color: var(--primary-color-dark);
}

.custom-alert {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.95);
  background-color: #0db75f; /* success color */
  color: #fff;
  padding: 1.2rem 2rem;
  border-radius: 10px;
  font-size: 1rem;
  font-weight: 600;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease, transform 0.4s ease;
  z-index: 9999;
  text-align: center;
  min-width: 250px;
}

/* When visible */
.custom-alert.show {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
  pointer-events: auto;
}

/* Error version */
.custom-alert.error {
  background-color: #e63946;
}


@media (width > 540px) {
  .stats__container {
    flex-direction: row;
    align-items: center;
    justify-content: space-evenly;
  }

  .stats__card {
    align-items: flex-start;
    flex-direction: column;
    gap: 0;
  }

  .stats__divider {
    height: 75px;
    width: 2px;
    background-color: var(--primary-color);
  }

  .skill__grid {
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(4, 1fr);
  }

  .skill__card:nth-child(1) {
    grid-area: 1/1/3/2;
  }

  .skill__card:nth-child(2) {
    grid-area: 2/2/4/3;
  }

  .skill__card:nth-child(3) {
    grid-area: 3/1/5/2;
  }

  .contact__container form {
    grid-template-columns: repeat(2, 1fr);
  }

  .contact__container textarea {
    grid-column: 1/3;
  }

  .contact__container .btn {
    grid-column: 2/3;
    margin-inline-end: unset;
  }
}

@media (width > 768px) {
  nav {
    position: static;
    padding: 2rem 1rem 1rem;
    max-width: var(--max-width);
    margin-inline: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
  }

  .nav__header {
    flex: 1;
    padding: 0;
    background: transparent;
  }

  .nav__logo a {
    font-size: 1.5rem;
    color: var(--primary-color);
  }

  .nav__logo a span {
    padding: 4px 14px;
    color: var(--white);
    background-color: var(--primary-color);
  }

  .nav__menu__btn {
    display: none;
  }

  .nav__links {
    position: static;
    padding: 0;
    max-width: fit-content;
    flex-direction: row;
    background-color: transparent;
    transform: none;
  }

  .nav__links a {
    color: var(--text-dark);
    font-weight: bold;
  }

  .nav__links a:hover {
    color: var(--primary-color);
  }

  .nav__links li:last-child {
    display: none;
  }

  .nav__btn {
    flex: 1;
    display: flex;
    justify-content: flex-end;
  }

  .nav__btn a {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-dark);
    white-space: nowrap;
    border: 2px solid var(--primary-color);
    border-radius: 10px;
  }

  .nav__btn a:hover {
    color: var(--white);
    background-color: var(--primary-color);
  }

  .header__container {
    grid-template-columns: repeat(2, 1fr);
    align-items: center;
  }

  .header__content .section__subheader {
    margin-inline-start: unset;
  }

  .header__content :is(h1, .section__description) {
    text-align: left;
  }

  .header__btns {
    justify-content: flex-start;
  }

  .header__image {
    grid-area: 1/2/2/3;
  }

  .skill__container {
    grid-template-columns: repeat(2, 1fr);
    align-items: center;
  }

  .portfolio__container {
    grid-template-columns:
      minmax(0, 1fr)
      repeat(3, minmax(0, calc(var(--max-width) / 3)))
      minmax(0, 1fr);
  }

  .portfolio__content {
    grid-column: 2/3;
  }

  .portfolio__image__wrapper {
    grid-column: 3/6;
  }

  .footer__container {
    flex-direction: row;
    justify-content: space-between;
  }
}