/* ---------- Base ---------- */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: "Poppins", sans-serif;
}

body{
    background:
    linear-gradient(
      180deg,
      #020617 0%,
      #08122f 35%,
      #0f172a 100%
    );
}

/* ---------- Topbar/header ---------- */
.topbar{
  position: sticky;
  top: 0;
  z-index: 1200;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 6%;

  background: rgba(1, 39, 53, 0.95);

  backdrop-filter: blur(12px);

  border-bottom: 1px solid rgba(255,255,255,.08);

  box-shadow: 0 8px 25px rgba(0,0,0,.25);
}

/* Transparent effect when scrolled */
.topbar.scrolled {
  background: rgba(26, 26, 46, 0.85);
  backdrop-filter: blur(10px);
}

.left-top {
  display: flex;
  align-items: center;
  gap: 16px;
}

.logo {
  font-weight: 600;
  color: #ffffff;
  font-size: 1.1rem;
}

.logo span {
  color: #56ccf2;
  font-weight: 600;
  margin-left: 6px;
}

/* Menu button (hamburger) */
.menu-btn {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  background: #2e2e42;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
}

.hamburger,
.hamburger::before,
.hamburger::after {
  display: block;
  width: 20px;
  height: 2px;
  background: white;
  border-radius: 2px;
  position: relative;
}

.hamburger::before,
.hamburger::after {
  content: "";
  position: absolute;
  left: 0;
}

.hamburger::before {
  top: -6px;
}

.hamburger::after {
  top: 6px;
}

/* Right top social icons */
.right-top {
  display: flex;
  align-items: center;
  gap: 12px;
}

.social {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  color: #e0e0e0;
  text-decoration: none;
  transition: all 0.18s ease;
  background: transparent;
}

.social:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #56ccf2;
  transform: translateY(-3px);
  box-shadow: 0 6px 14px rgba(86, 204, 242, 0.25);
}

/* ---------- Sidebar ---------- */
/* ===================================
   MODERN SIDEBAR
=================================== */

.sidebar {
    position: fixed;
    top: 0;
    left: -320px;

    width: 280px;
    height: 100vh;

    background: rgba(17, 24, 39, 0.98);
    backdrop-filter: blur(12px);

    padding-top: 80px;

    box-shadow: 10px 0 40px rgba(0,0,0,0.3);

    transition: all 0.45s ease;

    z-index: 1300;

    overflow-y: auto;
}

/* Sidebar opens */
.sidebar.open {
    left: 0;
}

/* Gradient accent line */
.sidebar::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;

    width: 4px;
    height: 100%;

    background: linear-gradient(
        to bottom,
        #60a5fa,
        #2563eb,
        #7c3aed
    );
}

/* Menu Links */
.sidebar a {
    display: flex;
    align-items: center;

    padding: 16px 30px;

    color: #ffffff;
    text-decoration: none;

    font-size: 1rem;
    font-weight: 500;

    border-left: 4px solid transparent;

    transition: all 0.3s ease;
}

/* Hover Effect */
.sidebar a:hover {
    background: rgba(37,99,235,.15);

    color: #60a5fa;

    border-left: 4px solid #60a5fa;

    padding-left: 40px;

    box-shadow: inset 0 0 20px rgba(96,165,250,.15);
}

/* Active Link */
.sidebar a.active {
    background: rgba(37,99,235,.2);

    color: #60a5fa;

    border-left: 4px solid #60a5fa;
}

/* Close Button */
.close-btn {
    position: absolute;

    top: 20px;
    right: 20px;

    width: 40px;
    height: 40px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;

    background: rgba(255,255,255,.1);

    color: white;

    font-size: 24px;

    cursor: pointer;

    transition: all 0.3s ease;
}

.close-btn:hover {
    background: #2563eb;

    transform: rotate(90deg);
}

/* Overlay */
.overlay {
    position: fixed;
    inset: 0;

    background: rgba(0,0,0,.45);

    backdrop-filter: blur(4px);

    opacity: 0;
    pointer-events: none;

    transition: 0.4s ease;

    z-index: 1250;
}

.overlay.show {
    opacity: 1;
    pointer-events: auto;
}
/* overlay */
.overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.25);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
  z-index: 1250;
}

.overlay.show {
  opacity: 1;
  pointer-events: auto;
}

/* ---------- Box layout for sections ---------- */
.box{
    background:#1e293b;
    border-radius:20px;
    box-shadow:0 15px 40px rgba(0,0,0,.35);
    margin:40px auto;
    padding:50px;
    width:min(1200px,92%);
    border:1px solid rgba(255,255,255,.05);
}

/* common headings */
h2 {
  color:white;
  font-size: 1.6rem;
  margin-bottom: 12px;
}

h2 span {
  color: #007bff;
}

/* ---------- Hero ---------- */
.hero-container{
    display:flex;
    align-items:center;
    justify-content:center;
    gap:70px;
    padding:70px 8%;
}

.hero-img{
    width:300px;
    height:300px;
    object-fit:cover;

    border-radius:30px;

    border:4px solid #3b82f6;

    box-shadow:
    0 0 25px rgba(59,130,246,.4),
    0 0 50px rgba(59,130,246,.2);

    transition:.4s;
}

.hero-img:hover{
    transform:scale(1.06) rotate(-2deg);
    box-shadow:
    0 0 40px rgba(59,130,246,.6),
    0 0 80px rgba(59,130,246,.4);
}

.hero-text h1{
    font-size:4rem;
    line-height:1.2;
    color:white;
}

.highlight{
    color:#3b82f6;
}

.typing-text{
    color:#60a5fa;
    font-size:1.5rem;
    font-weight:700;
    margin:15px 0;
}

.hero-text p{
    color:#cbd5e1;
    font-size:1.1rem;
    max-width:650px;
}

.hero{
    background:
        radial-gradient(circle at left center,
        rgba(59,130,246,.18) 0%,
        transparent 40%),
        #08122f;

    border-radius:30px;
}

/* buttons */
.buttons {
  margin-top: 18px;
}

.btn {
  display: inline-block;
  padding: 9px 18px;
  border-radius: 26px;
  border: 2px solid #007bff;
  color: #007bff;
  text-decoration: none;
  margin-right: 8px;
  transition: all 0.18s ease;
  background: transparent;
  font-weight: 600;
}

.btn.primary {
  background: #007bff;
  color: white;
  box-shadow: 0 8px 18px rgba(0, 123, 255, 0.12);
}

.btn:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 20px rgba(0, 123, 255, 0.12);
}

.hero-stats{
    display:flex;
    gap:40px;
    margin-top:30px;
}

.hero-stats h2{
    color:#3b82f6;
    margin:0;
}

.hero-stats p{
    color:#cbd5e1;
    margin:0;
}

/* ---------- About ---------- */
.about-content p {
  margin-bottom: 12px;
  font-size: 1rem;
  color: #333;
}
.about p{
    color: #e2e8f0;
    font-size: 1.05rem;
    line-height: 1.8;
}

.about{
    background:#172554;
    border:1px solid rgba(59,130,246,.15);
}

/* =========================
   SKILLS
========================= */
/* ==========================
   TECH STACK
========================== */

.tech-grid{
    display:flex;
    flex-wrap:wrap;
    justify-content:center;
    gap:20px;
    margin-top:30px;
}

.tech-card{
    width:180px;
    background:#111827;
    border:1px solid rgba(59,130,246,.2);
    border-radius:16px;
    padding:25px 15px;
    text-align:center;
    transition:0.3s ease;
}

.tech-card:hover{
    transform:translateY(-8px);
    border-color:#3b82f6;
    box-shadow:0 10px 25px rgba(59,130,246,.25);
}

.tech-card i{
    font-size:2.5rem;
    color:#3b82f6;
    margin-bottom:12px;
}

.tech-card p{
    color:white;
    font-weight:600;
    margin-top:10px;
}

.tech{
    background:#172554;
    border:1px solid rgba(59,130,246,.15);
}
/* ===== EXPERIENCE ===== */

/* =========================
   EXPERIENCE TIMELINE
========================= */

.timeline{
    position:relative;
    margin-top:40px;
}

.timeline::before{
    content:"";
    position:absolute;

    left:20px;
    top:0;

    width:3px;
    height:100%;

    background:#2563eb;
}

.timeline-item{
    position:relative;
    padding-left:60px;
    margin-bottom:40px;
}

.timeline-dot{
    position:absolute;

    left:10px;
    top:10px;

    width:22px;
    height:22px;

    background:#2563eb;
    border-radius:50%;
    border:4px solid white;
}

.timeline-content{
    background:#111827;
    padding:25px;
    border-radius:15px;
    transition:.3s;
}

.timeline-content:hover{
    transform:translateX(8px);
}

.timeline-content h3{
    color:white;
}

.timeline-content h4{
    color:#60a5fa;
    margin:8px 0;
}

.timeline-content span{
    color:#94a3b8;
    font-size:.9rem;
}

.timeline-content p{
    color:#cbd5e1;
    margin-top:12px;
}

/* ---------- Certifications ---------- */
.cert-grid-compact{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(250px,1fr));
    gap:20px;
    margin-top:30px;
}

.cert-card{
    background:#0f172a;

    border:1px solid rgba(59,130,246,.2);

    border-radius:18px;

    padding:25px;

    transition:.3s ease;

    text-align:center;
}

.cert-card:hover{
    transform:translateY(-8px);

    border-color:#3b82f6;

    box-shadow:
      0 10px 25px rgba(59,130,246,.25);
}

.cert-card h4{
    color:#fff;
    font-size:1rem;
    margin-top:10px;
    margin-bottom:8px;
}

.cert-card p{
    color:#94a3b8;
    font-size:.9rem;
}

.cert-icon{
    font-size:2.5rem;
    margin-bottom:10px;
}

/* ===================================
   PROJECTS SECTION
=================================== */
/* PROJECTS */

/* Projects Section */
.project-grid{
    display:grid;
    grid-template-columns:repeat(3, 1fr);
    gap:25px;
    margin-top:30px;
}

.project-card{
    background:#111827;
    border-radius:18px;
    overflow:hidden;
    border:1px solid rgba(59,130,246,.15);
    transition:.3s;
}

.project-card:hover{
    transform:translateY(-8px);
    box-shadow:0 15px 30px rgba(59,130,246,.2);
}

.project-card img{
    width:100%;
    height:220px;
    object-fit:cover;
    display:block;
}

.project-body{
    padding:20px;
}

.project-body h3{
    color:#fff;
    margin-bottom:10px;
}

.project-body p{
    color:#f6f7f8;
    line-height:1.6;
}

.tags{
    display:flex;
    flex-wrap:wrap;
    gap:10px;
    margin:18px 0;
}

.tags span{
    padding:8px 14px;
    background:rgba(59,130,246,.15);
    color:#60a5fa;
    border:1px solid rgba(59,130,246,.25);
    border-radius:30px;
    font-size:.85rem;
    font-weight:600;
}

.project-link{
    display:inline-block;
    padding:12px 22px;
    background:#3b82f6;
    color:white;
    text-decoration:none;
    border-radius:10px;
    font-weight:600;
}

.demo-link{
    display:inline-flex;
    align-items:center;
    gap:8px;
    padding:12px 18px;
    border:2px solid #3b82f6;
    color:#3b82f6;
    border-radius:12px;
    text-decoration:none;
    font-weight:600;
    white-space:nowrap;   /* Important */
    margin-left:10px;
    transition:.3s;
}

.demo-link:hover{
    background:#3b82f6;
    color:#fff;
    transform:translateY(-3px);
}

.project-metrics{
    display:flex;
    flex-wrap:wrap;
    gap:8px;
    margin:15px 0;
}

.project-metrics span{
    background:rgba(59,130,246,.15);
    color:#60a5fa;
    border:1px solid rgba(59,130,246,.3);
    padding:6px 12px;
    border-radius:20px;
    font-size:.8rem;
    font-weight:600;
}
/* ---------- Reveal animation ---------- */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.7s cubic-bezier(0.2, 0.9, 0.2, 1);
}

.reveal.active {
  opacity: 1;
  transform: none;
}

/* ---------- Responsive tweaks ---------- */
@media (max-width: 900px) {
  .hero-container {
    gap: 18px;
  }

  .hero-text {
    text-align: center;
  }

  .hero-img {
    width: 140px;
    height: 140px;
  }

  .topbar {
    padding: 10px 4%;
  }

  .box {
    padding: 32px 6%;
    margin: 32px auto;
  }
}

section h2{
    font-size: 1.8rem;
    font-weight: 800;
    text-align: left;
    margin-bottom: 15px;
    position: relative;
}

section h2 span{
    color: #3b82f6;
}

.subtitle{
    color: #e2e8f0;
    font-size: 1.1rem;
    text-align: left;
    margin-top: 10px;
    margin-bottom: 40px;
}

.contact p{
    color: #e2e8f0;
    font-size: 1.1rem;
    line-height: 1.8;
    text-align: left;
    margin: 20px 0 30px;
}

footer{
    color: #ffffff;
    text-align: left;
    padding: 20px;
    background: #0f172a;
    font-size: 16px;
}

footer span{
    color:#3b82f6;
    font-weight:600;
}

.achievement-grid{
    display:grid;
    grid-template-columns:repeat(4,1fr);
    gap:20px;
    margin-top:30px;
}

.achievement-card{
    background:#111827;
    border:1px solid rgba(59,130,246,.2);
    border-radius:18px;
    padding:25px;
    text-align:center;
    transition:.3s;
}

.achievement-card:hover{
    transform:translateY(-8px);
    box-shadow:0 15px 30px rgba(59,130,246,.15);
}

.achievement-card h3{
    color:#3b82f6;
    font-size:2rem;
    margin-bottom:10px;
}

.achievement-card p{
    color:#e2e8f0;
}

/* =========================
   MOBILE RESPONSIVE DESIGN
========================= */

@media (max-width: 768px) {

    /* Hero Section */
    .hero-container{
        flex-direction: column;
        text-align: center;
        gap: 30px;
    }

    .hero-image{
        width: 220px;
        height: 220px;
        margin: auto;
    }

    .hero-text h1{
        font-size: 2.2rem;
        line-height: 1.2;
    }

    .hero-text p{
        font-size: 1rem;
    }

    /* Buttons */
    .buttons{
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }

    .buttons .btn{
        width: 220px;
        text-align: center;
    }

    /* Stats */
    .stats{
        justify-content: center;
        gap: 30px;
    }

    /* Skills */
    .skills-grid{
        grid-template-columns: repeat(2,1fr);
    }

    /* Projects */
    .project-grid{
        grid-template-columns: 1fr;
    }

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

    .project-buttons{
        flex-direction: column;
    }

    .project-link,
    .demo-link{
        width: 100%;
        text-align: center;
        justify-content: center;
    }

    /* Certificates */
    .cert-grid{
        grid-template-columns: 1fr;
    }

    /* Experience */
    .experience-card{
        padding: 20px;
    }

    /* Contact */
    .contact-buttons{
        flex-direction: column;
        align-items: center;
    }

    /* Titles */
    h2{
        font-size: 2rem;
        text-align: center;
    }

    .subtitle{
        text-align: center;
    }

    /* Boxes */
    .box{
        padding: 25px;
    }
}

@media (max-width:768px){

    .topbar{
        padding: 15px 20px;
    }

    .logo{
        font-size: 1rem;
    }

    .social-icons{
        display:none;
    }

}