* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* :root {
  --primary: #6366f1;
  --secondary: #4f46e5;
  --dark: #1e1b4b;
  --gray: #c7d2fe;
  --light: #312e81;
  --white: #ffffff;
  --border: #4338ca;
} */

:root {
  --primary: #3b82f6;
  --secondary: #2563eb;
  --dark: #0f172a;
  --gray: #94a3b8;
  --light: #1e293b;
  --white: #f8fafc;
  --border: #334155;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Poppins", sans-serif;
  background: #0f172a;
  color: var(--white);
  line-height: 1.6;
}

a {
  text-decoration: none;
  color: inherit;
}

.container {
  width: min(1200px, 90%);
  margin: auto;
}

/* Navbar */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  backdrop-filter: blur(12px);
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid #334155;
  z-index: 1000;
}

.nav-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 0;
}

.nav-wrapper img {
  width: 28px;
}

.nav-wrapper .logo {
  display: flex;
  gap: 8px;
}

.logo {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--white);
}

.nav-links {
  display: flex;
  gap: 1.5rem;
}

.nav-links a {
  font-weight: 500;
  transition: 0.3s ease;
}

.nav-links a:hover {
  color: #c7d2fe;
}

.menu-btn {
  display: none;
  flex-direction: column;
  gap: 4px;
  cursor: pointer;
}

.menu-btn span {
  width: 24px;
  height: 3px;
  background: #1a1744;
  border-radius: 20px;
}

/* Hero */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 80px;

  background:
    radial-gradient(
      circle at top right,
      rgba(37, 99, 235, 0.18),
      transparent 25%
    ),
    radial-gradient(
      circle at bottom left,
      rgba(59, 130, 246, 0.12),
      transparent 25%
    ),
    #0f172a;
}

.hero-wrapper {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  align-items: center;
  gap: 3rem;
}

.hero-text h3 {
  color: var(--primary);
  margin-bottom: 0.5rem;
  font-size: 1rem;
}

.hero-text h1 {
  font-size: 3.5rem;
  line-height: 1.2;
  margin-bottom: 1rem;
}

.hero-text p {
  color: #cbd5e1;
  margin-bottom: 2rem;
  max-width: 550px;
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.hero-icons {
  display: flex;
  gap: 12px;
  margin-top: 20px;
}

.hero-icons a {
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}

.btn-hero {
  width: 80px;
  height: 80px;
  color: white;
  border: white 1px solid;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  /* Smooth transition for the hover effect */
  transition: transform 0.3s ease-in-out;
}

.btn-hero:hover {
  transform: scale(1.1);
}

.btn {
  padding: 0.9rem 1.5rem;
  border-radius: 12px;
  font-weight: 600;
  transition: 0.3s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.btn-primary {
  background: linear-gradient(135deg, #818cf8, #4f46e5);
  color: white;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(79, 70, 229, 0.2);
}

.btn-outline {
  border: 1px solid #4338ca;
  background: #312e81;
}

.btn-outline:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.hero-image {
  display: flex;
  justify-content: center;
  align-items: center;
}

.profile-card {
  width: 360px;
  height: 360px;
  background: #312e81;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  text-align: center;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.35);
  overflow: hidden;
}

.profile-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

section {
  padding: 100px 0;
}

.section-title {
  text-align: center;
  margin-bottom: 4rem;
}

.section-title h2 {
  font-size: 2.3rem;
  margin-bottom: 0.5rem;
}

.section-title p {
  color: #cbd5e1;
}

/* About */
.about-content {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  align-items: start;
}

.about-card,
.technologies-card {
  .about-card,
  .technologies-card {
    background: #111827;
    border: 1px solid #334155;
    border-radius: 24px;
    padding: 40px;
    margin-top: 20px;
  }
}

.about-card h3 {
  margin-bottom: 1rem;
}

.about-card p {
  margin: 0;
  line-height: 1.7;
  color: #cbd5e1;
}

/* TECHNOLOGIES */

.technologies-card {
  padding: 16px;
}

.technologies-card h3 {
  margin: 0 0 25px 0;
  text-align: center;
  font-size: 28px;
  color: #ffffff;
}

.technology-list {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.technology-item {
  display: inline-block;
  background: #1e293b;
  color: #e2e8f0;
  border: 1px solid #475569;
  padding: 14px 25px;
  border-radius: 30px;
  font-weight: 600;
  font-size: 12px;
  transition: 0.3s ease;
}

.technology-item:hover {
  background: #2563eb;
  border-color: #3b82f6;
  color: white;
}

.experience-box {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.experience-item {
  padding: 1.5rem;
  border-radius: 18px;
  background: #312e81;
  border: 1px solid #4338ca;
}

.experience-item h4 {
  margin-bottom: 0.3rem;
}

.experience-item {
  padding: 1.5rem;
  border-radius: 18px;
  background: #111827;
  border: 1px solid #334155;
}

.experience-item span {
  color: #60a5fa;
  font-weight: 500;
  font-size: 0.95rem;
}

.experience-item ul {
  padding: 1rem 1.5rem;
  border-radius: 18px;
  background: #1e293b;
}

/* Skills */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
}

.skill-card {
  background: #111827;
  border-radius: 24px;
  padding: 2rem;
  text-align: center;
  border: 1px solid #334155;
  transition: 0.3s ease;
}

.skill-card:hover {
  transform: translateY(-8px);
  border-color: #3b82f6;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.35);
}

.skill-icon {
  width: 70px;
  height: 70px;
  border-radius: 20px;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  margin: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.5rem;
  margin-bottom: 1rem;
  font-weight: 700;
}

.skill-card p {
  color: #cbd5e1;
  margin-top: 0.5rem;
  font-size: 0.95rem;
}

/* Portfolio */
/* .portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
} */

.portfolio-grid,
.certificate-grid {
  display: flex;
  flex-direction: column;
  gap: 48px;
}

.portfolio-section,
.certificate-section {
  margin-bottom: 60px;
}

.portfolio-title,
.certificate-title {
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 24px;
  color: white;
  text-transform: capitalize;
}

.portfolio-grid-inner,
.certificate-grid-inner {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.portfolio-card,
.certificate-card {
  background: #111827;
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid #334155;
  transition: 0.3s ease;
  max-width: 25vw;
}

.portfolio-image,
.certificate-image {
  height: 250px;
  background: linear-gradient(135deg, #1e3a8a, #2563eb);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #dbeafe;
  font-weight: 600;
  font-size: 1rem;
  overflow: hidden;
}

.portfolio-card:hover,
.certificate-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.35);
}

/* .portfolio-image,
.certificate-image {
  height: 250px;
  background: linear-gradient(135deg, #6366f1, #4f46e5);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #dbeafe;
  font-weight: 600;
  font-size: 1rem;
  overflow: hidden;
} */

.certificate-image {
  height: 300px;
}

.portfolio-image img,
.certificate-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.portfolio-content,
.certificate-content {
  padding: 1.5rem;
}

.portfolio-content h3,
.certificate-content h3 {
  margin-bottom: 0.5rem;
}

.portfolio-content p,
.certificate-content p {
  color: #cbd5e1;
  font-size: 0.95rem;
}

.portfolio-store {
  margin-top: 1rem;
  display: flex;
  gap: 1rem;
  justify-items: center;
}

.btn-store {
  padding: 0.5rem 1rem;
  border-radius: 12px;
  font-weight: 600;
  background: linear-gradient(135deg, #818cf8, #334155);
  color: white;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.btn-store i {
  margin-right: 0.5rem;
}

.certificateSwiper,
.portfolioSwiper {
  width: 100%;
  padding-bottom: 40px;
}

.swiper-slide,
.portfolioSwiper .swiper-slide {
  height: auto;
}

.swiper-slide .certificate-card,
.portfolioSwiper .portfolio-card {
  height: 100%;
}

/* Contact */
.contact {
  padding: 100px 0;
}

.contact-buttons {
  margin-top: 2rem;

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

  gap: 1rem;
}

.contact-buttons .btn,
.hero-buttons .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;

  padding: 0.9rem 1.5rem;

  border-radius: 14px;

  text-decoration: none;

  font-size: 0.95rem;
  font-weight: 600;

  transition: all 0.3s ease;
}

.contact-buttons .btn i {
  font-size: 1.1rem;
}

/* Primary Button */
.btn-primary {
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  color: white;
  border: 1px solid #2563eb;
}

.btn-primary:hover {
  background: #1d4ed8;
  border-color: #1d4ed8;
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(37, 99, 235, 0.35);
}

.btn-outline {
  color: #dbeafe;
  border: 1px solid #475569;
  background: rgba(255, 255, 255, 0.04);
}

.btn-outline:hover {
  background: #2563eb;
  border-color: #2563eb;
  color: white;
}

/* Footer */
.footer {
  margin-top: 5rem;

  text-align: center;

  color: #94a3b8;

  font-size: 0.9rem;

  border-top: 1px solid rgba(255, 255, 255, 0.08);

  padding-top: 2rem;
}

/* Loader overlay */
#loader.loader {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(14, 16, 40, 0.6);
  z-index: 2000;
  transition:
    opacity 0.25s ease,
    visibility 0.25s ease;
}

.loader.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.spinner {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: 6px solid rgba(255, 255, 255, 0.12);
  border-top-color: #ffffff;
  animation: spin 1s linear infinite;
}

/* Skeleton placeholders for about/experience */
.skeleton-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.25rem;
}

.skeleton-card {
  height: 160px;
  border-radius: 16px;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0.03) 25%,
    rgba(255, 255, 255, 0.06) 50%,
    rgba(255, 255, 255, 0.03) 75%
  );
  background-size: 200% 100%;
  animation: shimmer 1.2s linear infinite;
  border: 1px solid rgba(255, 255, 255, 0.04);
}

/* Portfolio read more */
.description {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}

.description.expanded {
  -webkit-line-clamp: unset;
}

.read-more-btn {
  background: none;
  border: none;
  color: #2563eb;
  cursor: pointer;
  padding: 0;
  margin-top: 8px;
  font-size: 14px;
}

.read-more-btn:hover {
  text-decoration: underline;
}

/* Certificate */
.certificate-image img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: 12px;
  cursor: pointer;
  transition: 0.3s;
}

.certificate-image img:hover {
  transform: scale(1.03);
}

.pdf-thumbnail {
  width: 100%;
  height: auto;

  border-radius: 12px;

  cursor: pointer;

  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);

  transition: 0.3s;
}

.pdf-thumbnail:hover {
  transform: scale(1.03);
}

/* Modal image */
.image-modal {
  display: flex;
  justify-content: center;
  align-items: center;

  position: fixed;
  inset: 0;

  background: rgba(0, 0, 0, 0.85);

  opacity: 0;
  visibility: hidden;

  transition: 0.3s;
  z-index: 9999;
}

.image-modal.show {
  opacity: 1;
  visibility: visible;
}

.modal-content {
  max-width: 90%;
  max-height: 90%;
  border-radius: 10px;
  animation: zoom 0.25s ease;
}

.close-image {
  position: absolute;
  top: 20px;
  right: 30px;

  color: white;
  font-size: 40px;
  cursor: pointer;
  user-select: none;
}

.portfolio-image img {
  cursor: zoom-in;
}

@keyframes zoom {
  from {
    transform: scale(0.8);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

@keyframes shimmer {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Responsive */
@media (max-width: 1000px) {
  .hero-wrapper,
  .about-content {
    grid-template-columns: 1fr;
  }

  .hero {
    padding: 120px 0 60px;
  }

  .hero-text {
    text-align: center;
    order: 2;
    margin: auto;
  }

  .hero-text p {
    text-align: center;
    margin: auto;
  }

  .hero-buttons {
    justify-content: center;
    margin-top: 16px;
  }

  .hero-text h1 {
    font-size: 2.7rem;
  }

  .hero-icons {
    justify-content: center;
  }

  .hero-image {
    order: 1;
  }

  .profile-card {
    width: 100%;
    max-width: 320px;
    height: auto;
  }

  .about-content {
    display: flex;
    flex-direction: column;
  }

  .hero-image {
    order: 1;
  }

  .about-card {
    order: 1;
  }

  .experience-box {
    order: 2;
  }

  .portfolio-card,
  .certificate-card {
    max-width: 100vw;
  }

  .contact-buttons {
    flex-direction: row;
  }
}

@media (max-width: 768px) {
  .nav-links {
    position: absolute;
    top: 70px;
    right: 5%;
    background: #111827;
    border: 1px solid #334155;
    border-radius: 18px;
    padding: 1rem;
    width: 220px;
    flex-direction: column;
    display: none;
  }

  .nav-links.active {
    display: flex;
  }

  .menu-btn {
    display: flex;
  }

  .hero-wrapper {
    display: flex;
    justify-content: center;
    flex-direction: column;
  }

  .hero-text {
    order: 2;
  }

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

  .hero-icons {
    justify-content: center;
  }

  .hero-image {
    order: 1;
  }

  .profile-card {
    width: 100%;
    max-width: 320px;
    height: auto;
  }

  .about-content {
    display: flex;
    flex-direction: column;
  }

  .about-card {
    order: 1;
  }

  .experience-box {
    order: 2;
  }

  section {
    padding: 80px 0;
  }

  .portfolio-card,
  .certificate-card {
    max-width: 100vw;
  }

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

  .contact-buttons .btn {
    width: 100%;
    max-width: 320px;
  }
}
