/* General Styles */
body {
  font-family: "Courier New", Courier, monospace;
  margin: 0;
  padding: 0;
  background: radial-gradient(#1e1e2f 25%, black);
  color: #c5c6c7;
  user-select: none;
  cursor: url(https://cur.cursors-4u.net/cursors/cur-6/cur518.cur), auto !important;
}

html {
  scroll-behavior: smooth;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 12px;
}

::-webkit-scrollbar-track {
  background: #1e1e2f;
  border-radius: 6px;
}

::-webkit-scrollbar-thumb {
  background: #bf00ff;
  border-radius: 6px;
  border: 2px solid #1e1e2f;
}

::-webkit-scrollbar-thumb:hover {
  background: #8a2be2;
}

/* Firefox Scrollbar */
* {
  scrollbar-width: thin;
  scrollbar-color: #bf00ff #1e1e2f;
}

a {
  color: #bf00ff;
  text-decoration: none;
  display: flex;
  align-items: center;
  transition: all 0.3s ease;
}

a:hover {
  text-decoration: underline;
}

a img {
  width: 20px;
  height: 20px;
  margin-right: 10px;
}

.project a {
  transition: all 0.3s ease;
}

.header {
  background: url("https://i.ibb.co/PZ1fq6bz/banner.gif") no-repeat center
    center;
  background-size: cover;
  padding: 20px;
  border-bottom: 2px solid #bf00ff;
  display: grid;
  grid-template-columns: 2fr 1fr 2fr; /* Reduce side columns, keeping center more dominant */
  align-items: center;
  font-family: "Orbitron", sans-serif;
}

.header h1 {
  text-align: center;
  margin: 0;
  color: #4169e1;
  font-size: 2rem;
}

.profile-picture {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  border: 4px solid #bf00ff;
  margin: 0 15px;
  justify-self: center;
}

.header h1:first-of-type {
  justify-self: end; /* Moves text closer to center */
}

.header h1:last-of-type {
  justify-self: start; /* Moves text closer to center */
}

/* Navigation */
.nav {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  background-color: #0b0c10;
  padding: 10px;
  border-top: 2px solid #bf00ff;
}

.nav a {
  margin: 10px;
  color: #c5c6c7;
  font-weight: bold;
}

.nav a:hover {
  color: #bf00ff;
  text-decoration: none;
}

.nav a i {
  margin-right: 8px;
  font-size: 18px;
}

/* Sections */
section {
  max-width: 800px;
  margin: 20px auto;
  padding: 20px;
  background-color: #282a36;
  border-radius: 8px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

section h2 {
  color: #bf00ff;
  border-bottom: 1px solid #c5c6c7;
  padding-bottom: 5px;
  font-size: 1.8rem;
}

section ul {
  list-style: none;
  padding: 0;
}

section li {
  margin: 10px 0;
  line-height: 1.6;
}

/* Links */
.links ul {
  list-style: none;
  padding: 0;
}

.links li {
  margin: 10px 0;
}

/* Projects */
.project {
  margin-bottom: 20px;
}

/* Videos Section */
.videos .video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
}

.videos iframe {
  width: 100%;
  height: 200px;
  border: none;
  border-radius: 8px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

/* Footer */
.footer {
  text-align: center;
  padding: 10px;
  background: url("https://i.ibb.co/PZ1fq6bz/banner.gif");
  color: #bf00ff;
}

.footer p {
  margin: 0;
}

/* Section Divider Styling */
.section-divider {
  margin: 30px 0;
  padding: 20px;
  background-color: #1e1e2f;
  border-radius: 8px;
}

/* Code Effect */
.code-effect {
  font-family: "Courier New", Courier, monospace;
  background-color: black;
  padding: 10px;
  color: #c5c6c7;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  overflow-x: auto;
}

/* Responsive Design */
@media (max-width: 768px) {
  .header h1 {
    font-size: 1.5rem;
  }

  .profile-picture {
    width: 100px;
    height: 100px;
  }

  .nav {
    flex-direction: column;
    align-items: center;
  }

  section {
    padding: 15px;
  }

  .footer {
    padding: 15px;
  }
}

@media (max-width: 480px) {
  .header h1 {
    font-size: 1.2rem;
  }

  .profile-picture {
    width: 80px;
    height: 80px;
  }

  .nav a {
    font-size: 0.9rem;
    margin: 5px 0;
  }

  .videos iframe {
    height: 150px;
  }

  section h2 {
    font-size: 1.5rem;
  }
}

.vulnerabilities ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.vulnerabilities li {
  display: flex;
  align-items: center;
  margin: 10px 0;
}

.vulnerabilities img {
  margin-right: 10px;
  filter: invert(0);
}

.vulnerabilities a {
  display: inline-block;
  color: white;
  text-decoration: none;
}

.vulnerabilities a:hover {
  text-decoration: underline;
}

/* Projects Section */
.projects {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  padding: 20px;
}

.project {
  background-color: #1e1e2f;
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.project:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.4);
}

.project h4 {
  color: #bf00ff;
  margin-bottom: 10px;
  font-size: 1.2rem;
}

.project p {
  color: #c5c6c7;
  margin-bottom: 15px;
  font-size: 0.9rem;
}

.project a {
  display: inline-block;
  background-color: #bf00ff;
  color: white;
  padding: 8px 16px;
  border-radius: 4px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease;
}

.project a:hover {
  background-color: #8a2be2;
}

/* GitHub-like Project Cards */
.github-card {
  background-color: #1e1e2f;
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.github-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.4);
}

.github-card-header {
  display: flex;
  align-items: center;
  margin-bottom: 15px;
}

.github-card-header i {
  font-size: 24px;
  color: white;
  margin-right: 10px;
}

.github-card-header h4 {
  color: white;
  margin: 0;
  font-size: 1.2rem;
}

.github-card p {
  color: #c5c6c7;
  margin-bottom: 15px;
  font-size: 0.9rem;
}

.github-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  /* Add gap between buttons and tags */
}

.github-card-footer a {
  display: inline-block;
  background-color: grey;
  color: white;
  padding: 8px 16px;
  border-radius: 4px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease;
  font-size: 0.9rem;
  /* Fixed font size for buttons */
  min-width: 120px;
  /* Fixed width for buttons */
  text-align: center;
  /* Center text in buttons */
  white-space: nowrap;
  /* Prevent button text from wrapping */
  overflow: hidden;
  /* Hide overflow text */
  text-overflow: ellipsis;
  /* Add ellipsis for overflow text */
}

.github-card-footer a:hover {
  background-color: #8a2be2;
}

.github-card-footer .tags {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
  /* Allow tags to wrap to the next line if needed */
}

.github-card-footer .tags span {
  background-color: grey;
  color: white;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 0.8rem;
  /* Fixed font size for hashtags */
  white-space: nowrap;
  /* Prevent hashtags from wrapping */
  overflow: hidden;
  /* Hide overflow text */
  text-overflow: ellipsis;
  /* Add ellipsis for overflow text */
  max-width: 100px;
  /* Fixed max width for hashtags */
}

.skill-rating {
  display: inline-block;
  font-family: monospace;
  font-size: 16px; /* Adjust size as needed */
  position: relative;
  color: #fbd051;
}

.skill-rating::before {
  content: "◻◻◻◻◻"; /* Empty squares */
  display: inline-block;
  position: absolute;
  left: 0;
  top: 0;
  z-index: 1;
}

.skill-rating::after {
  content: ""; /* Filled squares */
  display: inline-block;
  position: absolute;
  left: 0;
  top: 0;
  z-index: 2;
  width: 0;
  overflow: hidden;
  white-space: nowrap;
  transition: width 1.5s ease-in-out; /* Smooth transition */
}

/* Class to trigger animation */
.skill-rating.animate::after {
  width: 100%;
}

#back-to-top {
  display: none;
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: #bf00ff;
  color: white;
  border: none;
  padding: 10px 15px;
  cursor: pointer;
  border-radius: 5px;
  font-size: 16px;
  opacity: 85%;
}
#back-to-top:hover {
  background: #8a2be2;
}

/* Hack The Box Badges Section */
.htb-badges {
  text-align: center;
  margin: 40px auto;
  padding: 20px;
  background-color: #282a36; /* Same gray as other sections */
  border-radius: 8px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  border: 1px solid #c5c6c7; /* Matches other section borders */
}

/* Header Container */
.htb-badges-header {
  display: flex;
  justify-content: center;
  align-items: center; /* Ensures vertical alignment */
  gap: 10px; /* Adds spacing between logo & text */
  margin-bottom: 15px;
}

/* HTB Logo */
#htb-logo {
  width: 50px; /* Adjust width for balance */
  height: auto;
}

/* Section Title */
.htb-badges h2 {
  font-family: monospace;
  font-size: 1.8rem;
  color: #c5c6c7;
  text-transform: uppercase;
  letter-spacing: 1px;
  display: flex;
  align-items: center; /* Centers text with logo */
  gap: 10px; /* Spacing between logo and text */
  border-bottom: 1px solid #c5c6c7;
  padding-bottom: 5px;
  margin: 0;
}

/* Badges Container */
.htb-badge-container {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 15px;
  margin-top: 10px;
}

/* Badge Styling */
.htb-badge-container img {
  width: 180px; /* Consistent badge size */
  height: auto;
  border-radius: 8px;
  transition: transform 0.1s ease-in-out, filter 0.1s ease-in-out;
  filter: grayscale(20%) brightness(90%);
}

.htb-badge-container img:hover {
  transform: scale(1.05);
  filter: grayscale(0%) brightness(100%)
    drop-shadow(0 0 10px rgba(255, 255, 255, 0.5));
}

/* Description */
.htb-badges p {
  margin-top: 15px;
  font-size: 1rem;
  color: #c5c6c7;
  font-family: "Courier New", Courier, monospace;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
  .htb-badge-container {
    flex-direction: column;
    align-items: center;
  }

  .htb-badge-container img {
    width: 150px;
  }

  #htb-logo {
    width: 40px; /* Slightly smaller on mobile */
  }
}

@media (max-width: 480px) {
  .htb-badges h2 {
    font-size: 1.5rem;
  }

  .htb-badge-container img {
    width: 130px;
  }
}

/* Police Assistance Section */
.police {
  background-color: #282a36; /* Same as other sections */
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  margin: 20px auto;
  max-width: 800px;
  border: 1px solid rgba(191, 0, 255, 0.2); /* Subtle border for consistency */
}

.police h2 {
  color: #bf00ff;
  border-bottom: 1px solid #c5c6c7;
  padding-bottom: 5px;
  font-size: 1.8rem;
  margin-bottom: 20px;
}

.police h3 {
  color: #c5c6c7;
  font-size: 1.5rem;
  margin-top: 20px;
  margin-bottom: 15px;
}

.police h4 {
  color: #bf00ff;
  font-size: 1.2rem;
  margin-top: 15px;
  margin-bottom: 10px;
}

.police p {
  color: #c5c6c7;
  line-height: 1.6;
  font-size: 1rem;
  margin-bottom: 15px;
}

.police ul {
  list-style: none;
  padding-left: 20px;
  color: #c5c6c7;
}

.police ul li {
  margin: 10px 0;
  position: relative;
  padding-left: 20px;
}

.police ul li::before {
  content: "▹";
  color: #bf00ff;
  position: absolute;
  left: 0;
}

.case-details {
  background-color: #1e1e2f; /* Same as other section dividers */
  padding: 15px;
  border-radius: 8px;
  margin-top: 20px;
  border: 3px solid rgba(191, 0, 255, 0.1);
}

.case-details p {
  color: white;
}

.disclaimer {
  background-color: #1e1e2f; /* Same as other section dividers */
  padding: 15px;
  border-radius: 8px;
  margin-top: 20px;
  border: 3px solid rgba(255, 68, 68, 0.2);
}

.disclaimer h4 {
  color: #ff4444;
  font-size: 1.2rem;
  margin-bottom: 10px;
}

.disclaimer p {
  color: #c5c6c7;
  font-size: 0.9rem;
  line-height: 1.6;
}

/* Responsive Design */
@media (max-width: 768px) {
  .police {
    padding: 15px;
  }

  .police h2 {
    font-size: 1.6rem;
  }

  .police h3 {
    font-size: 1.4rem;
  }

  .police h4 {
    font-size: 1.1rem;
  }

  .police p {
    font-size: 0.95rem;
  }
}

@media (max-width: 480px) {
  .police h2 {
    font-size: 1.5rem;
  }

  .police h3 {
    font-size: 1.3rem;
  }

  .police h4 {
    font-size: 1rem;
  }

  .police p {
    font-size: 0.9rem;
  }
}

.footer {
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.footer.hide-footer {
  opacity: 0;
  transform: translateY(100%);
}

.certificate {
  width: 100%;
}

/* Modal styles */
.modal {
  display: none; /* Hidden by default */
  position: fixed; /* Stay in place */
  z-index: 1000; /* Sit on top */
  left: 0;
  top: 0;
  width: 100%; /* Full width */
  height: 100%; /* Full height */
  overflow: auto; /* Enable scroll if needed */
  background-color: rgba(0, 0, 0, 0.8); /* Black w/ opacity */
  backdrop-filter: blur(5px); /* Add blur effect to the background */
  display: flex; /* Use flexbox to center content */
  justify-content: center; /* Center horizontally */
  align-items: center; /* Center vertically */
}

.modal-content {
  display: block;
  max-width: 90%; /* Width of the modal */
  max-height: 90%; /* Max height */
  border-radius: 2px; /* Optional: round corners */
}

.close {
  position: absolute;
  top: 20px;
  right: 35px;
  color: white;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
}

em {
  color: orange;
}
