/* ===== MEDIA QUERIES FOR RESPONSIVE DESIGN ===== */

/* ===== EXTRA LARGE SCREENS (1400px+) ===== */
@media screen and (min-width: 1400px) {
  section {
    padding: 6rem 4rem;
  }

  .section-container {
    max-width: 1200px;
  }

  .experience-details-container {
    max-width: 1400px;
  }

  .projects-container {
    max-width: 1400px;
  }
}

/* ===== LARGE SCREENS (1024px - 1400px) ===== */
@media screen and (max-width: 1400px) {
  #desktop-nav {
    display: none;
  }
  
  #hamburger-nav {
    display: flex;
  }

  section {
    padding: 5rem 2.5rem;
  }

  #profile {
    gap: 4rem;
  }

  .section__pic-container img {
    width: 280px;
    height: 280px;
  }

  #profile .title {
    font-size: 2.8rem;
  }

  .section__text__p2 {
    font-size: 1.3rem;
  }
}

/* ===== MEDIUM-LARGE SCREENS (769px - 1024px) ===== */
@media screen and (max-width: 1024px) {
  #desktop-nav {
    padding: 1.2rem 2rem;
  }

  section {
    padding: 5rem 2rem;
  }

  #profile {
    gap: 3rem;
    padding-top: 7rem;
  }

  .section__pic-container img {
    width: 260px;
    height: 260px;
  }

  #profile .title {
    font-size: 2.6rem;
  }

  .title {
    font-size: 2.4rem;
  }

  .section__text__p2 {
    font-size: 1.25rem;
  }

  /* About Section */
  .about-containers {
    gap: 1.2rem;
  }

  .details-container {
    padding: 2rem 1.5rem;
  }

  /* Experience Section */
  .experience-details-container {
    max-width: 900px;
  }

  .experience-details-container .about-containers {
    flex-wrap: wrap;
  }

  .experience-details-container .details-container {
    flex: 1 1 calc(50% - 1rem);
    min-width: 300px;
  }

  .article-container {
    gap: 1.2rem 1rem;
  }

  /* Research Section */
  .research-container {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  /* Projects Section */
  .projects-container {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
  }

  /* Contact Section */
  .contact-container {
    gap: 1.5rem;
  }
}

/* ===== TABLETS & SMALL LAPTOPS (601px - 768px) ===== */
@media screen and (max-width: 768px) {
  #desktop-nav {
    display: none;
  }

  #hamburger-nav {
    display: flex;
  }

  section {
    padding: 4.5rem 1.5rem;
    min-height: auto;
  }

  /* Profile Section */
  #profile {
    flex-direction: column;
    gap: 2.5rem;
    padding-top: 8rem;
    min-height: 90vh;
  }

  .section__pic-container img {
    width: 240px;
    height: 240px;
  }

  #profile .section__text__p1 {
    font-size: 0.9rem;
  }

  #profile .title {
    font-size: 2.4rem;
  }

  .section__text__p2 {
    font-size: 1.15rem;
    text-align: center;
  }

  .btn-container {
    flex-wrap: wrap;
    gap: 0.8rem;
  }

  .btn {
    min-width: 140px;
  }

  /* General Headings */
  .title {
    font-size: 2.2rem;
  }

  .section__text__p1 {
    font-size: 0.85rem;
  }

  /* About Section */
  .about-containers {
    flex-direction: column;
    gap: 1rem;
  }

  .details-container {
    padding: 1.8rem 1.3rem;
  }

  .text-container {
    padding: 1.8rem 1.5rem;
  }

  .section-container {
    max-width: 100%;
  }

  /* Experience Section */
  .experience-details-container {
    width: 100%;
  }

  .experience-details-container .about-containers {
    flex-direction: column;
  }

  .experience-details-container .details-container {
    flex: 1 1 100%;
    max-width: 100%;
  }

  .article-container {
    gap: 1rem 0.8rem;
  }

  article {
    gap: 0.6rem;
  }

  /* Research Section */
  .research-container {
    grid-template-columns: 1fr;
    gap: 1.8rem;
  }

  .research-card {
    padding: 2.2rem 1.8rem;
  }

  .paper-title {
    font-size: 1.15rem;
  }

  .research-links {
    flex-direction: row;
    gap: 0.8rem;
  }

  /* Projects Section */
  .projects-container {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .project-card {
    max-width: 100%;
  }

  /* Contact Section */
  .contact-container {
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
  }

  .contact-card {
    max-width: 400px;
    width: 100%;
  }

  /* Arrow Icons */
  .arrow {
    display: none;
  }
}

/* ===== MOBILE DEVICES (481px - 600px) ===== */
@media screen and (max-width: 600px) {
  section {
    padding: 4rem 1.2rem;
  }

  /* Navigation */
  #hamburger-nav {
    padding: 1rem 1.2rem;
  }

  .menu-links {
    width: 180px;
  }

  /* Profile Section */
  #profile {
    padding-top: 7rem;
    gap: 2rem;
  }

  .section__pic-container img {
    width: 220px;
    height: 220px;
  }

  #profile .title {
    font-size: 2.1rem;
  }

  .section__text__p2 {
    font-size: 1.05rem;
  }

  /* Headings */
  .title {
    font-size: 2rem;
  }

  /* About Section */
  .details-container {
    padding: 1.6rem 1.2rem;
  }

  .details-container h3 {
    font-size: 1rem;
  }

  .details-container p {
    font-size: 0.88rem;
  }

  .text-container {
    padding: 1.6rem 1.3rem;
    font-size: 0.92rem;
    line-height: 1.7;
  }

  /* Experience Section */
  .experience-sub-title {
    font-size: 1.15rem;
  }

  article h3 {
    font-size: 0.9rem;
  }

  article p {
    font-size: 0.8rem;
  }

  /* Research Section */
  .research-card {
    padding: 2rem 1.5rem;
  }

  .paper-title {
    font-size: 1.05rem;
  }

  .venue-info {
    font-size: 0.8rem;
  }

  .research-description {
    font-size: 0.88rem;
  }

  /* Projects Section */
  .projects-container {
    gap: 1.5rem;
  }

  .project-title {
    font-size: 1.15rem;
  }

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

  .tech-badge {
    font-size: 0.7rem;
    padding: 0.3rem 0.65rem;
  }

  .btn-project,
  .btn-project-outline {
    font-size: 0.8rem;
    padding: 0.65rem 1.2rem;
  }

  /* Contact Section */
  .contact-subtitle {
    font-size: 0.92rem;
  }

  .contact-card {
    max-width: 100%;
    padding: 2rem 1.5rem;
  }

  .contact-icon-wrapper {
    width: 60px;
    height: 60px;
  }

  .contact-icon {
    width: 28px;
    height: 28px;
  }

  .contact-card h3 {
    font-size: 1rem;
  }

  .contact-card a {
    font-size: 0.88rem;
  }
}

/* ===== SMALL MOBILE DEVICES (320px - 480px) ===== */
@media screen and (max-width: 480px) {
  section {
    padding: 3.5rem 1rem;
  }

  /* Navigation */
  .logo {
    font-size: 1.3rem;
  }

  #hamburger-nav {
    padding: 0.9rem 1rem;
  }

  .menu-links {
    width: 160px;
  }

  .menu-links li a {
    padding: 0.65rem 1rem;
    font-size: 0.88rem;
  }

  /* Profile Section */
  #profile {
    padding-top: 6.5rem;
    gap: 1.8rem;
  }

  .section__pic-container img {
    width: 200px;
    height: 200px;
  }

  #profile .section__text__p1 {
    font-size: 0.85rem;
  }

  #profile .title {
    font-size: 1.9rem;
    line-height: 1.2;
  }

  .section__text__p2 {
    font-size: 1rem;
    line-height: 1.4;
  }

  .btn-container {
    flex-direction: column;
    width: 100%;
    gap: 0.7rem;
  }

  .btn {
    width: 100%;
    padding: 0.75rem 1.5rem;
    font-size: 0.85rem;
  }

  #socials-container .icon {
    width: 36px;
    height: 36px;
  }

  /* General Headings */
  .title {
    font-size: 1.8rem;
  }

  .section__text__p1 {
    font-size: 0.8rem;
    letter-spacing: 0.18em;
  }

  /* About Section */
  .details-container {
    padding: 1.5rem 1rem;
  }

  .details-container .icon {
    width: 28px;
    height: 28px;
  }

  .details-container h3 {
    font-size: 0.95rem;
  }

  .details-container p {
    font-size: 0.85rem;
  }

  .text-container {
    padding: 1.5rem 1.2rem;
    font-size: 0.9rem;
    line-height: 1.65;
  }

  /* Experience Section */
  .experience-sub-title {
    font-size: 1.05rem;
    margin-bottom: 1rem;
  }

  .article-container {
    gap: 0.9rem 0.7rem;
  }

  article {
    gap: 0.5rem;
  }

  article h3 {
    font-size: 0.85rem;
  }

  article p {
    font-size: 0.75rem;
  }

  .icon {
    width: 22px;
    height: 22px;
  }

  /* Research Section */
  .research-card {
    padding: 1.8rem 1.3rem;
  }

  .paper-title {
    font-size: 1rem;
    line-height: 1.3;
  }

  .authors {
    font-size: 0.8rem;
  }

  .venue-info {
    font-size: 0.75rem;
  }

  .research-description {
    font-size: 0.85rem;
    line-height: 1.6;
  }

  .research-links {
    gap: 0.6rem;
    flex-wrap: wrap;
  }

  .research-link {
    font-size: 0.8rem;
    padding: 0.5rem 1rem;
  }

  /* Projects Section */
  .projects-container {
    gap: 1.3rem;
  }

  .project-card {
    border-radius: 1rem;
  }

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

  .project-content {
    padding: 1.5rem 1.3rem 1.7rem;
  }

  .project-title {
    font-size: 1.05rem;
    line-height: 1.25;
  }

  .project-description {
    font-size: 0.82rem;
    line-height: 1.65;
  }

  .tech-badge {
    font-size: 0.68rem;
    padding: 0.28rem 0.6rem;
  }

  .project-card .btn-container {
    flex-direction: column;
    gap: 0.6rem;
  }

  .btn-project,
  .btn-project-outline {
    width: 100%;
    font-size: 0.78rem;
    padding: 0.6rem 1rem;
  }

  /* Contact Section */
  #contact {
    min-height: 70vh;
  }

  .contact-subtitle {
    font-size: 0.88rem;
    margin-bottom: 2rem;
  }

  .contact-card {
    padding: 1.8rem 1.3rem;
  }

  .contact-icon-wrapper {
    width: 56px;
    height: 56px;
    margin-bottom: 1rem;
  }

  .contact-icon {
    width: 26px;
    height: 26px;
  }

  .contact-card h3 {
    font-size: 0.95rem;
  }

  .contact-card a {
    font-size: 0.85rem;
  }

  /* Footer */
  footer {
    padding: 1.5rem 1rem;
  }

  footer p {
    font-size: 0.82rem;
  }
}

/* ===== EXTRA SMALL DEVICES (max 360px) ===== */
@media screen and (max-width: 360px) {
  section {
    padding: 3rem 0.8rem;
  }

  .logo {
    font-size: 1.2rem;
  }

  #profile {
    padding-top: 6rem;
  }

  .section__pic-container img {
    width: 180px;
    height: 180px;
  }

  #profile .title {
    font-size: 1.7rem;
  }

  .section__text__p2 {
    font-size: 0.95rem;
  }

  .title {
    font-size: 1.65rem;
  }

  .btn {
    padding: 0.7rem 1.3rem;
    font-size: 0.82rem;
  }

  .details-container {
    padding: 1.3rem 0.9rem;
  }

  .text-container {
    padding: 1.3rem 1rem;
    font-size: 0.88rem;
  }

  .experience-sub-title {
    font-size: 1rem;
  }

  .research-card {
    padding: 1.6rem 1.1rem;
  }

  .paper-title {
    font-size: 0.95rem;
  }

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

  .project-content {
    padding: 1.3rem 1.1rem 1.5rem;
  }

  .project-title {
    font-size: 1rem;
  }

  .contact-card {
    padding: 1.6rem 1.1rem;
  }
}

/* ===== LANDSCAPE ORIENTATION ADJUSTMENTS ===== */
@media screen and (max-height: 600px) and (orientation: landscape) {
  section {
    min-height: auto;
    padding: 3rem 2rem;
  }

  #profile {
    padding-top: 5rem;
    min-height: auto;
  }

  .section__pic-container img {
    width: 180px;
    height: 180px;
  }
}

/* ===== PRINT STYLES ===== */
@media print {
  #desktop-nav,
  #hamburger-nav,
  .arrow,
  footer {
    display: none;
  }

  section {
    page-break-inside: avoid;
    padding: 1rem;
  }

  .btn-container,
  #socials-container {
    display: none;
  }

  body {
    background: white;
  }
}