/* ==========================================
   CSS VARIABLES (THEMES TOGGLING Added)
   ========================================== */
:root {
  --primary: #c8013c; /* Crimson Red */
  --primary-glow: rgba(200, 1, 60, 0.4);
  --primary-light: #e61a56;

  /* Dark Theme Properties (Default) */
  --bg-base: #09090b;
  --bg-surface: #18181b;
  --bg-glass: rgba(24, 24, 27, 0.85);
  --text-main: #ffffff;
  --text-muted: #a1a1aa;
  --border-color: rgba(255, 255, 255, 0.08);

  /* UI Rounded Styles */
  --radius-sm: 16px;
  --radius-md: 24px;
  --radius-lg: 40px;
  --radius-pill: 100px;

  /* Shadows & Transitions */
  --shadow-soft: 0 20px 40px rgba(0, 0, 0, 0.3);
  --shadow-glow: 0 10px 30px var(--primary-glow);
  --transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}

/* Light Theme Variables */
[data-theme="light"] {
  --bg-base: #f4f4f5;
  --bg-surface: #ffffff;
  --bg-glass: rgba(255, 255, 255, 0.85);
  --text-main: #09090b;
  --text-muted: #52525b;
  --border-color: rgba(0, 0, 0, 0.08);
  --shadow-soft: 0 20px 40px rgba(0, 0, 0, 0.06);
  --shadow-glow: 0 10px 30px rgba(200, 1, 60, 0.2);
}

/* ==========================================
   GLOBAL RESET
   ========================================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Poppins", sans-serif;
}
html {
  scroll-behavior: smooth;
}
body {
  background: var(--bg-base);
  color: var(--text-main);
  overflow-x: hidden;
  transition:
    background 0.4s ease,
    color 0.4s ease;
}
ul {
  list-style: none;
}
a {
  text-decoration: none;
  color: inherit;
}

/* ==========================================
   ANIMATED BACKGROUND SHAPES (TOP Left & BOTTOM Right)
   ========================================== */
.bg-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}

/* Base style for all glowing circles */
.shape-circle {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  opacity: 0.6;
  animation: floatingShape 12s infinite alternate ease-in-out;
}

/* Top Left Circles */
.tl-1 {
  top: -10%;
  left: -10%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, var(--primary) 0%, transparent 70%);
}
.tl-2 {
  top: 5%;
  left: 10%;
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, var(--primary-light) 0%, transparent 70%);
  animation-delay: -3s;
}

/* Bottom Right Circles */
.br-1 {
  bottom: -10%;
  right: -10%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, var(--primary) 0%, transparent 70%);
  animation-direction: alternate-reverse;
}
.br-2 {
  bottom: 5%;
  right: 10%;
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, var(--primary-light) 0%, transparent 70%);
  animation-delay: -5s;
}

/* Floating Animation for background shapes */
@keyframes floatingShape {
  0% {
    transform: translate(0, 0) scale(1);
  }
  50% {
    transform: translate(30px, -30px) scale(1.1);
  }
  100% {
    transform: translate(-30px, 30px) scale(0.9);
  }
}

/* ==========================================
   REUSABLE UI COMPONENTS
   ========================================== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Card Design */
.ui-card {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  padding: 40px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-soft);
  transition: var(--transition);
}

.section-heading {
  text-align: center;
  margin-bottom: 60px;
  padding-top: 100px;
}
.section-heading h2 {
  font-size: 3rem;
  font-weight: 800;
}
.section-heading h2 span {
  color: var(--primary);
}
.section-heading p {
  color: var(--text-muted);
  font-size: 1.1rem;
  margin-top: 10px;
}

/* Buttons */
.btn {
  padding: 16px 36px;
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 1rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border: none;
  transition: var(--transition);
}

.btn-gradient {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: white;
  box-shadow: var(--shadow-glow);
}
.btn-gradient:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 15px 40px var(--primary-glow);
}

.btn-glass {
  background: var(--bg-glass);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-color);
  color: var(--text-main);
}
.btn-glass:hover {
  border-color: var(--primary);
  color: var(--primary);
}
.btn-full {
  width: 100%;
  margin-top: 10px;
}

/* ==========================================
   NAVIGATION BAR
   ========================================== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 30px 0;
  z-index: 1000;
  background: transparent;
  transition: var(--transition);
}
.navbar.scrolled {
  padding: 15px 0;
  background: var(--bg-glass);
  backdrop-filter: blur(15px);
  border-bottom: 1px solid var(--border-color);
}
.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}
.logo {
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -1px;
}
.logo span {
  color: var(--primary);
}

.nav-links {
  display: flex;
  gap: 35px;
}
.nav-links a {
  font-weight: 500;
  opacity: 0.8;
  transition: var(--transition);
}
.nav-links a:hover {
  opacity: 1;
  color: var(--primary);
}

/* Icon buttons layout */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 15px;
}
.icon-btn {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  width: 45px;
  height: 45px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
  font-size: 1.2rem;
}
.icon-btn:hover {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}
.mobile-only {
  display: none;
}

/* ==========================================
   HERO SECTION
   ========================================== */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding-top: 120px;
  position: relative;
  z-index: 1;
}

.profile-container {
  position: relative;
  margin-bottom: 40px;
  display: inline-block;
}
.profile-img {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--bg-base);
  position: relative;
  z-index: 2;
}
.profile-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 195px;
  height: 195px;
  border-radius: 50%;
  background: linear-gradient(45deg, var(--primary), transparent);
  animation: spin 4s linear infinite;
  z-index: 1;
}

@keyframes spin {
  100% {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

/* Floating Elements around profile add more element if you want in index.html😊 */
.float-badge {
  position: absolute;
  width: 50px;
  height: 50px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: var(--primary);
  z-index: 3;
  box-shadow: var(--shadow-soft);
  animation: floatSync 3s ease-in-out infinite alternate;
}
.b-left {
  top: 10px;
  left: -25px;
  animation-delay: 0s;
}
.b-right {
  bottom: 10px;
  right: -25px;
  animation-delay: 1.5s;
}

@keyframes floatSync {
  0% {
    transform: translateY(0);
  }
  100% {
    transform: translateY(-15px);
  }
}

/* Status & Text */
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 20px;
  background: rgba(200, 1, 60, 0.1);
  border: 1px solid rgba(200, 1, 60, 0.2);
  border-radius: var(--radius-pill);
  color: var(--primary);
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 25px;
}
.dot {
  width: 8px;
  height: 8px;
  background: var(--primary);
  border-radius: 50%;
  animation: pulse 1.5s infinite;
}
@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 var(--primary-glow);
  }
  70% {
    box-shadow: 0 0 0 10px transparent;
  }
  100% {
    box-shadow: 0 0 0 0 transparent;
  }
}

.hero-title {
  font-size: 4.5rem;
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 20px;
}
.hero-title span {
  background: linear-gradient(to right, var(--text-main), var(--primary));
  -webkit-background-clip: text;
  color: transparent;
}
.hero-subtitle {
  font-size: 1.2rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto 40px;
  line-height: 1.6;
}
.hero-btn-group {
  display: flex;
  justify-content: center;
  gap: 15px;
}

/* ==========================================
   ABOUT & SKILLS SECTION
   ========================================== */
.about-card {
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}
.code-icon {
  font-size: 45px;
  color: var(--primary);
  margin-bottom: 20px;
}
.about-card h3 {
  font-size: 26px;
  margin-bottom: 15px;
}
.about-card p {
  color: var(--text-muted);
  line-height: 1.8;
  font-size: 1.1rem;
}

/* Skills Grid (add more skills from index.html) */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 20px;
  max-width: 900px;
  margin: 0 auto;
}
.skill-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
  padding: 30px 20px;
  text-align: center;
  cursor: pointer;
}
.skill-item:hover {
  border-color: var(--primary);
  transform: translateY(-5px);
}
.skill-item i {
  font-size: 40px;
  color: var(--primary);
}
.skill-item span {
  font-weight: 600;
  font-size: 1rem;
}

/* ==========================================
   PROJECTS SECTION
   ========================================== */
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 40px;
}
.project-card {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  overflow: hidden;
  transition: var(--transition);
  position: relative;
}
.project-card:hover {
  transform: translateY(-15px);
  box-shadow: var(--shadow-glow);
  border-color: var(--primary);
}

.p-img-box {
  width: 100%;
  height: 250px;
  overflow: hidden;
  padding: 15px 15px 0 15px;
}
.p-img-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: var(--radius-md);
  transition: var(--transition);
}
.project-card:hover .p-img-box img {
  transform: scale(1.05);
}

.p-content {
  padding: 30px;
}
.p-content h3 {
  font-size: 22px;
  margin-bottom: 10px;
}
.p-content p {
  color: var(--text-muted);
  font-size: 15px;
  margin-bottom: 20px;
  line-height: 1.6;
}
.p-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 25px;
}
.p-tags span {
  background: var(--bg-base);
  border: 1px solid var(--border-color);
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
}
.p-link {
  color: var(--text-main);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition);
}
.p-link:hover {
  color: var(--primary);
}

/* ==========================================
   CONTACT FORM & FOOTER (Must Use EmailJS or any other service to make the form work. I cant make this form workable without credentials😊)
   ========================================== */
.contact-wrapper {
  max-width: 800px;
  margin: 0 auto;
}
.input-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 20px;
}
.ui-input {
  width: 100%;
  background: var(--bg-base);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  padding: 18px 25px;
  border-radius: var(--radius-md);
  font-size: 1rem;
  outline: none;
  transition: var(--transition);
  margin-bottom: 20px;
}
.ui-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(200, 1, 60, 0.1);
}
textarea.ui-input {
  resize: vertical;
  border-radius: var(--radius-md);
}

footer {
  background: var(--bg-surface);
  padding: 60px 0;
  border-top: 1px solid var(--border-color);
  text-align: center;
  margin-top: 100px;
}
.footer-logo h2 {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 25px;
}
.footer-logo span {
  color: var(--primary);
}
.social-circles {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-bottom: 30px;
}
.social-circles a {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--bg-base);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  transition: var(--transition);
  border: 1px solid var(--border-color);
}
.social-circles a:hover {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
  transform: translateY(-5px);
}
footer p {
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* ==========================================
   MOBILE RESPONSIVENESS
   ========================================== */
@media (max-width: 992px) {
  .hero-title {
    font-size: 3.5rem;
  }
  .hero-subtitle {
    font-size: 1.1rem;
    padding: 0 15px;
  }

  /* Mobile Navigation Sliding Menu */
  .mobile-only {
    display: flex;
  }
  .nav-links {
    position: absolute;
    top: 80px;
    right: 20px;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-soft);
    border-radius: var(--radius-md);
    flex-direction: column;
    gap: 0;
    width: 250px;
    padding: 10px 0;
    text-align: center;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-20px);
    transition: var(--transition);
  }
  .nav-links.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }
  .nav-links a {
    display: block;
    padding: 15px 20px;
    border-bottom: 1px solid var(--border-color);
  }
  .nav-links li:last-child a {
    border-bottom: none;
  }
}

@media (max-width: 768px) {
  .hero-title {
    font-size: 2.8rem;
  }
  .input-row {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .hero-btn-group {
    flex-direction: column;
    padding: 0 20px;
  }
  .btn-glass {
    margin-left: 0;
    margin-top: 15px;
  }
  .ui-card {
    padding: 30px 20px;
  }

  /* Responsive bg shapes */
  .tl-1,
  .br-1 {
    width: 400px;
    height: 400px;
  }
}
