/* General Styles */
body {
  font-family: "Lora", serif;
  background: #e8ebf0;
  color: #333;
  opacity: 0;
  transition:
    opacity 0.25s ease,
    background-color 0.4s ease,
    color 0.4s ease;
  overflow-x: hidden;
}

html.theme-switching,
html.theme-switching * {
  transition: none !important;
}

body.loaded {
  opacity: 1;
}

body.fade-out {
  opacity: 0;
}

body,
.navbar,
.hero-content,
.blog-card,
.certificate-card,
.download-modal-card,
.project-card {
  transition:
    background-color 0.4s ease,
    color 0.4s ease,
    border-color 0.4s ease;
}

/* Navbar */
.navbar {
  background: transparent;
  padding: 15px 0;
  border: none; /* Removed border */
}
/* Customizing Brand Name */
.navbar-brand {
  display: flex;
  align-items: center;
  font-size: 20px;
  font-weight: 600;
  text-decoration: none;
  margin-left: 1rem;
  transition:
    transform 0.3s ease,
    color 0.3s ease;
}

/* Apply font to brand name */
.navbar-brand .brand-name {
  font-family: "Exile", cursive;
  font-weight: normal;
  font-size: 24px;
  color: #484554;
  letter-spacing: 1px;
}

/* Logo Styling */
.logo {
  width: 40px; /* Adjust as needed */
  height: auto;
  margin-right: 10px;
}

/* Hover & Click Animations */
.navbar-brand .brand-name:hover {
  transition: transform 0.4s ease;
  transform: scale(1.05);
  color: #53505c;
}

.navbar-brand .brand-name:active {
  transform: scale(0.95);
}

.navbar .navbar-toggler {
  border: none;
  position: absolute;
  right: 0.5rem; /* Position it to the right */
  /* margin-top: 15px; */
}

.navbar .nav-link {
  font-size: 20px; /* Make the nav menu icons smaller */
  color: #333;
  font-family: "Playfair Display", serif;
  transition: color 0.3s;
  margin-right: 50px;
}

.navbar .nav-link:hover {
  color: #6c5ce7;
  transition: transform 0.4s ease;
  transform: scale(1.12);
}

/* Hero Section */
.hero {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 85vh;
  padding: 10px 5%;
}

.hero-content {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  text-align: center;
  min-height: 620px;
  max-width: 1320px;
  width: 100%;
  justify-content: center;
  border: 2px solid #ccc;
  padding: 40px;
  border-radius: 15px;
  /* background: white; */
  flex-direction: row;
}

/* Profile Image */
.image-section img {
  width: 380px;
  height: 380px;
  border-radius: 50%;
  object-fit: cover;
  /* box-shadow: 0px 5px 15px rgba(0, 0, 0, 0.2); */
  animation:
    fadeIn 3s ease-in-out,
    breathing 5s ease-in-out 3s infinite;
  animation-fill-mode: both;
}

@keyframes breathing {
  0% {
    transform: scale(1);
  }
  30% {
    transform: scale(1.03);
  }
  100% {
    transform: scale(1);
  }
}

/* Text Section */
.text-section h1 {
  font-size: 48px;
  font-weight: bold;
  font-family: "Playfair Display", serif;
  animation: fadeIn 2s ease-in-out;
}

.text-section h2 {
  font-size: 22px;
  color: #555;
  animation: fadeIn 1s ease-in-out;
}

.text-section p {
  font-size: 18px;
  line-height: 1.6;
  animation: fadeIn 1s ease-in-out;
}

/* Social Icons */
.social-icons {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-top: 20px;
}
.social-icons a {
  font-size: 28px;
  margin-right: 5px;
  color: #333;
  transition: transform 0.36s cubic-bezier(0.23, 1, 0.32, 1), box-shadow 0.36s cubic-bezier(0.23, 1, 0.32, 1);
}
.fa-youtube {
  color: red;
}

.fa-facebook {
  color: rgb(36, 112, 234);
}

.fa-twitter {
  color: black;
}

.fa-instagram {
  color: rgb(255, 0, 128);
}

.social-icons a:hover {
  transform: translateY(-3px) scale(1.2);
}

.fa-telegram {
  color: skyblue;
}

.fa-linkedin {
  color: rgb(31, 77, 184);
}

.fa-whatsapp {
  color: green;
}

.fa-github {
  color: rgb(99, 99, 99);
}
.fa-circle-info {
  color: #df50ec;
}
/* Dark Mode Button */
#dark-mode-toggle {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: var(--primary-color, #989fad);
  color: white;
  border: none;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 18px;
  transition:
    transform 0.3s,
    background-color 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

#dark-mode-toggle:hover {
  transform: scale(1.3);
}

[data-theme="dark"] #dark-mode-toggle {
  background: var(--primary-color, #8981e5);
}

/* Footer */
.footer {
  text-align: center;
  font-size: 16px;
  background: transparent;
}

/* Smooth Animations */
@keyframes fadeIn {
  0% {
    opacity: 0;
    transform: scale(0.8);
  }
  70% {
    opacity: 1;
    transform: scale(1.08);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}
/* Blog page */
.blog-card {
  background-color: #dcdee7;
  padding: 20px;
  margin: 20px 0;
  box-shadow:
    0 4px 10px 0 rgba(0, 0, 0, 0.1),
    0 1px 5px 0 rgba(0, 0, 0, 0.1);
  border-radius: 10px;
  cursor: pointer;
  transition: transform 0.25s ease-in-out;
}

.project-image {
  position: relative;
  overflow: hidden;
  margin-top: 20px;
  width: 100%;
  height: 0;
  border-radius: 10px;
  padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
}

.project-image img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.project-image .overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(40, 44, 52, 0.26);
  backdrop-filter: blur(8px);
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  transition:
    opacity 0.28s ease-out,
    transform 0.28s ease-out;
  box-shadow: 0 8px 24px 0 rgba(31, 38, 135, 0.14);
  border-radius: 10px;
  transform: scale(0.98);
  pointer-events: auto;
}
.project-card:hover .project-image .overlay,
.project-card.touch-hover .project-image .overlay {
  opacity: 1;
  transform: scale(1);
}
.project-image .overlay .btn {
  background: rgba(255, 255, 255, 0.2);
  color: #14181a;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 2rem;
  padding: 0.7rem 2.2rem;
  font-size: 1.1rem;
  font-weight: 600;
  box-shadow: 0 2px 12px rgba(40, 44, 52, 0.18);
  transition:
    transform 0.22s cubic-bezier(0.23, 1, 0.32, 1),
    box-shadow 0.22s cubic-bezier(0.23, 1, 0.32, 1);
  letter-spacing: 0.03em;
  outline: none;
}
.project-image .overlay .btn:hover,
.project-image .overlay .btn.touch-hover {
  transform: scale(1.03);
  box-shadow: 0 4px 24px rgba(40, 44, 52, 0.25);
  background: rgba(255, 255, 255, 0.35);
  color: #111;
}

.project-image:hover .overlay {
  opacity: 1;
}

.project-image:hover img {
  transform: scale(1.02);
}

.project-image .overlay .btn {
  transform: translateY(20px);
  transition: transform 0.3s ease;
  padding: 10px 20px;
  font-size: 1rem;
  white-space: nowrap;
}

.project-image:hover .overlay .btn {
  transform: translateY(0);
}

.blog-card:hover {
  background-color: #969ab3;
  transform: scale(1.02) !important;
  will-change: transform;
}

.blog-content {
  display: none;
  margin-top: 10px;
}

.blog-content ul {
  padding-left: 20px;
  margin: 15px 0;
}

.blog-content li {
  margin-bottom: 8px;
}

.blog-content .btn {
  margin-top: 15px;
}

.section-title {
  color: #3b3b3b;
  text-align: center;
  margin-bottom: 30px;
}

/* Resume Page */
.section-title {
  color: rgb(73, 77, 81);
  text-align: center;
  margin-bottom: 30px;
  opacity: 0;
  transform: translateY(18px);
  will-change: opacity, transform;
  transition:
    opacity 0.45s ease-out,
    transform 0.45s ease-out;
}

@keyframes floatProfile {
  0% {
    transform: translateY(0) scale(1);
  }
  50% {
    transform: translateY(10px) scale(1.02);
  }
  100% {
    transform: translateY(0) scale(1);
  }
}
.profile-img {
  display: block;
  margin: 0 auto;
  min-width: 200px;
  width: 25%;
  height: 25%;
  border-radius: 50%;
  border: 3px solid #aeb0c9;
  transition: transform 0.28s ease-in-out;
  animation: floatProfile 12s ease-in-out infinite;
  animation-play-state: running;
  will-change: transform;
}
.profile-img:hover,
.profile-img.touch-hover {
  animation-play-state: paused !important;
  transform: scale(1.005) !important;
  will-change: transform;
  transition: transform 0.28s ease-in-out;
}

.profile-img.scaling {
  animation: none !important;
  transform: scale(1.02) !important;
  will-change: transform;
}

.timeline {
  position: relative;
  padding-left: 30px;
  border-left: 3px solid rgb(182, 179, 194);
}

.timeline-item {
  margin-bottom: 20px;
  padding-left: 20px;
  position: relative;
  opacity: 0;
  transform: translateY(20px);
  will-change: opacity, transform;
  transition:
    opacity 0.45s ease-out,
    transform 0.45s ease-out;
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: -11px;
  top: 5px;
  width: 20px;
  height: 20px;
  background: rgb(174, 176, 201);
  border-radius: 50%;
}
.qualifications {
  margin-top: 20px;
  margin-left: 8%;
  margin-right: 8%;
}
.skill-bar {
  background-color: rgb(219, 216, 228);
  border-radius: 10px;
  margin-bottom: 10px;
  padding: 5px;
  will-change: transform;
  transition: transform 0.25s ease-out;
}
.skill-bar:hover,
.skill-bar.touch-hover {
  transform: scale(1.02) !important;
}

.skill-bar .fill {
  height: 20px;
  background-color: #aeb0c9;
  border-radius: 5px;
  text-align: center;
  line-height: 20px;
}

.skill-icon {
  font-size: 24px;
  margin-right: 10px;
}

.skill-icons {
  margin: 10px 0;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.skill-icons i {
  /* font-size: 1.5rem; */
  color: #666;
  transition: color 0.3s ease;
}

.skill-icons i:hover {
  color: #fa478c;
  transform: scale(1.3);
}

.certificate-card {
  background: rgb(219, 216, 228);
  text-align: center;
  border-radius: 10px;
  padding-top: 20px;
  padding-left: 20px;
  padding-right: 20px;
  transition: transform 0.25s ease-out;
  min-height: 22vh;
  cursor: pointer;
}

.certificate-card img {
  width: 100%;
  max-width: 180px;
  border: 4px solid #aeb0c9;
  border-radius: 10px;
  transition: transform 0.3s ease;
}

/* Zoom overlay */
.zoom-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  z-index: 1000;
  cursor: zoom-out;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.zoom-overlay.active {
  opacity: 1;
}

.zoom-overlay img {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.9);
  max-width: 90%;
  max-height: 90%;
  border: none;
  border-radius: 5px;
  opacity: 0;
  transition:
    transform 0.6s ease,
    opacity 0.3s ease;
}

.zoom-overlay.active img {
  transform: translate(-50%, -50%) scale(1);
  opacity: 1;
}

.certificate-card:hover {
  transform: scale(1.02) !important;
}

/* Portfolio page */
.section-title {
  color: rgb(73, 77, 81);
  text-align: center;
  margin-bottom: 30px;
  opacity: 0;
  transform: translateY(20px);
  transition:
    opacity 0.8s ease-out,
    transform 0.8s ease-out;
}
.masonry-grid {
  column-count: 4;
  column-gap: 22px;
  padding: 20px;
  position: relative;
}

/* Add a transparent overlay to prevent right-click */
.masonry-grid::after {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 999999;
  pointer-events: none;
}

.masonry-grid img {
  width: 100%;
  break-inside: avoid;
  margin-bottom: 22px;
  border-radius: 3px;
  border: 1.5dvh solid #474a58;
  box-shadow:
    0 8px 8px 0 rgba(0, 0, 0, 0.28),
    0 6px 20px 0 rgba(0, 0, 0, 0.08);
  transition:
    transform 0.22s ease-out,
    box-shadow 0.22s ease-out;
  user-select: none;
  -webkit-user-select: none;
  -webkit-user-drag: none;
  pointer-events: auto;
  -webkit-touch-callout: none;
  -khtml-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
  position: relative;
  z-index: 1;
  backface-visibility: hidden;
  transform: translateZ(0);
}
/* Browser-specific context menu prevention (complemented by JavaScript) */
.masonry-grid {
  -webkit-context-menu: none;
  -moz-context-menu: none;
  -ms-context-menu: none;
  pointer-events: auto;
}

.masonry-grid img:hover {
  transform: translateY(-5px) translateZ(0);
  box-shadow: 0px 10px 22px rgba(0, 0, 0, 0.16);
}
@media (max-width: 1024px) {
  .masonry-grid {
    column-count: 3;
  }
}
@media (max-width: 768px) {
  .masonry-grid {
    column-count: 2;
  }
}
@media (max-width: 480px) {
  .masonry-grid {
    column-count: 2;
  }
}

/*🛠 FIXED RESPONSIVENESS */
/*Medium Screen Fixes */
@media (max-width: 1024px) {
  .hero-content {
    flex-direction: column-reverse;
    text-align: center;
    padding: 20px;
  }

  .image-section img {
    width: 320px;
    height: 320px;
  }

  .text-section h1 {
    font-size: 42px;
  }

  .text-section h2 {
    font-size: 20px;
  }

  .text-section p {
    font-size: 16px;
  }
  .certificate-card {
    min-height: 20vh;
    padding-top: 10px;
    /* padding-bottom: 5px; */
    padding-left: 10px;
    padding-right: 10px;
  }
}

/* Tablet Fixes */
@media (max-width: 768px) {
  .text-section h1 {
    font-size: 38px;
  }

  .text-section h2 {
    font-size: 18px;
  }

  .text-section p {
    font-size: 15px;
  }

  .image-section img {
    width: 280px;
    height: 280px;
  }
  .qualifications {
    margin-left: 2%;
    margin-right: 2%;
  }
  .certificate-card {
    min-height: 22vh;
    padding-top: 10px;
    /* padding-bottom: 5px; */
    padding-left: 10px;
    padding-right: 10px;
  }
  .project-image {
    padding-bottom: 75%; /* 4:3 Aspect Ratio for tablets */
  }
  .project-image .overlay .btn {
    padding: 8px 16px;
    font-size: 0.9rem;
  }
}

/* Small Screen Fixes */
@media (max-width: 576px) {
  .navbar .nav-link {
    margin-left: 1rem;
    margin-right: 0px;
  }
  .navbar .nav-link:hover {
    transform: scale(1.05);
  }
  .text-section h1 {
    font-size: 32px;
  }

  .text-section h2 {
    font-size: 16px;
  }

  .text-section p {
    font-size: 14px;
  }

  .image-section img {
    width: 250px;
    height: 250px;
  }

  .hero {
    padding: 0px 5px;
    min-height: 72vh;
  }
  .hero-content {
    border: 0px solid black;
  }
  .certificate-card {
    min-height: 20vh;
    padding-top: 10px;
    /* padding-bottom: 5px; */
    padding-left: 10px;
    padding-right: 10px;
  }
  .certificate-card img {
    border: 3px solid #aeb0c9;
  }

  #dark-mode-toggle {
    position: static;
    width: 24px;
    height: 24px;
    margin-right: 38px;
  }

  .navbar .navbar-toggler {
    margin-left: 10px;
  }

  .navbar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
  }

  .navbar-brand {
    margin-left: 0;
  }

  .project-image {
    padding-bottom: 100%; /* 1:1 Aspect Ratio for mobile */
  }

  .project-image .overlay .btn {
    padding: 6px 12px;
    font-size: 0.8rem;
  }
  .project-card h3 {
    font-size: 1.1rem;
  }
  .project-card p {
    font-size: 0.92rem;
  }
}

/* Dark Mode Styles */
[data-theme="dark"] {
  --bg-color: #191c26;
  --brandname-color: #8c8994;
  --brandname-hover-color: #bdb8cb;
  --text-color: #bbc3e1;
  --text-color-2: #9d8bf0;
  --hero-bg: #0e1322;
  --card-bg: #363a46;
  --card-hover: #000;
  --border-color: #363a48;
  --link-color: #7b89aa;
  --link-hover: #bdb8cb;
}

[data-theme="dark"] body {
  background: var(--bg-color);
  color: var(--text-color);
}

[data-theme="dark"] .brand-name {
  color: var(--brandname-color);
}
[data-theme="dark"] .brand-name:hover {
  color: var(--brandname-hover-color);
}

[data-theme="dark"] .navbar {
  background: var(--bg-color);
}

[data-theme="dark"] .navbar .nav-link {
  color: var(--text-color);
}

[data-theme="dark"] .navbar-brand .brand-name {
  color: var(--link-color);
}

[data-theme="dark"] .navbar-brand .brand-name:hover {
  color: var(--link-hover);
}

[data-theme="dark"] .hero-content {
  background: var(--bg-color);
  border-color: var(--border-color);
}

[data-theme="dark"] .hero h1,
.hero h2 {
  color: var(--text-color);
}

[data-theme="dark"] .blog-card {
  background-color: var(--card-bg);
}

[data-theme="dark"] .blog-card:hover {
  background-color: var(--card-hover);
}

[data-theme="dark"] .section-title {
  color: var(--text-color-2);
}
[data-theme="dark"] .profile-img {
  border: 3px solid #86838d;
}

[data-theme="dark"] .skill-bar {
  background-color: #363a46;
}

[data-theme="dark"] .skill-bar .fill {
  height: 20px;
  background-color: rgb(18, 21, 32);
}

[data-theme="dark"] .skill-icon {
  color: rgb(195, 195, 215);
}
[data-theme="dark"] .zoom-overlay {
  background: rgba(0, 0, 0, 0.8);
}

[data-theme="dark"] .certificate-card {
  background: #363a46;
}

[data-theme="dark"] .certificate-card img {
  border-color: #1f1f24;
}
[data-theme="dark"] .masonry-grid img {
  border-color: #363a46;
}

.blog-card .read-more {
  display: inline-block;
  margin-top: 1rem;
  padding: 0.5rem 1.5rem;
  background-color: var(--primary-color);
  color: white;
  border-radius: 5px;
  text-decoration: none;
  transition: all 0.3s ease;
  font-weight: 500;
}

.blog-card .read-more:hover {
  background-color: var(--secondary-color);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

[data-theme="dark"] .blog-card .read-more {
  background-color: var(--primary-color);
  color: var(--text-color);
}

[data-theme="dark"] .blog-card .read-more:hover {
  background-color: var(--secondary-color);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* Touch hover support for touchscreen devices */
.navbar-brand .brand-name.touch-hover {
  transform: scale(1.05) !important;
}

.navbar .nav-link.touch-hover {
  transform: scale(1.4) !important;
}

.social-icons a.touch-hover {
  transform: scale(1.8) !important;
}

.project-image.touch-hover .overlay {
  opacity: 1;
}

.project-image.touch-hover img {
  transform: scale(1.05) !important;
}

.project-image .overlay .btn.touch-hover {
  transform: translateY(0);
}

.blog-card.touch-hover {
  transform: scale(1.02);
}

.certificate-card:hover,
.certificate-card.touch-hover {
  transform: scale(1.04) !important;
  will-change: transform;
}

.profile-img.touch-hover {
  transform: scale(1.1) !important;
}

.masonry-grid img.touch-hover {
  transform: scale(1.1) !important;
}

.blog-card .read-more.touch-hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.image-section img.touch-hover {
  /* Optionally, add a slight scale for touch */
  transform: scale(1.06) !important;
}

/* Show overlay when the entire project card is hovered or touched */
.blog-card.project-card:hover .project-image .overlay,
.blog-card.project-card.touch-hover .project-image .overlay {
  opacity: 1;
}

/* Project Card Styles (same as blog-card, but for .project-card) */
.project-card {
  background-color: #dcdee7;
  padding: 20px;
  margin: 20px 0;
  box-shadow:
    0 4px 10px 0 rgba(0, 0, 0, 0.1),
    0 1px 5px 0 rgba(0, 0, 0, 0.1);
  border-radius: 10px;
  cursor: pointer;
  transition: transform 0.5s ease;
  position: relative;
}
.project-card:hover,
.project-card.touch-hover {
  transform: scale(1.04) !important;
  will-change: transform;
}

/* Show overlay when the entire project card is hovered or touched */
.project-card:hover .project-image .overlay,
.project-card.touch-hover .project-image .overlay {
  opacity: 1;
}

[data-theme="dark"] .project-card {
  background-color: var(--card-bg);
}
[data-theme="dark"] .project-card:hover,
[data-theme="dark"] .project-card.touch-hover {
  background-color: var(--card-hover);
}

@media (max-width: 1024px) {
  .project-card {
    min-height: 20vh;
    padding-top: 10px;
    padding-left: 10px;
    padding-right: 10px;
  }
}
@media (max-width: 768px) {
  .project-card {
    min-height: 22vh;
    padding-top: 10px;
    padding-left: 10px;
    padding-right: 10px;
  }
}
@media (max-width: 576px) {
  .project-card {
    min-height: 20vh;
    padding-top: 10px;
    padding-left: 10px;
    padding-right: 10px;
  }
}

@keyframes staggeredFadeIn {
  0% {
    opacity: 0;
    transform: translateY(24px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}
.staggered-fade-in {
  opacity: 0;
  will-change: opacity, transform;
  animation: staggeredFadeIn 0.45s ease-out forwards;
}

.project-card:hover .skill-icons i,
.project-card.touch-hover .skill-icons i,
.project-card:hover .skill-icons svg,
.project-card.touch-hover .skill-icons svg,
.project-card:hover .skill-icons svg *,
.project-card.touch-hover .skill-icons svg * {
  color: #6c5ce7 !important;
  fill: #6c5ce7 !important;
  transition:
    color 0.3s,
    fill 0.3s;
}

@keyframes wave {
  0% {
    transform: translateY(0);
  }
  10% {
    transform: translateY(-12px);
  }
  20% {
    transform: translateY(0);
  }
  100% {
    transform: translateY(0);
  }
}
.wave-animate {
  animation: wave 8s cubic-bezier(0.23, 1, 0.32, 1) infinite;
  display: inline-block;
}
.wave-animate-hover {
  animation: wave 1s cubic-bezier(0.23, 1, 0.32, 1) !important;
  animation-iteration-count: 1;
}
.social-icons a:hover,
.social-icons a.touch-hover {
  /* Remove idle wave, trigger fast wave on hover */
  animation: wave 1s cubic-bezier(0.23, 1, 0.32, 1) !important;
  animation-iteration-count: 1 !important;
}

/* Resume Section Styles */
.resume-section {
  margin: 25px 0;
  animation: fadeIn 1s ease-in-out;
}

.resume-section .resume-title {
  font-size: 1.25rem;
  font-weight: 500;
  margin-bottom: 10px;
  color: #34363a;
  letter-spacing: 0.4px;
  line-height: 1.1;
}

.resume-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
}

.resume-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(198, 209, 224, 0.258);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1.5px solid rgba(241, 244, 247, 0.586);
  color: #333;
  text-decoration: none;
  font-family: "Inter", "Montserrat", "Helvetica Neue", Arial, sans-serif;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.36s cubic-bezier(0.23, 1, 0.32, 1);
  box-shadow: 0 6px 22px rgba(31, 38, 135, 0.04);
  padding: 0;
  letter-spacing: 0.4px;
}

.resume-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  border: 1.5px solid rgba(255, 255, 255, 0.26);
  transform: translateY(-3px) scale(1.06);
  box-shadow: 0 10px 30px rgba(108, 92, 231, 0.12);
}

.resume-btn:active {
  transform: translateY(-1px) scale(1.03);
  box-shadow: 0 6px 18px rgba(108, 92, 231, 0.08);
}

/* Responsive Design */
@media (max-width: 768px) {
  .resume-buttons {
    gap: 12px;
  }

  .resume-btn {
    width: 32px;
    height: 32px;
    font-size: 10px;
  }
}

/* Dark theme adjustments for resume buttons */
[data-theme="dark"] .resume-btn {
  color: var(--text-color);
  border: 1.2px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.02);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.5);
}

[data-theme="dark"] .resume-btn:hover {
  background: rgba(255, 255, 255, 0.04);
  border: 1.2px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.56);
}

[data-theme="dark"] .resume-btn:active {
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.45);
}
[data-theme="dark"] .resume-title {
  color: var(--text-color);
  text-align: center;
  margin-bottom: 15px;
}

/* --- Download Confirmation Modal --- */
.download-modal-overlay {
  display: flex;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 2000;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.download-modal-overlay.modal-visible {
  opacity: 1;
  pointer-events: auto;
}

.download-modal-card {
  background: #e8ebf0; /* Default Light theme background matches your body color */
  color: #333;
  padding: 25px 30px;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
  max-width: 400px;
  width: 90%;
  text-align: center;
  transform: scale(0.9);
  transition: transform 0.3s ease;
  border: 1px solid rgba(0, 0, 0, 0.05);
}

.download-modal-overlay.modal-visible .download-modal-card {
  transform: scale(1);
}

.download-modal-card h3 {
  font-family: "Playfair Display", serif;
  font-size: 22px;
  margin-bottom: 12px;
}

.download-modal-card p {
  font-size: 15px;
  margin-bottom: 24px;
  line-height: 1.5;
}

.modal-actions {
  display: flex;
  justify-content: center;
  gap: 15px;
}

.modal-btn {
  padding: 8px 24px;
  font-size: 14px;
  font-weight: 600;
  border-radius: 20px;
  border: none;
  cursor: pointer;
  transition:
    transform 0.2s ease,
    background-color 0.2s ease;
}

.modal-btn:hover {
  transform: scale(1.05);
}

.modal-btn:active {
  transform: scale(0.95);
}

.btn-cancel {
  background: rgba(0, 0, 0, 0.06);
  color: #555;
}

.btn-cancel:hover {
  background: rgba(0, 0, 0, 0.12);
}

.btn-confirm {
  background: #6c5ce7;
  color: white;
}

.btn-confirm:hover {
  background: #5b4cc4;
}

/* Dark Mode support for the modal */
[data-theme="dark"] .download-modal-card {
  background: var(--bg-color, #191c26);
  color: var(--text-color, #bbc3e1);
  border-color: var(--border-color, #363a48);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

[data-theme="dark"] .btn-cancel {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-color, #bbc3e1);
}

[data-theme="dark"] .btn-cancel:hover {
  background: rgba(255, 255, 255, 0.15);
}

/* ==========================================================================
   AI & Data Science Project Specifications Modal
   ========================================================================== */

/* Background Dimmed Overlay */
.ai-project-modal-overlay {
  display: flex;
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  z-index: 2500;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* Visibility State Trigger */
.ai-project-modal-overlay.ai-modal-open {
  opacity: 1;
  pointer-events: auto;
}

/* Modal Content Box Container (Light Mode Base) */
.ai-project-modal-card {
  background: #e8ebf0;
  color: #333;
  padding: 25px 30px;
  border-radius: 12px;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.16);
  max-width: 550px;
  width: 90%;
  text-align: left;
  transform: scale(0.92);
  transition: transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  border: 1px solid rgba(0, 0, 0, 0.06);
}

.ai-project-modal-overlay.ai-modal-open .ai-project-modal-card {
  transform: scale(1);
}

/* Modal Typography Layout structures */
.ai-project-modal-card h3 {
  font-family: "Playfair Display", serif;
  font-size: 24px;
  margin-bottom: 15px;
  border-bottom: 1px dashed rgba(0, 0, 0, 0.2);
  padding-bottom: 10px;
}

.ai-project-modal-card p {
  font-size: 15px;
  margin-bottom: 15px;
  line-height: 1.5;
  font-weight: 500;
}

/* Specifications Bulleted List */
.ai-project-modal-list {
  font-size: 0.95rem;
  padding-left: 15px;
  margin-bottom: 25px;
  line-height: 1.6;
  color: #333;
  list-style-type: disc;
}

.ai-project-modal-list li {
  margin-bottom: 10px;
}

/* --- Dark Mode Semantic Theme Adapters --- */
[data-theme="dark"] .ai-project-modal-card {
  background: var(--bg-color, #191c26) !important;
  color: var(--text-color, #bbc3e1) !important;
  border-color: var(--border-color, #363a48) !important;
  box-shadow: 0 14px 45px rgba(0, 0, 0, 0.52);
}

[data-theme="dark"] .ai-project-modal-card h3 {
  color: var(--text-color-2, #9d8bf0) !important;
  border-bottom-color: var(--border-color, #363a48) !important;
}

[data-theme="dark"] .ai-project-modal-list {
  color: var(--text-color, #bbc3e1) !important;
}

/* --- Responsive Layout Breakpoints --- */
@media (max-width: 576px) {
  .ai-project-modal-card {
    padding: 18px 20px !important;
    width: 92% !important;
    margin: 10px !important;
  }

  .ai-project-modal-card h3 {
    font-size: 20px !important;
    margin-bottom: 12px !important;
  }

  .ai-project-modal-list {
    font-size: 0.88rem !important;
    padding-left: 12px !important;
    margin-bottom: 18px !important;
  }

  .ai-project-modal-list li {
    margin-bottom: 8px !important;
  }
}

/* ==========================================================================
   Static Navigation Blog System Upgrades
   ========================================================================== */

/* Structural reset for link cards */
.blog-card-link {
  color: inherit !important;
  display: block;
}

.blog-card-link:hover {
  text-decoration: none !important;
}

/* Card layout enhancements for direct click interaction */
.static-blog-card {
  margin: 0 !important; /* Managed cleanly via Bootstrap's row g-4 layout */
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 220px;
}

.static-blog-card h3 {
  font-family: "Playfair Display", serif;
  font-size: 1.4rem;
  margin-top: 5px;
  margin-bottom: 12px;
  transition: color 0.3s ease;
}

/* Metadata components style architecture */
.read-time-badge {
  font-size: 0.85rem;
  font-weight: 500;
  color: #666;
}

/* Interactive navigation button transition properties */
.read-more-link {
  border-radius: 20px !important;
  padding: 6px 18px !important;
  font-size: 0.9rem !important;
  font-weight: 600 !important;
  background: #6c5ce7 !important;
  border: none !important;
  color: white !important;
  transition:
    transform 0.2s ease,
    background-color 0.2s ease !important;
}

/* Trigger nested element styling on whole card hover state */
.blog-card-link:hover .static-blog-card h3 {
  color: #6c5ce7;
}

.blog-card-link:hover .read-more-link {
  background: #5b4cc4 !important;
  transform: translateX(4px);
}

/* --- Dark Mode Semantic Adjustments --- */
[data-theme="dark"] .read-time-badge {
  color: var(--link-color, #7b89aa);
}

[data-theme="dark"] .blog-card-link:hover .static-blog-card h3 {
  color: var(--text-color-2, #9d8bf0);
}

[data-theme="dark"] .blog-card-link:hover .read-more-link {
  background: var(--text-color-2, #9d8bf0) !important;
  color: var(--bg-color, #191c26) !important;
}

/* ==========================================================================
   Bulletproof Dark Mode Toggle Icon Switcher
   ========================================================================== */

/* By default, hide the dark-theme-only icon */
#dark-mode-toggle .only-dark {
  display: none !important;
}

/* By default, display the light-theme-only icon */
#dark-mode-toggle .only-light {
  display: inline-block !important;
}

/* When the HTML document flips to dark mode, swap their states instantly */
[data-theme="dark"] #dark-mode-toggle .only-dark {
  display: inline-block !important;
}

[data-theme="dark"] #dark-mode-toggle .only-light {
  display: none !important;
}
/* FIX: Prevent Sticky Hover Scales on Touchscreens */
@media (hover: none) {
  #dark-mode-toggle:hover,
  .theme-toggle:hover {
    transform: none !important; /* Resets scale parameters instantly on phone taps */
  }
}

/* ==========================================================================
   Mobile Navbar Toggler Highlight Cleanup
   ========================================================================== */

/* Remove the persistent, heavy border box when clicked or focused on mobile */
.navbar .navbar-toggler:focus,
.navbar .navbar-toggler:active,
.navbar .navbar-toggler-icon:focus {
  outline: none !important;
  box-shadow: none !important;
  border: none !important;
}

/* ==========================================================================
   Blog Page Layout & Article Typography
   ========================================================================== */

/* Main container configuration */
.blog-container {
  max-width: 900px;
  margin-top: 3rem;
  margin-bottom: 5rem;
}

/* Article base typography */
.article-content {
  line-height: 1.8;
  font-size: 1.15rem;
  color: #333;
}

.article-content p {
  margin-bottom: 1.6rem;
}

.article-content .lead {
  font-size: 1.35rem;
  font-weight: 500;
  line-height: 1.7;
  color: #222;
}

/* Headings within the article */
.article-content h2,
.article-content h3 {
  font-family: "Playfair Display", serif;
  color: #2d3436;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  font-weight: 700;
}

/* Sub-lists within content body */
.article-content ul {
  padding-left: 20px;
  margin-bottom: 1.5rem;
}

.article-content li {
  margin-bottom: 0.5rem;
}

/* Back button border separation */
.blog-footer-nav {
  margin-top: 3.5rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(0, 0, 0, 0.1);
}

/* ==========================================================================
   Code Blocks & Code Typography Architecture
   ========================================================================== */

/* Preformatted code block wrapper */
pre {
  background-color: #f8f9fa;
  border-left: 4px solid #6c5ce7;
  padding: 18px;
  border-radius: 6px;
  margin-top: 1.5rem;
  margin-bottom: 2rem;
  box-shadow: inset 0 1px 4px rgba(0, 0, 0, 0.03);
}

/* Code typography syntax spacing */
code {
  font-family: "Courier New", Courier, monospace;
  font-size: 0.95rem;
  color: #2d3436;
}

/* ==========================================================================
   Dark Mode Theme Adapters [data-theme="dark"]
   ========================================================================== */

[data-theme="dark"] .article-content {
  color: var(--text-color);
}

[data-theme="dark"] .article-content .lead {
  color: #fff;
}

[data-theme="dark"] .article-content h2,
[data-theme="dark"] .article-content h3 {
  color: var(--text-color-2);
}

/* Code block adaptation in dark mode */
[data-theme="dark"] pre {
  background-color: #1e222b;
  border-left-color: var(--text-color-2);
  box-shadow: inset 0 1px 6px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] code {
  color: #e2e8f0;
}

[data-theme="dark"] .blog-footer-nav {
  border-top-color: var(--border-color);
}

/* ==========================================================================
   Clean, Independent Blog Animations (No JS Conflicts)
   ========================================================================== */

/* Core Animation Keyframes */
@keyframes blogEntrance {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* DESKTOP & TABLET: Smooth, instant CSS-only animation on load */
@media (min-width: 769px) {
  .blog-fade-in {
    opacity: 0;
    animation: blogEntrance 0.5s ease-out forwards;
  }
}

/* SMARTPHONE & TABLET BREAKPOINTS: Instant loading, formatting, and text wrapping */
@media (max-width: 768px) {
  .blog-fade-in {
    opacity: 1;
    transform: none;
    animation: none;
  }

  .blog-container {
    margin-top: 1.5rem;
    padding-left: 15px;
    padding-right: 15px;
  }

  .article-content {
    font-size: 1.05rem;
  }

  .article-content .lead {
    font-size: 1.15rem;
  }

  /* Code block overflow protection - forces long lines to wrap downward */
  pre {
    padding: 12px;
    white-space: pre-wrap;
    white-space: -moz-pre-wrap;
    white-space: -pre-wrap;
    white-space: -o-pre-wrap;
    word-wrap: break-word;
  }

  code {
    font-size: 0.8rem;
  }
}

/* ==========================================================================
   Blog Image Integration & Responsive Scaling
   ========================================================================== */

/* Base Wrapper */
.blog-image-wrapper {
  margin: 2.5rem 0; /* Creates breathing room above and below the image */
  text-align: center;
  width: 100%;
}

/* The Image Itself */
.blog-image-wrapper img {
  width: 100%;
  height: auto;
  border-radius: 8px; /* Smooth, modern corners */
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08); /* Premium subtle shadow */
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
}

/* Subtle interactive lift effect on hover (Desktop) */
@media (hover: hover) {
  .blog-image-wrapper img:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
  }
}

/* Caption Typography */
.blog-image-wrapper figcaption {
  margin-top: 0.8rem;
  font-size: 0.9rem;
  color: #636e72;
  font-style: italic;
  font-family: "Inter", "Helvetica Neue", sans-serif;
}

/* --- Dark Mode Theme Adapters --- */
[data-theme="dark"] .blog-image-wrapper img {
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4); /* Darker, deeper shadow for dark backgrounds */
  border: 1px solid var(--border-color, #363a48); /* Defines the edge cleanly in dark mode */
}

[data-theme="dark"] .blog-image-wrapper figcaption {
  color: var(--link-color, #7b89aa);
}

/* --- Responsive Breakpoints --- */

/* Tablet Adjustments */
@media (max-width: 768px) {
  .blog-image-wrapper {
    margin: 2rem 0; /* Slightly tighter margins for tablets */
  }
}

/* Smartphone Adjustments */
@media (max-width: 576px) {
  .blog-image-wrapper {
    margin: 1.5rem 0; /* Tightest margins to save screen real estate */
  }

  .blog-image-wrapper img {
    border-radius: 6px; /* Slightly sharper corners fit small screens better */
  }

  .blog-image-wrapper figcaption {
    font-size: 0.85rem; /* Scales text down so it doesn't wrap awkwardly */
  }
}
