/* ----------
   Base / Theme
---------- */
:root {
  --bg: #0b0f14;
  --surface: rgba(255,255,255,0.04);
  --surface-2: rgba(255,255,255,0.06);
  --text: #e6ecf1;
  --muted: #99a8b2;
  --accent: #00e5ff;
  --accent-2: #8a5cff;
  --ring: 0 0 0 2px rgba(0,229,255,0.35);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, Noto Sans, sans-serif;
  background: radial-gradient(1200px 600px at 10% -10%, rgba(138,92,255,0.15), transparent),
              radial-gradient(900px 500px at 90% 120%, rgba(0,229,255,0.12), transparent),
              var(--bg);
  color: var(--text);
  line-height: 1.6;
}

.container { width: min(1100px, 92%); margin: 0 auto; }

/* ----------
   Header / Nav
---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(11,15,20,0.75);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; padding: 0.8rem 0; }
.brand {
  font-family: "Space Grotesk", Inter, sans-serif;
  letter-spacing: 1px;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: .5rem;
}
.brand::after {
  content: "";
  width: 8px; height: 8px; border-radius: 999px; background: linear-gradient(45deg, var(--accent), var(--accent-2));
  box-shadow: 0 0 12px var(--accent);
}

/* Nav */
.nav-toggle {
  display: none;
  background: transparent;
  border: 0;
  cursor: pointer;
}
.nav-toggle-bar { display: block; width: 24px; height: 2px; background: var(--text); margin: 5px 0; }

.nav-menu { display: flex; gap: 1rem; list-style: none; margin: 0; padding: 0; }
.nav-menu a {
  color: var(--text);
  text-decoration: none;
  padding: .5rem .8rem;
  border-radius: 10px;
}
.nav-menu a:hover, .nav-menu a:focus { outline: none; box-shadow: var(--ring); }
.nav-menu a.active {
  background: rgba(102,204,255,0.1);
  color: #66ccff;
  border: 1px solid rgba(102,204,255,0.3);
}
.nav-menu .cta-link {
  background: linear-gradient(45deg, rgba(0,229,255,0.15), rgba(138,92,255,0.15));
  border: 1px solid rgba(255,255,255,0.1);
}

/* ----------
   Sections
---------- */
.section { padding: clamp(20px, 8vw, 80px) 0; }
.section.alt { background: linear-gradient(0deg, rgba(255,255,255,0.03), rgba(255,255,255,0.03)); }
.section-title {
  font-family: "Space Grotesk", Inter, sans-serif;
  font-weight: 700;
  font-size: clamp(1.6rem, 2.2vw, 2.2rem);
  margin: 0 0 1.2rem 0;
}

/* Hero */
.hero { position: relative; overflow: hidden; }
#hero-canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-inner {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 80px 0 60px;
}
/* Updated hero fonts and styles */
.hero-title {
  font-family: 'Sora', sans-serif;
  font-weight: 700;
  letter-spacing: -0.5px;
  font-size: clamp(2.4rem, 5vw, 3.75rem);
  color: #ffffff;
  text-shadow: 0 0 22px rgba(110,190,255,0.25);
}

.hero-subtitle {
  font-family: 'Inter', sans-serif;
  font-weight: 400;
  opacity: 0.88;
  font-size: clamp(1.05rem, 2vw, 1.25rem);
}

.hero-badges { display: flex; flex-wrap: wrap; gap: .6rem; justify-content: center; margin-bottom: 1.2rem; }
.hero-badges span {
  background: var(--surface);
  border: 1px solid rgba(255,255,255,0.08);
  padding: .35rem .6rem;
  border-radius: 6px;
  font-family: 'Inter', sans-serif;
  font-size: .9rem;
}
.hero-ctas { display: flex; gap: .8rem; justify-content: center; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .4rem;
  padding: .7rem 1rem;
  border-radius: 12px;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid rgba(255,255,255,0.12);
  color: var(--text);
}
.btn-primary {
  background: linear-gradient(45deg, var(--accent), var(--accent-2));
  border: 0;
}
.btn-ghost { background: var(--surface); }
.btn:hover, .btn:focus { box-shadow: var(--ring); outline: none; }

/* Cards */
.cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}
.card {
  background: var(--surface);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 16px;
  padding: 1rem;
  transition: transform .2s ease, box-shadow .2s ease;
}
.card:hover { transform: translateY(-2px); box-shadow: 0 8px 28px rgba(0,0,0,0.25); }

/* Projects */
.project {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 1.4rem;
  margin-bottom: 2rem;
  width: 200%;
  max-width: var(--container-width, 1100px);
  margin-left: auto;
  margin-right: auto;
}
.project-media img {
  width: 200%;
  height: auto;
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,0.1);
  background: #0e1319;
}
.pill-list { display: flex; flex-wrap: wrap; gap: .5rem; margin: .6rem 0 1rem; padding: 0; list-style: none; }
.pill-list li {
  background: var(--surface-2);
  padding: .35rem .6rem;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.08);
  font-size: .9rem;
}

/* Publications */
.pub-list { list-style: none; padding: 0; margin: 0; }
.pub-list li { background: var(--surface); border: 1px solid rgba(255,255,255,0.08); border-radius: 12px; padding: .9rem; margin-bottom: .7rem; }
.muted { color: var(--muted); font-size: .95rem; }

/* Timeline */
.timeline { display: grid; gap: 1rem; }
.timeline-item {
  background: var(--surface);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  padding: 1rem;
}
.timeline-meta { color: var(--muted); margin-top: -0.4rem; }

/* ----------------------------- */
/* CORE COMPETENCIES – ENHANCED  */
/* ----------------------------- */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 2rem;
  justify-items: center;
  align-items: stretch;
  padding: 1rem 0;
}

.skill {
  position: relative;
  background: linear-gradient(145deg, rgba(20, 25, 30, 0.95), rgba(10, 12, 15, 0.9));
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  padding: 2rem 1rem;
  text-align: center;
  width: 100%;
  max-width: 220px;
  transition: all 0.4s ease;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.3);
  overflow: hidden;
}

.skill::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(102, 204, 255, 0.08) 0%, transparent 70%);
  transform: rotate(25deg);
  opacity: 0;
  transition: opacity 0.5s ease;
}

.skill:hover::before {
  opacity: 1;
}

.skill:hover {
  transform: translateY(-8px) scale(1.03);
  border-color: rgba(102, 204, 255, 0.5);
  box-shadow: 0 0 25px rgba(102, 204, 255, 0.3);
}

.skill i {
  font-size: 3.2rem;
  color: #66ccff;
  margin-bottom: 0.8rem;
  display: block;
  text-shadow: 0 0 10px rgba(102, 204, 255, 0.5);
  transition: transform 0.4s ease;
}

.skill:hover i {
  transform: scale(1.15) rotate(3deg);
}

.skill span {
  display: block;
  color: #f0f4f8;
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  margin-top: 0.2rem;
}

/* ===== EXPERIENCE TABS ===== */
#experience .xp-tabs { margin-top: 0; }

/* Tab bar */
#experience .xp-tablist {
  display: flex;
  gap: .5rem;
  flex-wrap: wrap;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  padding-bottom: .5rem;
  margin-bottom: 1rem;
  overflow-x: auto;
  scrollbar-width: thin;
}
#experience .xp-tab {
  appearance: none;
  background: linear-gradient(145deg, rgba(20,25,30,.95), rgba(10,12,15,.9));
  border: 1px solid rgba(255,255,255,0.08);
  border-bottom: none;
  border-radius: 10px 10px 0 0;
  color: #dfe7f0;
  padding: .6rem .9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all .25s ease;
  white-space: nowrap;
}
#experience .xp-tab:hover { border-color: rgba(102,204,255,.45); }
#experience .xp-tab.is-active {
  color: #8fb8ff;
  border-color: rgba(102,204,255,.5);
  box-shadow: 0 0 12px rgba(102,204,255,.22);
}

/* Panels */
#experience .xp-panel[hidden] { display: none !important; }
#experience .xp-panel.is-active { display: block; }

#experience .xp-card {
  background: linear-gradient(145deg, rgba(20,25,30,.95), rgba(10,12,15,.9));
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 0 12px 12px 12px; /* attached to the active tab */
  padding: 1.25rem 1.25rem 1rem;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
#experience .xp-card:hover {
  transform: translateY(-2px);
  border-color: rgba(102,204,255,.45);
  box-shadow: 0 0 20px rgba(102,204,255,.18);
}

#experience .xp-header {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: .25rem .75rem;
  align-items: baseline;
  margin-bottom: .5rem;
}
#experience .xp-header h3 { margin: 0; font-size: 1.1rem; letter-spacing: .02em; }
#experience .xp-org { color: #a9b6c2; font-size: .95rem; }
#experience .xp-dates { color: #8fb8ff; font-weight: 600; font-size: .9rem; }

#experience .xp-points { margin: .25rem 0 0 1.1rem; padding: 0; display: grid; gap: .4rem; list-style: disc; }


/* Contact */
.contact-form { max-width: 620px; }
.form-row { display: grid; gap: .4rem; margin-bottom: .9rem; }
input, textarea {
  background: #0e141a;
  color: var(--text);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 12px;
  padding: .75rem .9rem;
  font: inherit;
}
input:focus, textarea:focus { outline: none; box-shadow: var(--ring); }
.form-actions { margin-top: .6rem; }
.form-note { color: var(--muted); font-size: .9rem; margin-top: .6rem; }

/* Footer */
.site-footer { border-top: 1px solid rgba(255,255,255,0.07); padding: 1.2rem 0; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.back-to-top {
  text-decoration: none; color: var(--text);
  background: var(--surface);
  border: 1px solid rgba(255,255,255,0.1);
  padding: .4rem .6rem; border-radius: 10px;
}

/* ----------
   Responsive
---------- */
@media (max-width: 980px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .project { grid-template-columns: 1fr; }
  .skill-grid { grid-template-columns: repeat(2, 1fr); }
  .nav-toggle { display: inline-block; }
  .nav-menu {
    position: absolute;
    right: 4%;
    top: 60px;
    display: none;
    flex-direction: column;
    background: rgba(11,15,20,0.95);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 12px;
    padding: .6rem;
  }
  .nav-menu.open { display: flex; }
}
@media (max-width: 580px) {
  .cards { grid-template-columns: 1fr; }
  .skill-grid { grid-template-columns: 1fr; }
}

/* ... previous CSS for .skill and hover effects ... */

/* ---------------------------------------------- */
/* UNIFORM LOGO SIZING FOR CORE COMPETENCIES ICONS */
/* ---------------------------------------------- */

.skill img,
.skill svg {
  display: block;
  margin: 0 auto 0.6rem auto;
  width: 3rem;              /* ~48px Devicon size */
  height: 3rem;
  object-fit: contain;
  filter: drop-shadow(0 0 6px rgba(102, 204, 255, 0.3));
  transition: transform 0.3s ease, filter 0.3s ease;
}

.skill:hover img,
.skill:hover svg {
  transform: scale(1.15);
  filter: drop-shadow(0 0 10px rgba(102, 204, 255, 0.6));
}

.skill span {
  margin-top: 0.4rem;
}

/* Ensure projects uses the same container width and full-bleed child widths */
#projects .container { width: min(1100px, 92%); margin: 0 auto; }
#projects .project { width: 100%; }
#projects .project-media img { max-width: 100%; width: 100%; height: auto; display: block; }

/* Safety reset if a rogue margin is shrinking the section */
#projects { margin-left: 0; margin-right: 0; }


/* If a label MUST wrap on tiny screens, relax nowrap below 420px */
@media (max-width: 420px) {
  #core-competencies .skill span { white-space: normal; }
}


/* ===== EDUCATION WITH LOGOS ===== */
.edu-card {
  background: linear-gradient(145deg, rgba(20,25,30,.95), rgba(10,12,15,.9));
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 16px;
  padding: 1.1rem 1.2rem 1rem;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
  margin-bottom: 1rem;
}
.edu-card:hover {
  transform: translateY(-2px);
  border-color: rgba(102,204,255,.45);
  box-shadow: 0 0 18px rgba(102,204,255,.22);
}

/* Header layout (logo + text) */
.edu-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: .75rem;
}
.edu-logo {
  width: 56px;
  height: auto;
  flex-shrink: 0;
  border-radius: 8px;
  object-fit: contain;
  background: rgba(255,255,255,0.05);
  padding: .25rem;
  box-shadow: 0 0 6px rgba(102,204,255,.25);
}

/* Typography */
.edu-card h3 { margin: 0 0 .25rem; font-size: 1.15rem; }
.edu-card .timeline-meta { color: #a9b6c2; margin: .1rem 0 .6rem; font-size: .95rem; }

/* Pills */
.edu-card .pill-list { margin: .6rem 0 0; display: flex; flex-wrap: wrap; gap: .4rem; }
.edu-card .pill-list li {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 20px;
  padding: .3rem .75rem;
  font-size: .85rem;
  white-space: nowrap;
}

