/* ================= GLOBAL SAFETY ================= */

html, body {
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
}

/* Disable custom cursor on touch screens and mobile devices */
@media (pointer: coarse), (max-width: 768px) {
  body {
    cursor: auto !important;
  }
  .custom-cursor {
    display: none !important;
  }
}


/* ================================================= */
/* ================== MOBILE ≤ 500px =============== */
/* ================================================= */

@media (max-width: 500px) {

  /* HEADER */
  header {
    padding: 10px 15px;
  }

  .logo a {
    font-size: 14px;
  }

  a.hire {
    font-size: 14px;
  }

  /* HERO */
  .hero-img {
    display: none;
  }

  .heading1 h1 {
    font-size: 2.2rem;
    flex-direction: column;
  }

  .heading2 {
    align-items: center;
  }

  .social-card {
    width: 100%;
  }

  /* ABOUT */
  .about_card {
    flex-direction: column;
    text-align: center;
    padding: 25px;
    gap: 30px;
  }

  .about_img {
    display: none;
  }

  /* SKILLS */

  section#skills .container {
    padding-left: 15px;
    padding-right: 15px;
  }
  
  .skls_card {
    padding: 20px;
    border-radius: 20px;
    overflow: hidden;
  }

  .num1,
  .num {
    flex-direction: column;
    gap: 15px;
  }

  .apps {
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
  }

  .apps img {
    width: 50px !important;
  }

  h1.title {
    font-size: 20px;
  }

  .nmbr {
    font-size: 28px;
  }

  /* CONTACT */
  .form-grid {
    grid-template-columns: 1fr;
  }

  .contact-card {
    padding: 20px;
  }

  .submit-btn {
    width: 100%;
  }

  /* FOOTER */
  .footer-content,
  .f-right-content {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 25px;
  }

  p.copyright {
    width: 100%;
    font-size: 13px;
  }

  .slick-prev,
  .slick-next {
    display: none !important;
  }

}

/* ================================================= */
/* ========= TABLET PORTRAIT 501px – 768px ======== */
/* ================================================= */

@media (min-width: 501px) and (max-width: 768px) {

  .hero-img {
    padding: 0;
    justify-content: center;
  }

  .profile {
    max-width: 280px;
  }

  .heading1 h1 {
    font-size: 3rem;
  }

  .about_card {
    flex-direction: column;
    text-align: center;
    gap: 40px;
  }

  .about_img img {
    max-width: 250px;
  }

  .num1,
  .num {
    gap: 40px;
     flex-direction: column;
    gap: 10px;
  }

  .apps {
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
  }

  .apps img {
    width: 65px !important;
  }

  .skls_card {
    overflow: hidden;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .footer-content,
  .f-right-content {
    flex-wrap: wrap;
    gap: 40px;
  }

  .slick-prev,
  .slick-next {
    display: none !important;
  }

}

/* ================================================= */
/* ========= TABLET LANDSCAPE 769px – 1024px ====== */
/* ================================================= */

@media (min-width: 769px) and (max-width: 1024px) {

  .profile {
    max-width: 320px;
  }

  .hero-img {
    padding: 0;
  }

  .heading1 h1 {
    font-size: 3.5rem;
  }

  .about_card {
    gap: 60px;
    padding: 40px;
  }

  .apps {
    gap: 25px;
  }

  .apps img {
    width: 75px !important;
  }

  .skls_card {
    padding: 20px !important;
    overflow: hidden;
  }

  .footer-content {
    gap: 60px;
  }

}

/* ================================================= */
/* ========= MOBILE HAMBURGER MENU (≤ 768px) ======= */
/* ================================================= */

@media (max-width: 768px) {
  .hamburger {
      display: flex;
      margin-left: auto;
      margin-right: 15px;
  }

  /* Hide default hire button on mobile header to avoid overlap */
  .navbar a.hire {
      display: none;
  }

  #nav-menu {
      position: absolute;
      top: 100%;
      right: 0;
      width: 250px;
      height: 100vh;
      background: rgba(11, 7, 5, 0.96);
      backdrop-filter: blur(10px);
      display: flex;
      flex-direction: column;
      align-items: center;
      padding-top: 50px;
      transform: translateX(100%);
      transition: transform 0.4s ease-in-out;
      border-left: 1px solid #7c5825;
      box-shadow: -5px 0 15px rgba(0,0,0,0.5);
  }

  header nav ul {
      flex-direction: column;
      align-items: center;
      gap: 30px;
      font-size: 18px;
  }

  /* Slide menu in when toggle is checked */
  .menu-toggle:checked ~ #nav-menu {
      transform: translateX(0);
  }

  /* Beautiful X animation for the 3 line slider */
  .menu-toggle:checked ~ .hamburger span:nth-child(1) {
      transform: translateY(8px) rotate(45deg);
  }
  .menu-toggle:checked ~ .hamburger span:nth-child(2) {
      opacity: 0;
  }
  .menu-toggle:checked ~ .hamburger span:nth-child(3) {
      transform: translateY(-8px) rotate(-45deg);
  }
}
