@media screen and (max-width: 1400px) {
    #profile {
      height: 83vh;
      margin-bottom: 6rem;
    }
    .about-containers {
      flex-wrap: wrap;
    }
    #contact,
    #projects,
    #certifications {
      height: fit-content;
    }
  }
  
  @media screen and (max-width: 1200px) {
    #desktop-nav {
      display: none;
    }
    #hamburger-nav {
      display: flex;
    }
    #experience,
    .experience-details-container {
      margin-top: 2rem;
    }
    #profile,
    .section-container {
      display: block;
    }
    .arrow {
      display: none;
    }
    section,
    .section-container {
      height: fit-content;
    }
    section {
      margin: 0 5%;
    }
    .section__pic-container {
      width: 275px;
      height: 275px;
      margin: 0 auto 2rem;
    }
    .about-containers {
      margin-top: 0;
    }
  }

  @media screen and (max-width: 900px) {
    /* Tablet optimizations for projects */
    .project-img {
      max-height: 250px;
    }

    .project-img-container {
      height: 220px;
    }

    .details-container {
      min-height: auto;
    }

    .tech-badge {
      font-size: 0.8rem;
      padding: 0.35rem 0.7rem;
    }

    /* Timeline adjustments for tablet */
    .timeline-container {
      padding: 0 1rem;
    }

    .timeline-content {
      width: 42%;
      padding: 1.2rem;
    }

    .timeline-title {
      font-size: 1.1rem;
    }

    .timeline-description {
      font-size: 0.9rem;
    }
  }
  
  @media screen and (max-width: 600px) {
    #contact,
    footer {
      height: 40vh;
    }

    /* Project improvements for mobile */
    .project-img {
      max-height: 200px;
      border-radius: 1rem;
    }

    .project-img-container {
      height: 200px;
    }

    .color-container {
      padding-bottom: 1.5rem;
    }

    .project-title {
      font-size: 1.25rem;
      margin: 0.5rem;
    }

    .tech-stack {
      gap: 0.4rem;
      margin: 0.75rem 0;
    }

    .tech-badge {
      font-size: 0.75rem;
      padding: 0.3rem 0.6rem;
    }

    .tech-badge i {
      font-size: 1rem;
    }

    /* Mobile timeline - switch to single column */
    .timeline-container {
      padding: 0 1rem;
    }

    .timeline-container::before {
      left: 20px;
    }

    .timeline-item {
      justify-content: flex-start;
    }

    .timeline-dot {
      left: 20px;
    }

    .timeline-item:hover .timeline-dot {
      transform: translate(-50%, 0) scale(1.2);
    }

    .timeline-content {
      width: calc(100% - 60px);
      margin-left: 60px !important;
      text-align: left !important;
    }

    .timeline-item:nth-child(odd) .timeline-content,
    .timeline-item:nth-child(even) .timeline-content {
      margin-left: 60px;
      margin-right: 0;
      text-align: left;
    }

    .timeline-title {
      font-size: 1.1rem;
    }

    .timeline-company {
      font-size: 0.9rem;
    }

    .timeline-description {
      font-size: 0.85rem;
    }

    .timeline-date {
      font-size: 0.8rem;
    }

    /* Tech stack mobile adjustments */
    .tech-stack-grid-container {
      padding: 0 1rem;
    }

    .tech-grid {
      grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
      gap: 1rem;
    }

    .tech-item {
      min-height: 110px;
      padding: 1rem 0.5rem;
    }

    .tech-logo {
      font-size: 2.5rem;
    }

    .tech-name {
      font-size: 0.8rem;
    }

    .tech-category-title {
      font-size: 1.2rem;
    }

    .certification-header {
      flex-direction: column;
      gap: 0.5rem;
    }
    .certification-container {
      padding: 1.5rem 1rem;
      min-height: auto;
    }
    .certification-description {
      font-size: 0.9rem;
    }
    #profile {
      height: 83vh;
      margin-bottom: 0;
    }
    article {
      font-size: 1rem;
    }
    footer nav {
      height: fit-content;
      margin-bottom: 2rem;
    }
    .about-containers,
    .contact-info-upper-container,
    .btn-container {
      flex-wrap: wrap;
    }
    .contact-info-container {
      margin: 0;
    }
    .contact-info-container p,
    .nav-links li a {
      font-size: 1rem;
    }
    .experience-sub-title {
      font-size: 1.25rem;
    }
    .logo {
      font-size: 1.5rem;
    }
    .nav-links {
      flex-direction: column;
      gap: 0.5rem;
      text-align: center;
    }
    .section__pic-container {
      width: auto;
      height: 46vw;
      justify-content: center;
    }
    .section__text__p2 {
      font-size: 1.25rem;
    }
    .title {
      font-size: 2rem;
    }
    .text-container {
      text-align: justify;
    }
  }
  