@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@400;600;700&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Nunito:ital,wght@0,300;0,400;0,600;0,700;1,300;1,400&display=swap");

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  text-decoration: none;
  outline: none;
  border: none;
  text-transform: capitalize;
  transition: all 0.2s linear;
}
html {
  font-size: 62.5%;
  overflow-x: hidden;
  scroll-behavior: smooth;
}
body {
  background: #f7f7f7;
  font-family: "Poppins", sans-serif;
}

*::selection {
  background: #2b3dda;
  color: #fff;
}

html {
  font-size: 62.5%;
  overflow-x: hidden;
}
html::-webkit-scrollbar {
  width: 0.8rem;
}
html::-webkit-scrollbar-track {
  background: rgb(235, 202, 245);
}
html::-webkit-scrollbar-thumb {
  background: #420177;
}

/* pre loader start */
.loader-container {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 10000;
  background: #e6eff1;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  width: 100%;
}
.loader-container.fade-out {
  top: -120%;
}
/* pre loader end */

/* navbar starts */
header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.7rem 10%;
  height: 6.5rem;
  background-color: #fff;
  box-shadow: 0 1px 4px rgba(146, 161, 176, 0.3);
}
/* was: min-height: 100vh */
section { padding: 2rem 9%; }

/* keep only the hero full-height */
.home { min-height: 100vh; }
.heading {
  font-size: 3.5rem;
  color: rgb(32, 32, 32);
  font-weight: 800;
  text-align: center;
}
.heading span {
  color: rgb(115, 3, 167);
}
header .logo {
  font-size: 1.9rem;
  font-weight: 800;
  text-decoration: none;
  color: #0e2431;
}
header .logo i {
  font-size: 2.2rem;
}
header .logo:hover {
  color: #fc8c05;
}
header .navbar ul {
  list-style: none;
  display: flex;
  justify-content: center;
  align-items: center;
}
header .navbar li {
  margin-left: 2.5rem;
}
header .navbar ul li a {
  font-size: 1.57rem;
  color: #0e2431;
  font-weight: 600;
  text-decoration: none;
  letter-spacing: 0.04rem;
  transition: 0.2s;
}
header .navbar ul li a.active,
header .navbar ul li a:hover {
  color: #011aff;
  border-bottom: 0.2rem solid #011aff;
  padding: 0.5rem 0;
}
/* navbar ends */

/* hamburger icon starts*/
#menu {
  font-size: 3rem;
  cursor: pointer;
  color: rgb(24, 2, 63);
  display: none;
}
@media (max-width: 768px) {
  #menu {
    display: block;
  }
  header .navbar {
    position: fixed;
    top: 6.5rem;
    right: -120%;
    width: 75%;
    height: 100%;
    text-align: left;
    align-items: flex-start;
    background-color: #0e0f31;
  }
  header .navbar ul {
    flex-flow: column;
    padding: 1rem;
  }
  header .navbar ul li {
    text-align: center;
    width: 100%;
    margin: 1rem 0;
    border-radius: 0.5rem;
    width: 26rem;
  }
  header .navbar ul li a {
    display: block;
    padding: 1rem;
    text-align: left;
    color: #fff;
    font-size: 2rem;
  }
  header .navbar ul li a.active,
  header .navbar ul li a:hover {
    padding: 1rem;
    color: #fff;
    border-radius: 0.5rem;
    border-bottom: 0.5rem solid #011aff;
  }
  .fa-times {
    transform: rotate(180deg);
  }
  header .navbar.nav-toggle {
    right: 0;
  }
}
/* hamburger icon ends */

/* hero section starts*/
.home {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  min-height: 100vh;
  align-items: center;
}
.home #particles-js {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
}
.home::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
}
.home .content {
  flex: 1 1 40rem;
  padding-top: 1rem;
  z-index: 1;
}
.home .image {
  flex: 1 1 40rem;
  z-index: 1;
}
.home .image img {
  width: 70%;
  margin-left: 6rem;
  border-radius: 50%;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  cursor: pointer;
}
.home .image img:hover {
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
}
.home .content h2 {
  font-size: 5rem;
  font-weight: 800;
  color: #002057;
}
.home .content h2 span {
  font-size: 5rem;
  font-weight: 800;
  color: #ff7b00;
}
.home .content p {
  font-size: 2.5rem;
  color: #000;
  font-weight: 600;
  padding: 1rem 0;
}
.home .content p span {
  font-size: 2.5rem;
  color: rgb(148, 8, 8);
  font-weight: 600;
  padding: 1rem 0;
}
.home .btn {
  margin-top: 1rem;
  position: absolute;
  line-height: 0;
  padding: 1.6rem 3rem;
  border-radius: 4em;
  transition: 0.5s;
  color: #fff;
  background: #2506ad;
  box-shadow: 0px 5px 18px rgba(48, 68, 247, 0.6);
  font-family: "Nunito", sans-serif;
}
.home .btn span {
  font-weight: 700;
  font-size: 1.7rem;
  letter-spacing: 0.1rem;
}
.home .btn i {
  margin-left: 0.3rem;
  font-size: 1.5rem;
  transition: 0.3s;
}
.home .btn:hover {
  background: #1a047e;
}
.home .btn:hover i {
  transform: translateX(5px);
}
/* social icons start */
.socials {
  position: relative;
  margin-top: 9rem;
}
.socials .social-icons {
  padding-left: 0;
  margin-bottom: 0;
  list-style: none;
}
.socials .social-icons li {
  display: inline-block;
  margin-bottom: 14px;
}
.social-icons a {
  font-size: 2rem;
  display: inline-block;
  line-height: 44px;
  color: #00d9ff;
  background-color: #09011b;
  width: 44px;
  height: 44px;
  text-align: center;
  margin-right: 8px;
  border-radius: 100%;
  -webkit-transition: all 0.2s linear;
  -o-transition: all 0.2s linear;
  transition: all 0.2s linear;
}
.social-icons a:active,
.social-icons a:focus,
.social-icons a:hover {
  color: #fff;
  background-color: #0685da;
}
.social-icons a.github:hover {
  background-color: #0e0e0e;
}
.social-icons a.twitter:hover {
  background-color: #00aced;
}
.social-icons a.linkedin:hover {
  background-color: #007bb6;
}
.social-icons a.dev:hover {
  background-color: #070707;
}
.social-icons a.tryhackme:hover {
  background-color: #B10000; /* TryHackMe red */
}
.social-icons a.instagram:hover {
  background-color: #ee00da;
}
.social-icons a.tryhackme img{
  width:24px; height:24px;      /* fits inside your 44px circle */
  display:block;                /* avoids baseline weirdness */
  margin:0 auto;                /* centers inside the circle */
  object-fit:contain;
}

.social-icons a.tryhackme:hover img {
  background-color: #B10000; /* TryHackMe red */
}

/* social icons end */

/* hero media queries starts*/
@media (max-width: 450px) {
  .home .btn {
    margin: 4rem 0;
  }
  .socials {
    margin-top: 12rem;
  }
  .home .image img {
    margin-top: -12rem;
  }
  .home .content p {
    font-size: 2.2rem;
  }
  .home .content p span {
    font-size: 2.2rem;
  }
}
/* hero media queries ends*/
/* hero section end */

/* about section starts */
.about {
  background: rgb(255, 255, 255);
}
.about .row {
  display: flex;
  flex-direction: row;
  gap: 2rem;
  flex-wrap: wrap;
  padding: 4rem;
}
.about .row .image {
  text-align: center;
  flex: 1 1 35rem;
}
.about .row .image img {
  margin: 4rem;
  width: 30rem;
  height: auto;
  border-radius: 5%;
  box-shadow: 0 5px 10px rgba(0, 0, 0, 0.6);
  mix-blend-mode: luminosity;
  transition: 0.3s;
  cursor: pointer;
}
.about .row .image img:hover {
  mix-blend-mode: normal;
}
.about .row .content {
  flex: 1 1 45rem;
  padding: 3rem;
}
.about .row .content h3 {
  color: rgb(27, 27, 27);
  font-size: 2.5rem;
}
.about .row .content .tag {
  font-size: 1.4rem;
  color: #020133;
  font-weight: 600;
  margin-top: 1rem;
}
.about .row .content p {
  font-size: 1.5rem;
  margin-top: 1.5rem;
  font-family: "Nunito";
  font-weight: 600;
  text-transform: none;
}
.about .row .content .box-container {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  font-family: "Nunito";
  font-weight: 600;
}
.about .row .content .box-container .box p {
  text-transform: none;
}
.about .row .content .box-container .box p span {
  color: #011aff;
}
.resumebtn {
  margin-top: 6rem;
}
.resumebtn .btn {
  padding: 1.7rem 3rem;
  border-radius: 0.5em;
  transition: 0.3s;
  color: #fff;
  background: #2506ad;
  box-shadow: 0px 5px 10px rgba(48, 68, 247, 0.6);
  font-family: "Nunito", sans-serif;
}
.resumebtn .btn span {
  font-weight: 600;
  font-size: 1.8rem;
  letter-spacing: 0.1rem;
}
.resumebtn .btn i {
  margin-left: 0.3rem;
  font-size: 1.2rem;
  transition: 0.3s;
}
.resumebtn .btn:hover {
  background: #1a047e;
}
.resumebtn .btn:hover i {
  transform: translateX(5px);
}
/* about media queries starts*/
@media screen and (max-width: 600px) {
  .about .row .image {
    margin-top: 2rem;
  }
  .about .row .image img {
    margin: 0 auto;
    width: 80%;
    mix-blend-mode: normal;
  }
  .about .row {
    padding: 0.5rem;
    margin-bottom: 7rem;
  }
  .about .row .content {
    padding: 1rem;
  }
  .about .row .content .box-container {
    gap: 0;
  }
}
/* about media queries ends*/
/* about section ends */
/* Match background of Education and Contact */

/* ===== Certifications & CTF ===== */

/* Certifications Grid */
.certs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); /* bigger cards */
  gap: 2rem; /* more spacing */
  margin-top: 2rem;
}

/* CTF Grid - fixed 2 columns for desktop */
.ctf-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem; /* more spacing between cards */
  margin-top: 2rem;
  align-items: start;
}

/* Cards */
.cert-card,
.ctf-card {
  background-color: #fff;
  border-radius: 14px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  text-align: center;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  overflow: hidden;
}
/* Shine + Drop-down Effect for Certs & CTF */
.cert-card,
.ctf-card {
  position: relative;
  overflow: hidden; /* needed for shine animation */
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.cert-card:hover,
.ctf-card:hover {
  transform: translateY(6px); /* slight drop */
  box-shadow: 0 8px 20px rgba(0,0,0,0.2);
}

.cert-card::before,
.ctf-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: -75%;
  width: 50%;
  height: 100%;
  background: linear-gradient(
    120deg,
    rgba(255, 255, 255, 0.3) 0%,
    rgba(255, 255, 255, 0.6) 50%,
    rgba(255, 255, 255, 0.3) 100%
  );
  transform: skewX(-25deg);
  transition: left 0.7s ease;
}

.cert-card:hover::before,
.ctf-card:hover::before {
  left: 125%;
}
.cert-card {
  padding: 1.5rem;
  max-width: 360px; /* bigger cert cards */
  margin: 0 auto;
}

.ctf-card {
  max-width: 440px; /* bigger CTF cards */
  margin: 0 auto;
}

.cert-card iframe,
.ctf-card iframe {
  display: block;
  border-radius: 12px;
  margin: 0 auto 1rem auto;
}
/* Cert badges */
.badge-img {
  width: 160px; /* larger badge */
  height: 160px;
  object-fit: contain;
  border-radius: 50%;
  display: block;
  margin: 0 auto 1rem auto;
}

/* CTF thumbnails */
.ctf-thumb {
  width: 100%;
  height: auto;
  border-radius: 8px;
  cursor: pointer;
  transition: opacity 0.2s ease;
}

.ctf-thumb:hover {
  opacity: 0.85;
}

/* CTF text */
.ctf-card .content {
  padding: 1rem 1.25rem 1.25rem;
}

.ctf-card .content .tag h3 {
  margin: 0 0 0.4rem 0;
  font-size: 1.1rem; /* larger title */
}

.ctf-card .desc p {
  margin: 0;
  font-size: 1rem; /* larger description */
  color: #555;
}

/* Titles & text (shared) */
.cert-card h3,
.ctf-card h3 {
  font-size: 1.2rem; /* bigger titles */
  font-weight: 600;
}

.cert-card p,
.ctf-card p {
  font-size: 1rem; /* bigger text */
  color: #555;
}

/* Responsive tweaks */
@media (max-width: 992px) {
  .ctf-grid {
    grid-template-columns: 1fr; /* stack on medium screens */
  }
}

@media (max-width: 768px) {
  .badge-img {
    width: 140px;
    height: 140px;
  }
}

@media (max-width: 480px) {
  .badge-img {
    width: 130px;
    height: 130px;
  }
}


/* Responsive Adjustments */
@media (max-width: 992px) {
  .ctf-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  }
  .ctf-thumb {
    height: 170px;
  }
}

@media (max-width: 768px) {
  .badge-img {
    width: 130px;
    height: 130px;
  }
  .ctf-thumb {
    height: 160px;
  }
}

@media (max-width: 480px) {
  .badge-img {
    width: 120px;
    height: 120px;
  }
  .ctf-thumb {
    height: 150px;
  }
}

/* ==== Lightbox ==== */
#image-lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.85);
  display: none;              /* hidden by default */
  justify-content: center;
  align-items: center;
  z-index: 9999;
  padding: 2rem;
}

#image-lightbox.open {
  display: flex;
  animation: lb-fade .15s ease-out;
}

#image-lightbox img {
  max-width: min(1200px, 92vw);
  max-height: 90vh;
  border-radius: 10px;
  box-shadow: 0 10px 30px rgba(0,0,0,.4);
}

.lightbox-close {
  position: absolute;
  top: 18px;
  right: 24px;
  background: rgba(255,255,255,.15);
  color: #fff;
  border: 0;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  font-size: 28px;
  line-height: 44px;
  text-align: center;
  cursor: pointer;
  backdrop-filter: blur(4px);
}

.lightbox-close:hover { background: rgba(255,255,255,.25); }

@keyframes lb-fade {
  from { opacity: 0; } to { opacity: 1; }
}

/* Prevent background scroll when lightbox is open */
body.no-scroll { overflow: hidden; }

/* Optional: indicate the image is clickable */
.ctf-thumb { cursor: zoom-in; }

/* =========================
   TryHackMe (ONLY NEW PART)
   ========================= */
.thm-heading{
  display: flex;
  align-items: center;
  justify-content: center;   /* center title + icon */
  gap: 14px;
  margin: 0 auto 1.2rem;
  text-align: center;
}

.thm-heading .thm-icon{
  display: inline-block;
  height: 46px;              /* crisp icon size */
  width: auto;
  vertical-align: middle;
  transform: translateY(2px); /* align with text baseline */
  filter: drop-shadow(0 1px 1px rgba(0,0,0,.12));
}

.tryhackme-container{
  display: flex;
  justify-content: center;   /* centers the iframe block */
  margin: 1rem auto 0;
  width: 100%;
}

/* Bigger, responsive badge; no white card behind it */
.thm-iframe{
  border: none;
  border-radius: 10px;
  width: min(820px, 96vw);   /* readable width */
  height: 260px;             /* taller for legibility */
}

/* TryHackMe Section */
.tryhackme-section{
  display: flex;
  flex-direction: column;
  align-items: center;         /* center the whole block */
  gap: 1.2rem;
  margin-top: 2rem;
}

.tryhackme-section .heading{
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.8rem;
}

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


.tryhackme-card {
  background: transparent; /* no white box */
  max-width: 380px; /* match ctf card width */
  margin: 1rem auto 0;
  display: flex;
  justify-content: center;
}

.tryhackme-badge {
  display: flex;
  justify-content: center;
  margin-top: 1rem;
}

/* skills section starts */
.skills {
  min-height: 90vh;
  background: linear-gradient(to bottom, #57059e, #4a00e0);
}
.skills h2 {
  color: #fff;
}
.skills .heading span {
  color: rgb(255, 230, 0);
}
.skills .container {
  background: rgba(0, 0, 22, 0.4);
  color: #fff;
  border-radius: 1rem;
  padding: 2rem;
  width: 90%;
  margin: auto;
  margin-top: 2rem;
}
.skills .container .row {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  flex-wrap: wrap;
  gap: 1.8rem;
}
.skills .container .bar {
  margin-bottom: 15px;
  padding: 10px;
  border-radius: 1rem;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  background: rgba(0, 0, 22, 0.9);
  transition: 0.2s;
}
.skills .container .bar:hover {
  box-shadow: 0 8px 10px rgba(0, 2, 68, 0.8) !important;
  background-color: rgba(0, 0, 0, 0.9) !important;
}
.skills .container .bar .info {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  margin-top: 1rem;
}
.skills .container .bar .info i {
  font-size: 4rem;
}
.skills .container .bar .info span {
  font-size: 2rem;
  font-weight: 500;
  font-family: "Poppins";
  margin-left: 0.5rem;
}
/* skills media queries starts*/
@media screen and (max-width: 600px) {
  .skills .container {
    padding: 0;
    margin: 0;
  }
  .skills .container .row {
    grid-template-columns: repeat(2, 1fr);
    margin: 1rem;
    padding: 2rem 0.2rem 2rem 0.2rem;
    gap: 1rem;
  }
  .skills .container {
    margin-top: 5px;
    width: 100%;
  }
}
/* skills media queries ends*/
/* skills section ends */

/* education section starts */
.education {
  background: #e5ecfb;
  min-height: 80vh;
}
.education .qoute {
  font-size: 1.5rem;
  text-align: center;
  font-family: "Nunito", sans-serif;
  font-weight: 600;
  margin-top: 0.5rem;
}
.education .box-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  margin-bottom: 2.4rem;   /* gives space before the View All button */
}
.education .box-container .box {
  display: flex;
  flex-direction: row;
  width: 80%;
  border-radius: 0.5rem;
  box-shadow: 0.2rem 0.5rem 1rem rgba(0, 0, 0, 0.2);
  text-align: center;
  position: relative;
  margin-top: 2rem;
  overflow: hidden;
  transition: 0.3s;
  background: rgb(252, 252, 252);
}
.education .box-container .box:hover {
  transform: scale(1.03);
  box-shadow: 1rem 0.5rem 1.2rem rgba(0, 0, 0, 0.3);
}
.education .box-container .box .image {
  flex: 1 1 20rem;
  width: 100%;
}
.education .box-container .box img {
  object-fit: cover;
  position: relative;
  width: 100%;
  height: 100%;
}
.education .box-container .box .content {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 1rem;
  flex-wrap: wrap;
  flex: 1 1 70rem;
}
.education .box-container .box .content h3 {
  font-size: 2.5rem;
  color: #012970;
  padding: 0.5rem 0;
  font-weight: 600;
  text-align: left;
  margin-left: 1rem;
}
.education .box-container .box .content p {
  font-size: 1.5rem;
  margin-left: 1rem;
  text-align: left;
}
.education h4 {
  font-size: 2rem;
  color: rgb(34, 109, 0);
  text-align: left;
  margin: 1rem;
  font-family: "Nunito", sans-serif;
  font-weight: 700;
}

/* education media queries starts*/
@media screen and (max-width: 600px) {
  .education .box-container .box {
    flex-direction: column;
    width: 100%;
  }
  .education .box-container .box .image {
    width: 100%;
    height: 25rem;
  }
  .education .box-container .box img {
    width: 100%;
  }
  .education .box-container .box .content {
    position: relative;
    display: flex;
    flex-direction: column;
    padding: 1rem;
    flex-wrap: wrap;
    flex: 0;
  }
  .education .btns {
    margin-top: 2rem;
    margin-left: 1rem;
    margin-right: 1rem;
    flex-wrap: wrap;
  }
}
/* education media queries ends*/
/* education section ends */

/* work section starts */
.work {
  /* background: #010124; */
  background: linear-gradient(to bottom, #000031, #00002c);
}
.work h2 {
  color: #fff;
  padding: 1rem;
}
.work .heading span {
  color: rgb(255, 230, 0);
}
.work .box-container {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin: 2rem;
}
.work .box-container .box {
  flex: 1 1 30rem;
  border-radius: 0.5rem;
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.1);
  position: relative;
  overflow: hidden;
  height: 30rem;
}
.work .box-container .box img {
  height: 100%;
  width: 100%;
  object-fit: cover;
}
.work .box-container .box .content {
  height: 100%;
  width: 100%;
  position: absolute;
  top: 85%;
  left: 0;
  background: rgba(255, 255, 255, 0.9);
  display: flex;
  flex-direction: column;
}
.work .box-container .box .content .tag {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  height: 4.5rem;
  width: 100%;
  padding-left: 1rem;
  background: #ffd900;
}
.work .box-container .box .content .tag h3 {
  font-size: 2rem;
}
.work .box-container .box:hover .content {
  top: 25%;
}
.work .desc {
  margin: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.work .desc p {
  font-size: 1.5rem;
}
.work .desc .btns {
  display: flex;
  justify-content: space-between;
  width: 100%;
  margin-top: 2rem;
}
.work .desc .btns .btn {
  line-height: 0;
  display: inline;
  padding: 1.5rem 2.5rem;
  border-radius: 0.5rem;
  font-size: 1.5rem;
  color: #fff;
  background: rgb(12, 12, 12);
  margin-right: 2rem;
}
.work .desc .btns .btn:hover {
  background: #310ae0f5;
}
.work .viewall {
  display: flex;
  justify-content: center;
}
.work .viewall .btn {
  position: relative;
  line-height: 0;
  padding: 1.6rem 3rem;
  border-radius: 0.5em;
  transition: 0.5s;
  color: rgb(255, 255, 255);
  font-weight: 700;
  border: 2px solid #fff;
  box-shadow: 0px 5px 10px rgba(65, 84, 241, 0.4);
  text-align: center;
}
.work .viewall .btn span {
  font-weight: 600;
  font-size: 1.7rem;
  font-family: "Nunito", sans-serif;
}
.work .viewall .btn i {
  margin-left: 0.3rem;
  font-size: 1.5rem;
  transition: 0.3s;
}
.work .viewall .btn:hover {
  background: #fff;
  color: #000;
}
.work .viewall .btn:hover i {
  transform: translateX(5px);
}
/* work section ends */

/* experience section starts */
.experience .timeline {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
}
.experience .timeline::after {
  content: "";
  position: absolute;
  width: 6px;
  background: #020133;
  top: 0;
  bottom: 0;
  left: 50%;
  margin-left: -3px;
  z-index: -2;
}
.experience .container {
  padding: 10px 40px;
  position: relative;
  background-color: inherit;
  width: 50%;
}
/*circles on timeline*/
.experience .container::after {
  content: "\f0b1";
  position: absolute;
  width: 25px;
  height: 25px;
  right: -17px;
  background-color: rgb(255, 255, 255);
  border: 4px solid #ff9f55;
  top: 15px;
  border-radius: 50%;
  z-index: 100;
  font-size: 1.89rem;
  text-align: center;
  font-weight: 600;
  color: #02094b;
  font-family: "Font Awesome\ 5 Free";
}
.experience .left {
  left: 0;
}
.experience .right {
  left: 50%;
}
/* arrows pointing right */
.experience .left::before {
  content: " ";
  height: 0;
  position: absolute;
  top: 22px;
  width: 0;
  z-index: 1;
  right: 30px;
  border: medium solid #f68c09;
  border-width: 10px 0 10px 10px;
  border-color: transparent transparent transparent #f68c09;
}
/* arrows pointing left  */
.experience .right::before {
  content: " ";
  height: 0;
  position: absolute;
  top: 22px;
  width: 0;
  z-index: 1;
  left: 30px;
  border: medium solid #f68c09;
  border-width: 10px 10px 10px 0;
  border-color: transparent #f68c09 transparent transparent;
}
.experience .right::after {
  left: -16px;
}
.experience .content {
  background-color: #f68c09;
  position: relative;
  border-radius: 6px;
}
.experience .content .tag {
  font-size: 1.3rem;
  padding-top: 1.5rem;
  padding-left: 1.5rem;
}
.experience .content .desc {
  margin-left: 1.5rem;
  padding-bottom: 1rem;
}
.experience .content .desc h3 {
  font-size: 1.5rem;
  font-weight: 600;
}
.experience .content .desc p {
  font-size: 1.2rem;
}
/* view all button */
.morebtn {
  display: flex;
  justify-content: center;
}
.morebtn .btn {
  position: relative;
  line-height: 0;
  padding: 1.6rem 3rem;
  border-radius: 0.5em;
  transition: 0.5s;
  color: #fff;
  background: #2506ad;
  box-shadow: 0px 5px 10px rgba(48, 68, 247, 0.6);
  text-align: center;
}
.morebtn .btn span {
  font-weight: 600;
  font-size: 1.7rem;
  font-family: "Nunito", sans-serif;
}
.morebtn .btn i {
  margin-left: 0.3rem;
  font-size: 1.5rem;
  transition: 0.3s;
}
.morebtn .btn:hover {
  background: #1a047e;
}
.morebtn .btn:hover i {
  transform: translateX(5px);
}

/* Media queries - Responsive timeline on screens less than 600px wide */
@media screen and (max-width: 600px) {
  .experience {
    min-height: 80vh;
  }
  .experience .timeline {
    margin-top: 2rem;
  }
  .experience .timeline::after {
    left: 31px;
  }
  .experience .container {
    width: 100%;
    padding-left: 8rem;
    padding-right: 2rem;
  }
  .experience .container::after {
    font-size: 2.2rem;
  }
  .experience .container::before {
    left: 61px;
    border: medium solid #f68c09;
    border-width: 10px 10px 10px 0;
    border-color: transparent #f68c09 transparent transparent;
  }
  .experience .left::after {
    left: 15px;
  }
  .experience .right::after {
    left: 15px;
  }
  .experience .right {
    left: 0%;
  }
  .morebtn {
    margin-top: 3rem;
  }
}
/* experience media queries ends */
/* experience section ends */

/* ==== Get in Touch (same bg as certs-ctf) ==== */
.contact {
  position: relative;
  min-height: 60vh;
  padding: 3.2rem 9%;
  overflow: hidden;
  background: linear-gradient(135deg, #eef3ff 0%, #eaf6ff 55%, #eefaf6 100%);
}

.contact::before {
  content:"";
  position:absolute; inset:0;
  background-image:
    radial-gradient(40rem 40rem at -10% 10%, rgba(82,130,255,.10) 0%, transparent 60%),
    radial-gradient(36rem 36rem at 110% 90%, rgba(34,201,142,.10) 0%, transparent 60%),
    repeating-linear-gradient(45deg, rgba(0,0,0,.03) 0 2px, transparent 2px 12px);
  pointer-events:none;
  z-index:0;
}

.contact > * {
  position: relative;
  z-index: 1; /* keep content above background */
}

.contact .container {
  max-width: 1050px;
  width: 100%;
  background: #fff;
  border-radius: 1.5rem;
  margin: 2rem 5rem;
  box-shadow: 0 5px 10px rgba(0, 0, 0, 0.15);
}

.contact .container .content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2.5rem 2rem;
}

.contact .content .image-box {
  max-width: 60%;
  margin-left: 4rem;
}

.contact .content .image-box img {
  width: 100%;
  height: 40rem;
  position: relative;
}

.contact .content form {
  width: 45%;
  margin-right: 3.5rem;
}
form .form-group {
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.form-group .field {
  height: 50px;
  display: flex;
  position: relative;
  margin: 1rem;
  width: 100%;
}
form i {
  position: absolute;
  top: 50%;
  left: 18px;
  color: rgb(51, 51, 51);
  font-size: 17px;
  pointer-events: none;
  transform: translateY(-50%);
}
form .field input,
form .message textarea {
  width: 100%;
  height: 100%;
  outline: none;
  padding: 0 16px 0 48px;
  font-size: 16px;
  font-family: "Poppins", sans-serif;
  border-radius: 5px;
  border: 1px solid rgb(51, 51, 51);
  background: #e5ecfb;
}
.field input::placeholder,
.message textarea::placeholder {
  color: rgb(51, 51, 51);
}
.field input:focus,
.message textarea:focus {
  padding-left: 47px;
  border: 2px solid rgb(115, 3, 167);
}
.field input:focus ~ i,
.message textarea:focus ~ i {
  color: rgb(115, 3, 167);
}
form .message {
  position: relative;
  margin: 1rem;
  width: 100%;
}
form .message i {
  top: 25px;
  font-size: 20px;
  left: 15px;
}
form .message textarea {
  min-height: 130px;
  max-height: 230px;
  max-width: 100%;
  min-width: 100%;
  padding: 12px 20px 0 48px;
}
form .message textarea::-webkit-scrollbar {
  width: 0px;
}
form .button-area {
  display: flex;
  float: right;
  flex-direction: row-reverse;
}
.button-area button {
  color: #fff;
  border: none;
  outline: none;
  font-size: 1.8rem;
  cursor: pointer;
  border-radius: 5px;
  padding: 13px 25px;
  background: #2506ad;
  box-shadow: 0px 5px 10px rgba(48, 68, 247, 0.6);
  transition: 0.3s ease;
  font-family: "Nunito", sans-serif;
}
.button-area button:hover {
  background: #421cecf5;
}
.button-area span {
  font-size: 17px;
  padding: 1rem;
  display: none;
}
.button-area button i {
  position: relative;
  top: 6px;
  left: 2px;
  font-size: 1.5rem;
  transition: 0.3s;
  color: #fff;
}
.button-area button:hover i {
  left: 8px;
}
/* contact section media queries starts */
@media (max-width: 900px) {
  .contact {
    min-height: 70vh;
  }
  .contact .container {
    margin: 3rem 0 2rem 0;
  }
  .contact .container .content {
    padding: 18px 12px;
  }
  .contact .content .image-box {
    display: none;
  }
  .contact .content form {
    width: 100%;
    margin-right: 2rem;
  }
}
/* contact section media queries ends */
/* contact section ends */

/* footer section starts */
.footer {
  min-height: auto;
  padding-top: 0;
  background: rgb(0, 1, 43);
}
.footer .box-container {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
}
.footer .box-container .box {
  flex: 1 1 25rem;
  margin: 2.5rem;
}
.footer .box-container .box h3 {
  font-size: 2.5rem;
  color: #fff;
  padding-bottom: 1rem;
  font-weight: normal;
}
.footer .box-container .box p {
  font-size: 1.5rem;
  color: #ccc;
  padding: 0.7rem 0;
  text-transform: none;
}
.footer .box-container .box p i {
  padding-right: 1rem;
  color: #ffae00;
}
.footer .box-container .box a {
  font-size: 1.5rem;
  color: rgb(238, 238, 238);
  padding: 0.3rem 0;
  display: block;
}
.footer .box-container .box a:hover {
  color: #ffae00;
}
.footer .box-container .box .share {
  display: flex;
  flex-wrap: wrap;
  padding: 1rem 0;
}
.footer .box-container .box .share a {
  height: 4rem;
  width: 4rem;
  padding: 1rem;
  text-align: center;
  border-radius: 5rem;
  font-size: 1.7rem;
  margin-right: 1rem;
  transition: 0.2s;
  background: rgb(230, 230, 230);
  color: #02094b;
  border: none;
}
.footer .box-container .box .share a:hover {
  background: transparent;
  transform: scale(0.98);
  border: 0.1rem solid rgb(180, 178, 178);
  color: #ffae00;
}
.footer .credit {
  padding: 1rem 0 0 0;
  text-align: center;
  font-size: 1.5rem;
  font-family: "Nunito", sans-serif;
  font-weight: 600;
  color: #fff;
  border-top: 0.1rem solid #fff3;
}
.footer .credit a {
  color: #ffae00;
}
.footer .fa {
  color: #e90606;
  margin: 0 0.3rem;
  font-size: 1.5rem;
  animation: pound 0.35s infinite alternate;
}
@-webkit-keyframes pound {
  to {
    transform: scale(1.1);
  }
}
@keyframes pound {
  to {
    transform: scale(1.1);
  }
}
@media (max-width: 450px) {
  .footer .box-container .box {
    margin: 1.5rem;
  }
  .footer .box-container .box p {
    padding: 0.7rem;
  }
  .footer .box-container .box .share a {
    padding: 1.2rem;
  }
}
/* footer section ends */

/* common media queries starts*/
@media (max-width: 450px) {
  html {
    font-size: 55%;
  }
  body {
    padding-right: 0;
  }
  section {
    padding: 2rem;
  }
}
/* common media queries ends*/

/* scroll top starts */
#scroll-top {
  position: fixed;
  top: -140%;
  right: 2rem;
  padding: 1rem 1.5rem;
  font-size: 2rem;
  background: #ffae00;
  color: rgb(13, 0, 44);
  border-radius: 50%;
  transition: 1s linear;
  z-index: 1000;
}
#scroll-top.active {
  top: calc(100% - 12rem);
}
/* scroll top ends */
/* ==== Certifications + CTF + TryHackMe (distinct bg) ==== */
.certs-ctf{
  position: relative;
  padding: 3.2rem 9% 0.8rem;
  overflow: hidden;

  /* soft gradient: not too different from education, but distinct */
  background: linear-gradient(135deg, #eef3ff 0%, #eaf6ff 55%, #eefaf6 100%);
}

/* faint glows + super subtle grid for a security/CTF vibe */
.certs-ctf::before{
  content:"";
  position:absolute; inset:0;
  background-image:
    radial-gradient(40rem 40rem at -10% 10%, rgba(82,130,255,.10) 0%, transparent 60%),
    radial-gradient(36rem 36rem at 110% 90%, rgba(34,201,142,.10) 0%, transparent 60%),
    repeating-linear-gradient(45deg, rgba(0,0,0,.03) 0 2px, transparent 2px 12px);
  pointer-events:none;
  z-index:0;
}

/* keep content above the pattern */
.certs-ctf > *{ position: relative; z-index:1; }

/* (Optional) also match Experience if you want the same bg there */
.experience {
  background: #e5ecfb;
}

/* Stop the horizontal scrollbar from the TryHackMe iframe */
.tryhackme-section {
  align-items: center;
  gap: 1rem;
  margin-top: 2rem;
}

.tryhackme-card {
  background: transparent;
  width: 100%;
  max-width: 820px;          /* cap width on large screens */
  margin: 0 auto;
  overflow: hidden;           /* belt-and-suspenders */
}

/* Use container-relative width, not vw, to avoid overflow inside padded sections */
.thm-iframe {
  display: block;
  border: none;
  border-radius: 10px;
  width: 100%;
  height: 180px;             /* a touch shorter to reduce blank space */
}

/* Mobile: ensure no accidental overflow and comfortable heights */
@media (max-width: 768px) {
  .thm-iframe { height: 160px; }
}

/* If you want to be extra safe, explicitly allow no horizontal scroll site-wide */
html, body { overflow-x: hidden; }

/* 2️⃣ Center TryHackMe iframe properly */
.tryhackme-card {
  background: transparent;
  display: flex;
  justify-content: center;   /* horizontally center */
  align-items: center;       /* vertically center if needed */
  margin: 0 auto;
}

.thm-iframe {
  border: none;
  border-radius: 10px;
  max-width: 820px;          /* limit max size */
  width: auto;               /* shrink to badge width */
  height: 180px;
  display: block;
}
/* ===== Courses Section ===== */
.courses-section {
  background: #e5ecfb;            /* matches .education */
  padding: 3rem 9%;
}

.course-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.6rem;
  margin-top: 1.6rem;
}

.course-card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: 14px;
  text-decoration: none;          /* anchor look like a card */
  color: inherit;
  box-shadow: 0 4px 15px rgba(0,0,0,.08);
  overflow: hidden;
  position: relative;             /* for shine */
  transition: transform .3s ease, box-shadow .3s ease;
}

/* Shine sweep */
.course-card::before {
  content: "";
  position: absolute;
  top: 0; left: -75%;
  width: 50%; height: 100%;
  background: linear-gradient(120deg,
    rgba(255,255,255,0.3) 0%,
    rgba(255,255,255,0.6) 50%,
    rgba(255,255,255,0.3) 100%);
  transform: skewX(-25deg);
  transition: left .7s ease;
}

.course-card:hover {
  transform: translateY(6px);
  box-shadow: 0 8px 20px rgba(0,0,0,.2);
}
.course-card:hover::before { left: 125%; }

.course-thumb {
  width: 100%;
  aspect-ratio: 16/9;             /* consistent height */
  background: #f3f3f3;
  overflow: hidden;
}
.course-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .35s ease;
}
.course-card:hover .course-thumb img {
  transform: scale(1.04);
}

.course-body {
  padding: 1rem 1.25rem 1.25rem;
}
.course-body h3 {
  font-size: 1.3rem;
  font-weight: 700;
  color: #012970;
  margin: 0 0 .4rem 0;
}
.course-body p {
  font-size: 1rem;
  color: #555;
  margin: 0;
}

/* Keep spacing consistent with other sections */
.courses-section .viewall { margin-top: 2rem; }

/* Responsive tweak */
@media (max-width: 480px) {
  .course-body h3 { font-size: 1.15rem; }
  .course-body p  { font-size: .95rem; }
}
/* Prevent section headings from hiding under fixed header when linking */
.education,
.courses-section,
.publications-section { scroll-margin-top: 8rem; }

/* Give the first education block extra top space under the fixed header */
.education.full-education { padding-top: 9rem; }

/* Subtle visual highlight for Masters card */
.education .box.featured {
  border-left: 6px solid #6c41ff;
  box-shadow: 0 10px 28px rgba(0,0,0,.12);
  transform: translateY(0);
}
.education .box.featured:hover { transform: scale(1.02); }

/* Publications section uses same layout as Courses */
.publications-section { background: #e5ecfb; padding: 3rem 9%; }
/* Scope spacing fixes to the education page only */
.page-education .education,
.page-education .courses-section,
.page-education .publications-section { scroll-margin-top: 8rem; }

/* Don't force full viewport height on these sections */
.page-education .education,
.page-education .courses-section,
.page-education .publications-section { min-height: auto; }

/* Give the first section some top padding under fixed header, but keep it tight */
.page-education .education.full-education { padding-top: 7.5rem; padding-bottom: 2rem; }

/* Compact spacing between sections */
.page-education .education + .courses-section { padding-top: 1.2rem; padding-bottom: 2rem; }
.page-education #btech.education { padding-top: 1.2rem; padding-bottom: 2rem; }
.page-education .publications-section { padding-top: 1.2rem; padding-bottom: 2.2rem; }

/* Small space below each card container so the next heading doesn't stick to it */
.page-education .education .box-container { margin-bottom: 1.2rem; }

/* Keep the Masters 'featured' look */
.page-education .education .box.featured {
  border-left: 6px solid #6c41ff;
  box-shadow: 0 10px 28px rgba(0,0,0,.12);
}
.page-education .education .box.featured:hover { transform: scale(1.02); }
/* === TryHackMe Badge Card (iframe) === */
.thm-card{
  display: flex;
  justify-content: center;   /* horizontal centering */
  align-items: center;
  position: relative;
  max-width: 860px;          /* matches your section width */
  margin: 1.2rem auto 0;     /* centers under the heading */
  padding: .9rem;            /* white frame around the badge */
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 4px 15px rgba(0,0,0,.08);
  overflow: hidden;          /* clip the shine */
  transition: transform .3s ease, box-shadow .3s ease;
}

/* Shine sweep */
.thm-card::before{
  content: "";
  position: absolute;
  top: 0; left: -75%;
  width: 50%; height: 100%;
  background: linear-gradient(
    120deg,
    rgba(255,255,255,0.0) 0%,
    rgba(255,255,255,0.45) 50%,
    rgba(255,255,255,0.0) 100%
  );
  transform: skewX(-25deg);
  transition: left .7s ease;
  pointer-events: none; /* don't block clicks */
}

.thm-card:hover{
  transform: translateY(6px);
  box-shadow: 0 10px 22px rgba(0,0,0,.18);
}
.thm-card:hover::before{ left: 125%; }

/* Clickable overlay (so clicking the badge opens your profile) */
.thm-link{
  position: absolute;
  inset: 0;
  z-index: 2;
}

/* The iframe itself */
.thm-iframe{
  display: block;
  width: 100%;
  height: 100px;   /* reduced height */
  border: 0;
  border-radius: 10px;
}

@media (max-width: 768px){
  .thm-iframe{ height: 180px; }
}
/* ==== Course Pages Styling ==== */
.page-course .media-card {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  padding: 1rem;
  margin: 1.2rem 0;
}

.page-course .course-figure {
  margin: 0;
  text-align: center;
}

/* Keep course images at their natural size, centered */
.page-course .media-card{
  display:flex;
  justify-content:center;
}

.page-course .course-figure{
  margin: 0 auto;
  max-width: 920px;       /* hard cap so it never gets huge on wide screens */
  text-align: center;
}

.page-course .course-figure img{
  width: auto;            /* use natural width */
  max-width: 100%;        /* but don’t overflow on small screens */
  height: auto;
  border-radius: 10px;
  display: block;
  transition: transform .25s ease;
}

.page-course .course-figure figcaption{
  font-size: 1.3rem;
  color: #333;
  margin-top: .6rem;
  text-transform: none;
}

.page-course .course-figure img:hover {
  transform: scale(1.015);
}

.page-course .course-figure figcaption {
  font-size: 1.3rem;
  color: #333;
  margin-top: 0.6rem;
  text-transform: none;
}
/* ==== Course Pages Styling (shared by all course detail pages) ==== */
.page-course { background:#e5ecfb; }
.page-course section { min-height:auto; padding-top:7.5rem; padding-bottom:2rem; }

/* hero wrapper */
.page-course .hero{
  background: linear-gradient(135deg, #eef3ff 0%, #eaf6ff 55%, #eefaf6 100%);
  border-radius:14px;
  padding:1.6rem;
  box-shadow:0 4px 12px rgba(0,0,0,.06);
}

/* white cards */
.page-course .subtle-card{
  background:#fff;
  border-radius:14px;
  box-shadow:0 4px 15px rgba(0,0,0,.08);
  padding:1.25rem;
  margin:1.2rem 0;
}

/* meta grid and two-column sections */
.page-course .meta-grid{
  display:grid;
  grid-template-columns: repeat(auto-fit, minmax(240px,1fr));
  gap:1rem;
}

.page-course .two-col{
  display:grid;
  grid-template-columns: 1.1fr .9fr;
  gap:1.4rem;
}
@media (max-width: 900px){
  .page-course .two-col{ grid-template-columns:1fr; }
}

/* pills / tags */
.page-course .pill{
  display:inline-block;
  padding:.35rem .8rem;
  border-radius:999px;
  background:#eef3ff;
  color:#012970;
  font-weight:700;
  font-size:1.2rem;
  margin-right:.5rem;
  margin-bottom:.5rem;
  text-transform:none;
}

/* typography tweaks (keep course text normal-case) */
.page-course p,
.page-course li,
.page-course .bread { text-transform:none; }

.page-course h3{
  font-size:2rem;
  margin-bottom:.6rem;
  color:#012970;
}
.page-course ul{ padding-left:1.3rem; }
.page-course li{ font-size:1.45rem; margin:.35rem 0; }

/* breadcrumb + links */
.page-course .bread{ font-size:1.3rem; margin-bottom:.6rem; }
.page-course .bread a{ color:#2506ad; }
.page-course .resource-list a{ color:#2506ad; }
.page-course .resource-list a:hover{ text-decoration:underline; }

/* CTA row */
.page-course .btn-row{ display:flex; gap:.8rem; flex-wrap:wrap; margin-top:.8rem; }
.page-course .btn-row .btn{ border-radius:.5rem; }

/* media card (you already had these, keep them here for completeness) */
.page-course .media-card{
  background:#fff;
  border-radius:14px;
  box-shadow:0 4px 15px rgba(0,0,0,.08);
  padding:1rem;
  margin:1.2rem 0;
}
.page-course .course-figure{ margin:0; text-align:center; }
.page-course .course-figure img{
  max-width: 100%;       /* don't exceed container */
  height: auto;          /* keep aspect ratio */
  border-radius: 10px;
  display: inline-block; /* allow natural sizing */
  object-fit: contain;   /* keep original proportions */
  transition: transform .25s ease;
}
.page-course .course-figure img:hover{ transform: scale(1.015); }
.page-course .course-figure figcaption{
  font-size:1.3rem;
  color:#333;
  margin-top:.6rem;
  text-transform:none;
}
/* --- Multi-level dropdown nav --- */
.navbar .nav-root { display:flex; align-items:center; gap:1.2rem; list-style:none; }
.navbar .nav-root > li { position:relative; }
.navbar a { display:inline-flex; align-items:center; gap:.4rem; }
.navbar .caret { font-size:.75rem; opacity:.8; }

/* Level 1 dropdown under "Education" */
.has-dropdown > .dropdown {
  position:absolute; top:100%; left:0;
  min-width: 16rem;
  background:#fff; border-radius:.6rem;
  box-shadow: 0 10px 24px rgba(0,0,0,.12);
  padding:.6rem 0; list-style:none;
  display:none; z-index:50;
}
.has-dropdown:hover > .dropdown,
.has-dropdown:focus-within > .dropdown { display:block; }

/* Items inside dropdown */
.dropdown > li > a {
  padding:.6rem 1rem; display:block; white-space:nowrap;
}
.dropdown > li > a:hover { background:var(--light, #f5f7fb); }

/* Level 2 submenu: Masters → courses */
.has-submenu { position:relative; }
.has-submenu > .submenu {
  position:absolute; top:0; left:100%;
  min-width: 18rem;
  background:#fff; border-radius:.6rem;
  box-shadow: 0 10px 24px rgba(0,0,0,.12);
  padding:.6rem 0; list-style:none;
  display:none;
}
.has-submenu:hover > .submenu,
.has-submenu:focus-within > .submenu { display:block; }

/* Mobile stacking */
@media (max-width: 992px) {
  .navbar .nav-root { flex-direction:column; align-items:flex-start; gap:0; }
  .has-dropdown > .dropdown,
  .has-submenu > .submenu {
    position:static; box-shadow:none; display:none; padding:0; margin-left:1rem;
  }
  .has-dropdown:focus-within > .dropdown,
  .has-dropdown.open > .dropdown { display:block; }
  .has-submenu:focus-within > .submenu,
  .has-submenu.open > .submenu { display:block; }
  .dropdown > li > a { padding:.6rem 0; }
}
/* featured masters: innovative layout */
.box.featured .content { padding-right: 1.5rem; }
.box.featured .content .ok { color: #1f9d55; font-weight: 700; }

.stat-grid {
  display:grid; grid-template-columns: repeat(4, minmax(140px,1fr));
  gap:.8rem; margin: .8rem 0 1rem;
}
.stat {
  display:flex; gap:.6rem; align-items:center;
  background:#f7f9fc; border:1px solid #eef2f7; border-radius:12px; padding:.6rem .8rem;
}
.stat-num {
  width:36px; height:36px; border-radius:50%;
  display:grid; place-items:center; font-weight:800; background:#fff; border:1px solid #e6ecf3;
}
.stat-title { font-weight:700; line-height:1.1; }
.stat-desc { font-size:.82rem; color:#5b6573; }

.lead { margin:.4rem 0 1rem; color:#2b3340; }

.details-wrap details {
  border:1px solid #e8edf5; border-radius:12px; background:#fff;
  padding:.6rem .8rem; margin:.6rem 0;
}
.details-wrap summary {
  cursor:pointer; font-weight:700; list-style:none;
  display:flex; align-items:center; gap:.5rem;
}
.details-wrap summary::-webkit-details-marker { display:none; }

.checklist { margin:.6rem 0 .2rem 1.2rem; }
.checklist li { margin:.25rem 0; }

.pill-row { display:flex; flex-wrap:wrap; gap:.4rem; margin:.6rem 0 .2rem; }
.pill {
  background:#eef5ff; color:#174ea6; border:1px solid #d8e6ff;
  padding:.25rem .55rem; border-radius:999px; font-size:.82rem; white-space:nowrap;
}

.link-grid {
  display:grid; grid-template-columns: repeat(2, minmax(180px,1fr)); gap:.4rem .8rem; margin-top:.5rem;
}
.link-grid a { text-decoration:none; color:#1a2a3a; border-bottom:1px dashed #c9d4e5; }
.link-grid a:hover { color:#0b63ce; border-bottom-color:#0b63ce; }

.btn.slim-btn { padding:.55rem .9rem; border-radius:.8rem; margin-top:.6rem; }

/* responsive */
@media (max-width: 1024px){
  .stat-grid { grid-template-columns: repeat(2, minmax(160px,1fr)); }
}
@media (max-width: 720px){
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .link-grid { grid-template-columns: 1fr; }
}
/* ===== Mega menu base ===== */
.navbar .nav-root { display:flex; align-items:center; gap:1.2rem; list-style:none; }
.navbar .nav-root > li { position:relative; }
.navbar a { display:inline-flex; align-items:center; gap:.4rem; }
.navbar .caret { font-size:.75rem; opacity:.8; }

.has-mega .mega {
  position:absolute; top:100%; left:0;
  width: min(880px, 94vw);
  background:#fff; border-radius:12px;
  box-shadow: 0 12px 28px rgba(0,0,0,.14);
  padding: .8rem .9rem 1rem;
  display:none; z-index:60;
}
.has-mega:hover > .mega,
.has-mega:focus-within > .mega { display:block; }

/* ===== Horizontal tabs (Masters | Bachelors) ===== */
.edu-tabs {
  display:flex; gap:.6rem; border-bottom:2px solid #eef2f7; padding:.2rem 0 .5rem;
}
.edu-tab {
  display:inline-flex; align-items:center; gap:.5rem;
  padding:.45rem .75rem; border-radius:10px;
  font-weight:700; color:#0f172a; text-decoration:none;
}
.edu-tab:hover { background:#f5f7fb; }
.edu-tab i { opacity:.9; }

/* ===== Courses panel ===== */
.edu-courses { padding-top:.7rem; }
.courses-grid {
  display:grid; grid-template-columns: repeat(2, minmax(220px, 1fr));
  gap:.5rem .7rem;
}
.course-chip {
  display:flex; align-items:center; gap:.5rem;
  text-decoration:none;
  background:#f7f9ff; border:1px solid #e1e9ff;
  border-radius:999px; padding:.5rem .7rem; font-weight:600;
  color:#0f172a;
  transition: all .15s ease;
}
.course-chip i { font-size:.95rem; opacity:.9; }
.course-chip:hover {
  background:#eaf2ff; border-color:#cfe0ff; transform: translateY(-1px);
}

.courses-footer { margin-top:.6rem; text-align:right; }
.courses-footer .see-all {
  text-decoration:none; font-weight:700; color:#0b63ce;
}
.courses-footer .see-all:hover { text-decoration:underline; }

/* keep dropdown aligned and not too tall */
.edu-mega { max-height: 70vh; overflow:auto; }

/* ===== Mobile behavior ===== */
@media (max-width: 992px){
  .navbar .nav-root { flex-direction:column; align-items:flex-start; gap:0; }
  .has-mega .mega {
    position:static; width:100%; box-shadow:none; padding: .4rem 0 .6rem;
  }
  .edu-tabs { gap:.4rem; }
  .courses-grid { grid-template-columns: 1fr; }
}
/* Smaller course pill styles in mega menu */
.mega ul li a {
  display: flex;
  align-items: center;
  gap: 6px; /* space between icon and text */
  padding: 6px 10px; /* reduced size */
  font-size: 0.9rem; /* slightly smaller text */
  border-radius: 18px; /* less rounded corners */
}

.mega ul li a i {
  font-size: 1rem; /* smaller icons */
}
/* === Compact course chips in Education mega menu === */
.navbar .has-mega .mega { width: min(760px, 94vw); } /* a bit narrower */

.navbar .has-mega .mega .edu-courses .courses-grid{
  grid-template-columns: repeat(2, minmax(200px, 1fr));
  gap: .4rem .6rem;
}

.navbar .has-mega .mega a.course-chip{
  padding: .35rem .6rem;      /* smaller pill */
  font-size: 1.3rem;          /* smaller text (1rem = 10px with your root) */
  border-radius: 14px;        /* tighter corners */
  line-height: 1.2;
  font-weight: 600;           /* was bold-looking */
}

.navbar .has-mega .mega a.course-chip i{
  font-size: 1.2rem;          /* smaller icon */
}
/* TryHackMe section */
.tryhackme-section .tryhackme-icon {
  height: 28px;
  width: 28px;
  vertical-align: middle;
  margin-right: .5rem;
}

.thm-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
  margin-top: 1rem;
}

@media (max-width: 820px) {
  .thm-grid { grid-template-columns: 1fr; }
}

.thm-card {
  position: relative;
  background: #fff;
  border-radius: 1.25rem;           /* 20px */
  box-shadow: 0 8px 24px rgba(0,0,0,.08);
  overflow: hidden;
  transition: transform .2s ease, box-shadow .2s ease;
}

.thm-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(0,0,0,.12);
}

/* Make whole card clickable without covering focusable children */
.thm-link {
  position: absolute;
  inset: 0;
  z-index: 1;
}

/* Consistent, elegant media area */
.thm-card .media {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;            /* uniform height across cards */
  background: linear-gradient(180deg, #f6f7fb, #eef1f7);
  overflow: hidden;
}

/* Images: cover neatly with rounded corners */
.thm-card .media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Iframe: remove scrollbars & borders; fill container */
.thm-iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  overflow: hidden;
}

/* Card body */
.thm-card-header {
  position: relative;
  z-index: 2;
  padding: .9rem 1rem 1.1rem;
}

.thm-card-header h3 {
  font-size: 1.05rem;
  font-weight: 600;
  margin: 0 0 .15rem 0;
}

.thm-card-header .muted {
  margin: 0;
  font-size: .9rem;
  color: #6b7280;                  /* tailwind gray-500-ish */
}

/* Optional: subtle brand accent on hover */
.thm-card:hover .thm-card-header h3 {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}
/* keep your existing .heading styles */
.tryhackme-section .tryhackme-icon {
  height: 28px; width: 28px; vertical-align: middle; margin-right: .5rem;
}

/* vertical stack */
.thm-stack {
  display: flex;
  flex-direction: column;
  align-items: center;          /* center both items */
  gap: 1.25rem;
  margin-top: .75rem;
}

/* compact card for the live badge */
.thm-card.is-compact {
  background: #fff;
  border-radius: 1rem;
  box-shadow: 0 8px 24px rgba(0,0,0,.08);
  padding: .75rem 1rem 1rem;
  max-width: 100%;
}

/* small, tidy badge area; no forced aspect ratio */
.media--badge {
  width: 460px;                 /* looks good for THM badge */
  max-width: 100%;
  overflow: hidden;
  border-radius: .75rem;
  background: #f4f6fb;
}
.thm-badge {
  width: 100%;
  height: 120px;                /* trims iframe chrome; adjust if needed */
  border: 0;
  overflow: hidden;
}

/* card text */
.thm-card-header { padding-top: .5rem; text-align: center; }
.thm-card-header h3 { margin: 0 0 .125rem; font-weight: 600; font-size: 1.05rem; }
.thm-card-header .muted { margin: 0; color: #6b7280; font-size: .9rem; }

/* natural-size image (no aspect ratio) */
.thm-figure { margin: 0; text-align: center; }
.thm-figure img {
  display: block;
  width: auto;                  /* natural width */
  height: auto;                 /* natural height */
  max-width: min(100%, 1000px); /* prevent overflow on small screens, but no squish */
  border-radius: 1rem;
  box-shadow: 0 10px 28px rgba(0,0,0,.10);
}
.thm-figure figcaption {
  margin-top: .5rem;
  font-size: .95rem;
  color: #6b7280;
}
/* TryHackMe clean vertical layout */
.tryhackme-icon { height: 28px; width: 28px; vertical-align: middle; margin-right: .5rem; }

.thm-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;                   /* space between badge and screenshot */
  margin-top: .75rem;
}

.thm-figure {
  margin: 0;
  background: #fff;
  border-radius: 16px;
  padding: 12px;
  box-shadow: 0 10px 28px rgba(0,0,0,.10);
  width: 100%;
  max-width: 760px;            /* tidy readable width */
  text-align: center;
}

.thm-figure img {
  display: block;
  width: 100%;                 /* responsive, but… */
  height: auto;                /* …keeps aspect ratio */
  border-radius: 12px;
}

.thm-figure--natural img {
  width: auto;                 /* show natural size */
  max-width: 100%;             /* only scale down if viewport is small */
  height: auto;
  margin: 0 auto;              /* center if image is narrower */
}

.thm-figure figcaption {
  margin-top: .5rem;
  font-size: .95rem;
  color: #6b7280;
}
.tryhackme-icon {
  height: 28px;
  width: 28px;
  vertical-align: middle;
  margin-right: .5rem;
}

.thm-showcase {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
  margin-top: 1rem;
}

.thm-figure {
  margin: 0;
  text-align: center;
}

.thm-figure img {
  display: block;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

/* Small badge: fixed width, keeps original aspect ratio */
.thm-figure--badge img {
  width: 300px;
  height: auto;
}

/* Big profile: show natural size but shrink if viewport is too small */
.thm-figure--profile img {
  width: auto;
  max-width: 100%;
  height: auto;
}

.thm-figure figcaption {
  margin-top: 0.4rem;
  font-size: 0.9rem;
  color: #6b7280;
}/* Section layout */
.thm-stage { display:flex; flex-direction:column; align-items:center; gap:.75rem; }
.tryhackme-icon { height:28px; width:28px; vertical-align:middle; margin-right:.5rem; }

.thm-layer { position:relative; }
.thm-profile {
  display:block; width:auto; max-width:100%; height:auto;
  border-radius:12px; box-shadow:0 10px 28px rgba(0,0,0,.10);
}

/* floating badge sticker */
.thm-sticker {
  position:absolute; top:12px; left:12px;         /* pin corner */
  display:block; transform:translateY(-6px);       /* tiny lift */
  filter: drop-shadow(0 6px 16px rgba(0,0,0,.22));
}
.thm-sticker img {
  width: 260px; height:auto; display:block; border-radius:12px;
}

/* mobile: stack badge below the image so it doesn't overlap content */
@media (max-width: 520px) {
  .thm-sticker { position:static; transform:none; margin-top:.5rem; }
  .thm-sticker img { width: 220px; }
}

.thm-caption { margin:0; color:#6b7280; font-size:.95rem; text-align:center; }

/* Section layout */
.thm-showcase { display:flex; flex-direction:column; align-items:center; gap:1rem; }

/* SMALL BADGE: shrink-wrap to image; no big white box */
.thm-figure--badge {
  display:inline-block;           /* shrink to contents */
  background: transparent;        /* remove card */
  padding: 0;                     /* remove padding */
  border-radius: 0;
  box-shadow: none;
  margin: 0;                      /* no extra margins */
}
.thm-figure--badge img {
  width: 300px;                   /* tidy size */
  height: auto;
  display: block;                 /* no baseline gap */
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0,0,0,.08);
}
.thm-figure--badge figcaption {
  margin-top: .4rem;
  text-align: center;
  font-size: .9rem;
  color: #6b7280;
}

/* PROFILE: natural size, only scales down on small screens */
.thm-figure--profile {
  margin: 0;
  text-align: center;
}
.thm-figure--profile img {
  width: auto; max-width: 100%; height: auto;
  display: block;                 /* remove baseline gap */
  border-radius: 12px;
  box-shadow: 0 10px 28px rgba(0,0,0,.10);
}
.thm-figure--profile figcaption {
  margin-top: .5rem; font-size: .95rem; color:#6b7280;
}
/* 1) Tighten the Certifications/CTF section bottom space */
section#certs,
.certs-ctf {
  padding-bottom: 1rem !important;
  margin-bottom: 0 !important;
}

/* 2) Remove extra top gap before Projects */
section#work,
.work {
  margin-top: 0 !important;
}

/* 3) Ensure the lightbox never takes layout space until opened */
#image-lightbox[aria-hidden="true"] { display: none !important; }
#image-lightbox[aria-hidden="false"] {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,.6);
  z-index: 9999;
}
/* Kill the forced full-screen height on the Certifications/CTF section */
#certs,
section.certs-ctf {
  min-height: auto !important;   /* override the global 100vh */
  padding-bottom: 1rem !important;
  margin-bottom: 0 !important;
}

/* (Optional) Keep only the hero full-height */
.home { min-height: 100vh; }      /* leave this as your only full-screen section */
#certs .thm-figure:last-child,
#certs .ctf-grid:last-child { margin-bottom: 0 !important; }
/* kill the 100vh just for the certs section */
#certs { min-height: auto !important; padding-bottom: 1rem !important; }
#certs .thm-figure:last-child { margin-bottom: 0 !important; }
#work { margin-top: 0 !important; padding-top: 1rem !important; }
/* layout */
.thm-showcase { display:flex; flex-direction:column; align-items:center; gap:1rem; margin-top:.75rem; }
.tryhackme-icon { width:28px; height:28px; vertical-align:middle; margin-right:.5rem; }

/* shared figure styles */
.thm-figure { margin:0; text-align:center; }
.thm-figure figcaption { margin-top:.4rem; font-size:.9rem; color:#6b7280; }

/* badge card with iframe */
.thm-badge-card{
  position:relative;
  display:inline-block;
  background:#fff;
  padding:8px;
  border-radius:14px;
  box-shadow:0 8px 24px rgba(0,0,0,.08);
}
.thm-badge-iframe{
  display:block;
  width:320px;            /* adjust if you want larger/smaller */
  height:100px;
  border:0;
  border-radius:10px;
  overflow:hidden;        /* hide any iframe chrome */
}
.thm-badge-link{ position:absolute; inset:0; z-index:2; } /* click-anywhere */

@media (max-width:420px){
  .thm-badge-iframe{ width:280px; height:95px; }
}

/* profile image: natural size, scales down on small screens */
.thm-profile-img{
  display:block;
  width:auto;             /* use intrinsic width */
  max-width:100%;         /* but don’t overflow on small screens */
  height:auto;
  border-radius:12px;
  box-shadow:0 10px 28px rgba(0,0,0,.10);
}
/* TryHackMe badge — no scrollbars */
.thm-badge-iframe{
  width: 420px;      /* big enough for the badge */
  height: 130px;
  border: 0;
  display: block;
  overflow: hidden;  /* hides frame chrome if any */
}

/* Small screens: scale the frame down instead of shrinking
   its viewport (which would reintroduce scrollbars) */
@media (max-width: 480px){
  .thm-badge-card{ width: 320px; }             /* container width */
  .thm-badge-iframe{
    width: 420px; height: 130px;               /* keep natural size */
    transform: scale(.76);                     /* visually smaller */
    transform-origin: top left;
  }
}
/* Center + blend the badge with the section background */
.thm-badge-card{
  display: flex;
  justify-content: center;
  align-items: center;
  width: fit-content;
  margin: 0 auto;

  /* make it match the background */
  background: transparent;   /* or: background: inherit; */
  box-shadow: none;
  padding: 0;
  border-radius: 0;
}

/* keep your iframe size */
.thm-badge-iframe{
  width: 420px;
  height: 130px;
  border: 0;
  display: block;
}

@media (max-width: 480px){
  .thm-badge-iframe{
    transform: scale(.76);
    transform-origin: top center;
  }
}
/* Badge: centered + a small right nudge */
.thm-badge-card{
  display:flex; justify-content:center; align-items:center;
  background:transparent; box-shadow:none; padding:0; border-radius:0;
  width:fit-content; margin:0 auto;
}
.thm-badge-iframe{
  width:420px; height:130px; border:0; display:block;
  margin-left:12px;               /* <-- slight push to the right */
}
@media (max-width:480px){
  .thm-badge-iframe{
    margin-left:0;
    transform:scale(.76);
    transform-origin:top center;
  }
}
/* TryHackMe profile screenshot: no white card, centered */
.thm-figure--profile{
  background:transparent !important;
  box-shadow:none !important;
  padding:0 !important;
  border:0 !important;
  border-radius:0 !important;
  width:fit-content;
  margin:0 auto;                  /* center the figure */
  text-align:center;
}
.thm-figure--profile img{
  display:block;
  width:auto;                     /* natural size */
  max-width:min(100%, 960px);     /* shrink on small screens */
  height:auto;
  border-radius:12px;
  box-shadow:0 10px 28px rgba(0,0,0,.10); /* optional soft lift */
}
.thm-figure--profile figcaption{
  margin-top:.5rem; font-size:.95rem; color:#6b7280;
}
/* --- TryHackMe polish --- */

/* Keep the section tight and centered */
.thm-showcase { 
  display: flex; 
  flex-direction: column; 
  align-items: center; 
  gap: .6rem;                 /* tighter vertical spacing */
}

/* Badge: centered with a slight right nudge */
.thm-badge-card{
  display:flex; 
  justify-content:center; 
  align-items:center;
  background:transparent; 
  box-shadow:none; 
  padding:0; 
  border-radius:0;
  width:fit-content; 
  margin:0 auto;
}
.thm-badge-iframe{
  width:420px; 
  height:130px; 
  border:0; 
  display:block;
  margin-left:12px;           /* << nudge */
}

/* Reduce the space under the badge caption */
.thm-figure { margin: 0; }
.thm-figure figcaption{ 
  margin-top: .35rem; 
  font-size: .95rem; 
  color:#6b7280; 
}
.thm-figure--badge { margin-bottom: .4rem; }

/* Big profile image: no white card; centered; natural size */
.thm-figure--profile{
  background:transparent !important;
  box-shadow:none !important;
  padding:0 !important;
  border:0 !important;
  border-radius:0 !important;
  width:fit-content;
  margin:0 auto;              /* center the figure */
  text-align:center;
}
.thm-figure--profile img{
  display:block;
  width:auto;                 /* natural width on desktop */
  max-width:min(100%, 1024px);/* shrink on small screens */
  height:auto;
  border-radius:12px;
  box-shadow:0 10px 28px rgba(0,0,0,.10); /* subtle lift */
}

/* Mobile: center the scaled badge */
@media (max-width: 480px){
  .thm-badge-iframe{
    margin-left:0;
    transform: scale(.76);
    transform-origin: top center;
  }
}

/* work section starts */
.work{
  /* background: #010124; */
  background: linear-gradient(to bottom, #010136, #00003a);
  margin-top: 5rem;
}
.work h2{
  color: #fff;
  padding: 1rem;
}
.work .heading span{
  color: rgb(255, 230, 0);
}
.work .button-group{
  display: flex;
  flex-wrap: wrap;
  gap:1rem;
  margin: 2rem auto;
  width: 50%;
  justify-content: center;
  align-items: center;
}
.work .button-group .btn{
  outline: none;
  padding: 1rem 2rem;
  background: transparent;
  color: #fff;
  border: 1px solid #fff;
  border-radius: 3px;
  cursor: pointer;
  font-weight: 500;
}
.work .button-group .btn:hover{
  background-color: #fff;
  color: #000;
}
.work .button-group .btn.is-checked{
  background-color: #fff;
  color: #000;
}
.work .box-container{
  display: flex;
  flex-wrap: wrap;
  gap:1.5rem;
  margin: 2rem;
}
.work .box-container .box{
  flex:1 1 30rem;
  border-radius: .5rem;
  box-shadow: 0 .7rem 1rem rgba(0,0,0,.3);
  position: relative;
  overflow:hidden;
  height:30rem;
  background: #fff;
  border: none;
}
.work .box-container .box img{
  height: 100%;
  width:100%;
  object-fit: cover;
}
.work .box-container .box .content{
  height: 100%;
  width:100%;
  position: absolute;
  top:85%; left:0;
  background:rgba(255, 255, 255, 0.9);
  display: flex;
  flex-direction: column;
}
.work .box-container .box .content .tag{
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  height: 4.5rem;
  width: 100%;
  padding-left: 1rem;
  background: #ffd900;
}
.work .box-container .box .content .tag h3{
  font-size: 2rem;
}
.work .box-container .box:hover .content{
  top: 25%;
}
.work .desc {
  margin: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.work .desc p{
  font-size: 1.5rem;
}
.work .desc .btns{
  display: flex;
  justify-content: space-between;
  width: 100%;
  margin-top: 2rem;
}
.work .desc .btns .btn{
  line-height: 0;
  display: inline;
  padding: 1.5rem 2.5rem;
  border-radius: .5rem;
  font-size: 1.5rem;
  color: #fff;
  background: rgb(12, 12, 12);
  margin-right: 2rem;
}
.work .desc .btns .btn:hover{
  background: #310ae0f5;
}

@media screen and (max-width: 450px) {
  .work .button-group{
    width: 100%;
  }
  .work .box-container{
    margin: 0rem;
  }
  .work .box-container .grid-item .box{
    width: 95% !important;
  }
}

