/* ========================================
   1. ROOT VARIABLES & GLOBAL RESET
   ======================================== */
:root {
  --bg: #0b1220;
  --panel: #0f1724;
  --muted: #9aa8bf;
  --accent: #7c3aed;
  --glass: rgba(255, 255, 255, 0.03);
  --card-radius: 14px;
  --maxw: 1100px;
  --pad: 24px;
  --ff: Inter, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html, body {
  height: 100%;
  margin: 0;
  padding: 0;
}

body {
  background: linear-gradient(180deg, #071025 0%, #071727 100%);
  color: #e6eef8;
  font-family: var(--ff);
  font-size: 16px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ========================================
   2. LAYOUT: .wrap (page container)
   ======================================== */
.wrap {
  display: grid;
  gap: 28px;
  grid-template-columns: 380px 1fr;
  margin: 32px auto;
  max-width: var(--maxw);
  padding: 0 18px; /* mobile safety */
  min-height: calc(100vh - 120px); /* Leave space for footer */
}

/* Desktop: 40px left gap (your preference) */
@media (min-width: 1200px) {
  .wrap {
    margin-left: 30px;
    margin-right: auto;
    padding-left: 0;
  }
}

/* ========================================
   3. SIDEBAR
   ======================================== */
.sidebar {
  background-color: #0a101b;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--card-radius);
  box-shadow:
    inset 0 0 20px rgba(0, 0, 0, 0.3),
    0 8px 24px rgba(0, 0, 0, 0.4),
    0 0 0 1px rgba(255, 255, 255, 0.05);
  margin-left: 0;
  min-height: calc(100vh - 64px);
  padding: var(--pad);
  position: sticky;
  top: 24px;
  align-self: flex-start; /* ← Prevents stretching */
  z-index: 10;   /* ← Above content */
}

/* Avatar */
.avatar {
  background: linear-gradient(135deg, #18283b, #0b2540);
  border: 3px solid rgba(124, 58, 237, 0.14);
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 300px;
  margin: 0 0 24px 12px;
  overflow: hidden;
  width: 300px;
}

.avatar img {
  display: block;
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.avatar.small {
  font-size: 0.85rem;
  height: 48px;
  width: 48px;
}

.meta {
  text-align: center;
  margin-bottom: 20px;
}

/* Name & Title */
.name {
  font-size: 1.35rem;
  font-weight: 800;
  margin: 0 0 4px;
}

.title {
  color: var(--muted);
  font-size: 1rem;
  margin-bottom: 16px;
}

/* Contact List */
.contact-list {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  list-style: none;
  margin: 24px 0 0;
  padding: 0;
}

.contact-list li {
  align-items: center;
  color: var(--muted);
  display: flex;
  font-size: 0.98rem;
  gap: 12px;
}

.contact-list a {
  color: inherit;
  text-decoration: none;
}

.icon {
  width: 20px;
  height: 20px;
  fill: #8b8b8b;           /* ← Visible gray */
  flex-shrink: 0;
  transition: fill 0.3s ease;
}

/* Hover effect */
.contact-list li:hover .icon {
  fill: var(--accent);     /* ← Purple on hover */
}

/* Social Chips */
.socials {
  display: flex;
  gap: 12px;
  margin-top: 28px;
  flex-wrap: wrap;
  justify-content: center;
}

.chip {
  background: rgba(255, 255, 255, 0.02);
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
  padding: 8px 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.3s ease;
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.chip:hover {
  background: rgba(124, 58, 237, 0.15);
  color: #fff;
  border-color: rgba(124, 58, 237, 0.4);
}

.chip-icon {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

/* ========================================
   4. MAIN CONTENT
   ======================================== */
.main {
  background: transparent;
  padding: 0;
}

/* Top Navigation Bar */
.topbar {
  align-items: center;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  margin-bottom: 10px;
}

.nav {
  display: flex;
  gap: 12px;
}

.nav a {
  border-radius: 10px;
  color: var(--muted);
  font-weight: 700;
  padding: 8px 12px;
  text-decoration: none;
}

.nav a:hover,
.nav a.active {
  background: var(--glass);
  color: #fff;
}

/* About Section */
.about {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.01), rgba(255, 255, 255, 0.005));
  border: 1px solid var(--glass);
  border-radius: 12px;
  margin-bottom: 18px;
  padding: 20px;
}

.about h1 {
  font-size: 1.4rem;
  margin: 0 0 10px;
}

/* What I'm Doing Grid */
.doing-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, 1fr);
}

.card {
  background: rgba(255, 255, 255, 0.015);
  border: 1px solid var(--glass);
  border-radius: 12px;
  padding: 16px;
}

.card h3 {
  font-size: 1rem;
  margin: 0 0 8px;
}

.card p {
  color: var(--muted);
  font-size: 0.95rem;
  margin: 0;
}

/* Mobile Header */
.mobile-header {
  align-items: center;
  display: none;
  gap: 12px;
  justify-content: space-between;
  margin-bottom: 12px;
}

.mobile-left {
  align-items: center;
  display: flex;
  gap: 12px;
}

.hambtn {
  background: transparent;
  border: 1px solid var(--glass);
  border-radius: 10px;
  color: var(--muted);
  padding: 8px 12px;
}

/* ========================================
   PERSONAL JOURNEY - HUMAN & RELATABLE
   ======================================== */
.personal-journey {
  margin-top: 0px;
  padding: 40px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.personal-journey h2 {
  font-size: 2rem;
  margin-bottom: 12px;
  background: linear-gradient(90deg, #fff, var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.journey-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin: 32px 0;
}

.journey-card {
  background: rgba(255, 255, 255, 0.015);
  border: 1px solid var(--glass);
  border-radius: 16px;
  padding: 24px;
  transition: all 0.3s ease;
  backdrop-filter: blur(8px);
}

.journey-card:hover {
  transform: translateY(-6px);
  border-color: rgba(124, 58, 237, 0.4);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.3);
}

.journey-icon {
  font-size: 2.2rem;
  margin-bottom: 16px;
  display: block;
}

.youtube .open-source-badge {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
  font-size: 0.9rem;
  color: #10b981;
  font-weight: 600;
}

.youtube .open-source-badge .badge-icon {
  width: 16px;
  height: 16px;
  fill: #10b981;
  flex-shrink: 0;
}

/* Hover */
.journey-card.youtube:hover .open-source-badge {
  color: #34d399;
}

.journey-card.youtube:hover .open-source-badge .badge-icon {
  fill: #34d399;
}

/* YouTube Preview */
.youtube-preview {
  display: flex;
  gap: 16px;
  margin: 16px 0;
  align-items: flex-start;
}

.youtube-thumb {
  width: 80px;
  height: 80px;
  border-radius: 12px;
  object-fit: cover;
  border: 2px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  flex-shrink: 0;
}

.youtube-info {
  flex: 1;
}

.youtube-info p {
  margin: 0 0 8px;
  font-size: 0.92rem;
  line-height: 1.5;
}

.youtube-info p:last-child {
  margin-bottom: 0;
}

/* Medium Preview */
.medium-preview {
  display: flex;
  gap: 16px;
  margin: 16px 0;
  align-items: center;
}

.medium-logo {
  width: 48px;
  height: 48px;
  filter: brightness(0) invert(1);
  opacity: 0.9;
}

.medium-info {
  flex: 1;
}

.medium-info p {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.5;
}

@media (max-width: 600px) {
  .youtube-preview, .medium-preview {
    flex-direction: column;
    align-items: flex-start;
  }
  .youtube-thumb { width: 64px; height: 64px; }
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--accent);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  padding: 8px 16px;
  border: 1px solid rgba(124, 58, 237, 0.3);
  border-radius: 999px;
  transition: all 0.3s ease;
}

.btn-outline:hover {
  background: rgba(124, 58, 237, 0.15);
  color: #fff;
  border-color: var(--accent);
}

.btn-outline svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

.project-list li strong {
  display: block;
  margin-bottom: 6px;
  font-size: 1.05rem;
  color: #fff;
}

.project-desc {
  font-size: 0.88rem;
  line-height: 1.5;
  color: var(--muted);
  display: block;
  margin-top: 4px;
}

.project-list li {
  padding: 14px 0;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.1);
}

.project-list li:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.project-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  color: var(--accent);
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  padding: 6px 12px;
  border: 1px solid rgba(124, 58, 237, 0.3);
  border-radius: 999px;
  transition: all 0.3s ease;
  backdrop-filter: blur(4px);
}

.project-link:hover {
  background: rgba(124, 58, 237, 0.15);
  color: #fff;
  border-color: var(--accent);
  transform: translateY(-1px);
}

.project-link svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

/* MCA Showcase */
.mca-showcase {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--glass);
  border-radius: 20px;
  padding: 32px;
  margin-top: 48px;
  gap: 32px;
  flex-wrap: wrap;
}

.mca-text h3 {
  margin: 0 0 8px;
  font-size: 1.5rem;
}

.mca-text p {
  margin: 4px 0;
}

.mca-photo {
  width: 220px;
  height: 220px;
  object-fit: cover;
  border-radius: 16px;
  border: 3px solid rgba(124, 58, 237, 0.4);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
  transition: transform 0.3s ease;
}

.mca-photo:hover {
  transform: scale(1.05);
}

/* Responsive */
@media (max-width: 900px) {
  .mca-showcase {
    flex-direction: column;
    text-align: center;
  }
  .mca-photo {
    width: 180px;
    height: 180px;
  }
}

/* Footer */
.footer {
  color: var(--muted);
  margin-top: 18px;
  text-align: center;
}

/* ========================================
   5. UTILITIES & TEXT
   ======================================== */
.muted {
  color: var(--muted);
}

.mt {
  margin-top: 12px;
}

.mt-2 {
  margin-top: 20px;
}

/* ========================================
   6. RESPONSIVE BREAKPOINTS
   ======================================== */

/* Tablet & Mobile */
@media (max-width: 900px) {
  .wrap {
    grid-template-columns: 1fr;
    gap: 18px;
    margin: 18px auto;
  }

  .sidebar {
    margin-left: 0;
    position: fixed;
    top: auto;
  }

  .mobile-header {
    display: flex;
  }

  .topbar {
    display: none;
  }
}

/* Small Mobile */
@media (max-width: 520px) {
  .doing-grid {
    grid-template-columns: 1fr;
  }

  .avatar {
    height: 96px;
    width: 96px;
  }

  body {
    font-size: 15px;
  }
}


/* ========================================
   SOFT SKILLS - HORIZONTAL BARS
   ======================================== */
.soft-skills {
  display: flex;
  flex-direction: column;
  gap: 18px;
  max-width: 600px;
}

.skill-item {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.skill-label {
  display: flex;
  justify-content: space-between;
  font-size: 0.95rem;
  font-weight: 600;
  color: #fff;
}

.skill-percent {
  color: var(--accent);
  font-weight: 700;
}

.skill-bar {
  height: 10px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  overflow: hidden;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3);
}

.skill-fill {
  height: 100%;
  border-radius: 999px;
  transition: width 1.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 0 12px rgba(124, 58, 237, 0.4);
  position: relative;
}

.skill-fill::after {
  content: '';
  position: absolute;
  top: 0; right: 0; bottom: 0; left: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  border-radius: 999px;
  animation: shimmer 2s infinite;
}

@keyframes shimmer {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

/* Animate on load */
.skill-fill {
  width: 0 !important;
}

.skill-item.visible .skill-fill {
  width: var(--target-width, 90%) !important;
}

/* Responsive */
@media (max-width: 768px) {
  .soft-skills {
    max-width: 100%;
  }
}

/* ========================================
   7. RESUME TIMELINE
   ======================================== */
.resume h2 {
  margin-bottom: 24px;
}

.timeline {
  position: relative;
  padding-left: 40px;
  margin: 40px 0;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 16px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--accent), transparent);
  z-index: 1px;
}

.timeline-item {
  position: relative;
  margin-bottom: 40px;
  display: flex;
  align-items: flex-start;
  gap: 20px;
}

.timeline-item::before {
  content: attr(data-year);
  position: absolute;
  left: -100px;
  top: 4px;
  font-size: 0.9rem;
  color: var(--accent);
  font-weight: 600;
  width: 90px;
  text-align: right;
}

.timeline-dot {
  position: absolute;
  left: -40px;
  top: 6px;
  width: 16px;
  height: 16px;
  background: var(--accent);
  border: 4px solid #0a101b;
  border-radius: 50%;
  z-index: 2;
  box-shadow: 0 0 0 4px rgba(124, 58, 237, 0.3);
  transition: all 0.3s ease;
}

.timeline-content {
  flex: 1;
  background: rgba(255, 255, 255, 0.015);
  border: 1px solid var(--glass);
  border-radius: 16px;
  padding: 20px;
  backdrop-filter: blur(8px);
  transition: all 0.3s ease;
  min-width: 0;
}

.timeline-date {
  position: absolute;
  top: -28px;
  left: 20px;
  font-size: 0.8rem;
  color: var(--accent);
  font-weight: 600;
  background: #0a101b;
  padding: 0 8px;
}

.timeline-content:hover {
  transform: translateY(-4px);
  border-color: rgba(124, 58, 237, 0.4);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.3);
}

.timeline-content h3 {
  margin: 0 0 6px;
  font-size: 1.25rem;
  color: #fff;
}

.timeline-content h4 {
  margin: 0 0 8px;
  font-size: 0.95rem;
}



.timeline-content p {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.6;
  color: #ccc;
}

/* Hover Effect */
.timeline-item:hover .timeline-dot {
  transform: scale(1.3);
}

.timeline-item:hover .timeline-content {
  background: rgba(255, 255, 255, 0.03);
  border-color: rgba(124, 58, 237, 0.3);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Mobile: Stack timeline */
@media (max-width: 900px) {
  .timeline {
    padding-left: 20px;
  }

  .timeline::before {
    left: 8px;
  }

  .timeline-item::before {
    left: -80px;
    width: 70px;
    font-size: 0.85rem;
  }

  .timeline-dot {
    left: -29px;
  }

  .timeline-item {
    flex-direction: column;
    gap: 8px;
  }
}

@media (max-width: 520px) {
  .timeline-item::before {
    position: static;
    text-align: left;
    margin-bottom: 4px;
    width: auto;
  }

  .timeline {
    padding-left: 0;
  }

  .timeline::before {
    display: none;
  }

  .timeline-dot {
    position: static;
    margin-bottom: 8px;
  }

  .timeline-item {
    border-left: 3px solid var(--accent);
    padding-left: 16px;
    margin-left: 12px;
  }
}

/* ========================================
   CERTIFICATIONS & WORKSHOPS
   ======================================== */
.cert-grid,
.workshop-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  margin-top: 16px;
}

.cert-card,
.workshop-card {
  background: rgba(255, 255, 255, 0.015);
  border: 1px solid var(--glass);
  border-radius: 16px;
  padding: 20px;
  transition: all 0.3s ease;
  backdrop-filter: blur(8px);
  position: relative;
  overflow: hidden;
}

.cert-card::before,
.workshop-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(135deg, rgba(124, 58, 237, 0.1), transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.cert-card:hover::before,
.workshop-card:hover::before {
  opacity: 1;
}

.cert-card:hover,
.workshop-card:hover {
  transform: translateY(-6px);
  border-color: rgba(124, 58, 237, 0.5);
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.3);
}

.cert-icon,
.workshop-icon {
  font-size: 1.8rem;
  margin-bottom: 12px;
  display: block;
  background: linear-gradient(90deg, var(--accent), #a78bfa);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.cert-card h4,
.workshop-card h4 {
  margin: 0 0 8px;
  font-size: 1.1rem;
  color: #fff;
  font-weight: 600;
}

.cert-issuer,
.workshop-venue {
  margin: 0;
  font-size: 0.92rem;
  color: var(--muted);
  line-height: 1.5;
}

/* Responsive */
@media (max-width: 768px) {
  .cert-grid,
  .workshop-grid {
    grid-template-columns: 1fr;
  }
}

/* ========================================
   CODING PROGRESS - HACKERRANK, LEETCODE & GitHub Stats
   ======================================== */
.coding-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 24px;
  margin-top: 20px;
}

.platform-card {
  background: rgba(255, 255, 255, 0.015);
  border: 1px solid var(--glass);
  border-radius: 20px;
  padding: 24px;
  backdrop-filter: blur(10px);
  transition: all 0.4s ease;
  position: relative;
  overflow: hidden;
}

.platform-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(135deg, rgba(124, 58, 237, 0.08), transparent);
  opacity: 0;
  transition: opacity 0.4s ease;
}

.platform-card:hover::before {
  opacity: 1;
}

.platform-card:hover {
  transform: translateY(-8px);
  border-color: rgba(124, 58, 237, 0.6);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.platform-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.platform-header img {
  height: 32px;
  border-radius: 6px;
}

.badge {
  background: rgba(124, 58, 237, 0.2);
  color: var(--accent);
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
  border: 1px solid rgba(124, 58, 237, 0.4);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 20px;
}

.stat-item {
  text-align: center;
}

.stat-value {
  font-size: 1.4rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 4px;
}

.stat-label {
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.3;
}

.progress-ring {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-top: 16px;
}

.ring-fill {
  transform: rotate(-90deg);
  transform-origin: 50% 50%;
  transition: stroke-dashoffset 1.5s cubic-bezier(0.4, 0, 0.2, 1);
  stroke-linecap: round;
}

.progress-ring text {
  font-family: inherit;
  dominant-baseline: middle;
}

.ring-label {
  margin-top: 8px;
  font-size: 0.9rem;
  color: var(--muted);
  font-weight: 500;
}

/* Animate on load */
.platform-card {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 0.6s ease forwards;
}

.platform-card:nth-child(1) { animation-delay: 0.1s; }
.platform-card:nth-child(2) { animation-delay: 0.2s; }

@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive */
@media (max-width: 768px) {
  .coding-stats {
    grid-template-columns: 1fr;
  }
  .stats-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .stat-item {
    text-align: left;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }
}

/* ========================================
   GITHUB STATS CARDS
   ======================================== */
.github-stats {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.github-images {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 8px;
}

.github-card {
  width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges;
}

.github-card:hover {
  transform: scale(1.02);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

/* Responsive: Stack all on mobile */
@media (max-width: 900px) {
  .coding-stats {
    grid-template-columns: 1fr;
  }
  .github-stats {
    order: 3;
  }
}

@media (max-width: 480px) {
  .stats-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .stat-item {
    justify-content: center;
    gap: 8px;
  }
}



/* ========================================
   8. TAB SYSTEM
   ======================================== */
.tab-panels {
  margin-top: 24px;
}

.tab-content {
  display: none;
  animation: fadeIn 0.4s ease forwards;
}

.tab-content.active {
  display: block;
}

/* Fade-in animation */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Optional: Smooth height transition */
.tab-content > * {
  overflow: hidden;
}

/* ========================================
   9. PORTFOLIO GRID & HOVER VIDEO
   ======================================== */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin-top: 20px;
}

.project-card {
  background: rgba(255, 255, 255, 0.015);
  border: 1px solid var(--glass);
  border-radius: 14px;
  overflow: hidden;
  transition: all 0.3s ease;
  position: relative;
  max-width: 360px;
  margin: 0 auto;
}

.project-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.3);
  border-color: rgba(124, 58, 237, 0.3);
}

.project-thumb {
  position: relative;
  cursor: pointer;
  overflow: hidden;
  border-radius: 16px;
}

/* ========================================
   THUMBNAIL TOOLTIP
   ======================================== */
.thumb-wrapper {
  position: relative;
  display: block;
  cursor: pointer;
  border-radius: 16px;
  overflow: hidden;
}

.thumb-wrapper::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.8);
  color: white;
  font-size: 0.8rem;
  font-weight: 500;
  padding: 6px 12px;
  border-radius: 8px;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  pointer-events: none;
  z-index: 10;
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.thumb-wrapper::before {
  content: "";
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-top-color: rgba(0, 0, 0, 0.8);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  z-index: 10;
}

.thumb-wrapper:hover::after,
.thumb-wrapper:hover::before {
  opacity: 1;
  visibility: visible;
  bottom: 16px;
}

.thumb-wrapper:hover::before {
  bottom: 10px;
}

/* Mobile: Show tooltip on tap (optional) */
@media (max-width: 768px) {
  .thumb-wrapper::after,
  .thumb-wrapper::before {
    display: none; /* Or keep if you want tap-to-show */
  }
}

.project-thumb img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  transition: 0.3s ease;
}

.video-preview {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: #000;
  opacity: 0;
  visibility: hidden;
  transition: 0.4s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.video-preview iframe {
  width: 100%;
  height: 100%;
  border: none;
}

.project-card.video-active .video-preview {
  opacity: 1;
  visibility: visible;
}

.project-card.video-active .project-thumb img {
  opacity: 0;
}

.project-info {
  padding: 18px;
}

.project-info h3 {
  margin: 0 0 6px;
  font-size: 1.15rem;
  color: #fff;
}

.project-info p {
  margin: 0 0 12px;
  font-size: 0.92rem;
  line-height: 1.5;
}

.project-links {
  display: flex;
  gap: 10px;
}

.btn-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  transition: all 0.2s ease;
}

.btn-icon svg {
  width: 18px;
  height: 18px;
  fill: var(--muted);
}

.btn-icon:hover {
  background: var(--accent);
  transform: translateY(-2px);
}

.btn-icon:hover svg {
  fill: #fff;
}

.btn-icon.live:hover {
  background: #10b981;
}

/* Mobile */
@media (max-width: 900px) {
  .portfolio-grid {
    grid-template-columns: 1fr;
  }
}

/* ========================================
   10. BLOG GRID
   ======================================== */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
  margin-top: 20px;
}

.blog-card {
  max-width: 360px;
  margin: 0 auto; /* centers card if alone in row */
  background: rgba(255, 255, 255, 0.015);
  border: 1px solid var(--glass);
  border-radius: 14px;
  overflow: hidden;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
}

.blog-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.25);
  border-color: rgba(124, 58, 237, 0.3);
}

.blog-thumb {
  height: 300px;
  overflow: hidden;
}

.blog-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.blog-card:hover .blog-thumb img {
  transform: scale(1.05);
}

.blog-info {
  padding: 18px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.blog-info h3 {
  margin: 0 0 8px;
  font-size: 1.1rem;
  color: #fff;
  line-height: 1.3;
}

.blog-info p {
  margin: 0 0 16px;
  font-size: 0.92rem;
  flex-grow: 1;
}

.btn-read {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--accent);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  margin-top: auto;
}

.btn-read svg {
  width: 16px;
  height: 16px;
  fill: var(--accent);
}

.btn-read:hover {
  color: #fff;
}

.btn-read:hover svg {
  fill: #fff;
}

/* Mobile */
@media (max-width: 900px) {
  .blog-grid {
    grid-template-columns: 1fr;
  }
}

/* FOOTER */
.site-footer {
  margin-top: 40px;
  padding: 24px;
  text-align: center;
  font-size: 0.85rem;
  color: #64748b;
  background: rgba(0, 0, 0, 0.4);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* ========================================
   RESPONSIVE Footer
   ======================================== */
@media (max-width: 768px) {
  .portfolio-container {
    grid-template-columns: 1fr;
    padding: 16px;
  }
  
  .site-footer {
    padding: 20px 16px;
    font-size: 0.85rem;
  }
}