﻿:root {
  --bg: #050816;
  --bg-soft: rgba(15, 23, 42, 0.9);
  --glass: rgba(15, 23, 42, 0.75);
  --accent: #00f5ff;
  --accent-soft: rgba(0, 245, 255, 0.18);
  --text: #f9fafb;
  --muted: #9ca3af;
  --border: rgba(148, 163, 184, 0.28);
  --radius-lg: 24px;
  --radius-xl: 32px;
  --shadow-soft: 0 28px 80px rgba(0, 0, 0, 0.6);
  --shadow-accent: 0 0 40px rgba(0, 245, 255, 0.4);
}

/* Light theme override */
body.light-theme {
  --bg: #f3f4f6;
  --bg-soft: rgba(243, 244, 246, 0.96);
  --glass: rgba(255, 255, 255, 0.9);
  --accent: #2563eb;
  --accent-soft: rgba(37, 99, 235, 0.18);
  --text: #0f172a;
  --muted: #4b5563;
  --border: rgba(148, 163, 184, 0.5);
  --shadow-soft: 0 24px 70px rgba(15, 23, 42, 0.1);
  --shadow-accent: 0 0 38px rgba(37, 99, 235, 0.3);
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Poppins", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--text);
  background: radial-gradient(circle at top, #111827, #020617 55%);
  min-height: 100vh;
  transition: background 0.3s ease, color 0.3s ease;
}

/* Background glow */
.bg-glow {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
}

.bg-glow::before {
  content: "";
  position: absolute;
  width: 520px;
  height: 520px;
  background: radial-gradient(circle, var(--accent-soft), transparent 65%);
  top: -120px;
  right: -80px;
  filter: blur(6px);
  opacity: 0.8;
}

/* Layout */

.container {
  width: min(1120px, 100% - 3rem);
  margin: 0 auto;
}

.section {
  padding: 5rem 0;
}

.section-container {
  background: var(--glass);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-soft);
  padding: 2.5rem 2.4rem 2.6rem;
  backdrop-filter: blur(18px);
}

.section-header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.section-header h2 {
  font-size: 1.8rem;
  letter-spacing: 0.05em;
}

.section-header p {
  color: var(--accent);
  font-size: 0.95rem;
  margin-top: 0.25rem;
}

.two-column {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .two-column {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Navbar */

.navbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(to bottom, rgba(5, 7, 20, 0.98), rgba(5, 7, 20, 0.88));
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(75, 85, 99, 0.4);
}

body.light-theme .navbar {
  background: linear-gradient(to bottom, rgba(249, 250, 251, 0.98), rgba(249, 250, 251, 0.92));
}

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

.logo {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-weight: 600;
}

.logo-dot {
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: radial-gradient(circle at 30% 30%, #f9fafb, var(--accent));
  box-shadow: 0 0 18px rgba(0, 245, 255, 0.9);
}

body.light-theme .logo-dot {
  box-shadow: 0 0 16px rgba(37, 99, 235, 0.7);
}

.logo-text {
  font-size: 1.05rem;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.8rem;
  font-size: 0.95rem;
}

.nav-link {
  color: var(--muted);
  text-decoration: none;
  position: relative;
  padding-bottom: 0.2rem;
  transition: color 0.2s ease;
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  height: 2px;
  width: 0;
  background: var(--accent);
  border-radius: 999px;
  transition: width 0.25s ease-out;
}

.nav-link:hover {
  color: var(--text);
}

.nav-link.active {
  color: var(--accent);
}

.nav-link.active::after {
  width: 100%;
}

/* Nav actions */

.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.theme-toggle {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  background: rgba(15, 23, 42, 0.9);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #e5e7eb;
  cursor: pointer;
  font-size: 0.95rem;
  transition: background 0.2s ease, transform 0.15s ease, box-shadow 0.15s ease;
}

body.light-theme .theme-toggle {
  background: rgba(248, 250, 252, 0.95);
  color: #0f172a;
}

.theme-toggle:hover {
  transform: translateY(-1px);
  box-shadow: 0 0 16px rgba(0, 245, 255, 0.5);
}

/* Mobile nav */

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  flex-direction: column;
  gap: 4px;
}

.nav-toggle span {
  width: 22px;
  height: 2px;
  border-radius: 999px;
  background: #e5e7eb;
}

body.light-theme .nav-toggle span {
  background: #0f172a;
}

@media (max-width: 768px) {
  .nav-links {
    position: absolute;
    inset: 64px 1.5rem auto 1.5rem;
    background: #020617f2;
    border-radius: 18px;
    border: 1px solid rgba(148, 163, 184, 0.4);
    padding: 1rem 1.25rem;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.9rem;
    transform-origin: top;
    transform: scaleY(0.2);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.16s ease-out, opacity 0.16s ease-out;
  }

  body.light-theme .nav-links {
    background: #f9fafb;
  }

  .nav-links.open {
    opacity: 1;
    transform: scaleY(1);
    pointer-events: auto;
  }

  .nav-toggle {
    display: flex;
  }
}

/* Hero */

.hero {
  padding: 4.5rem 0 5rem;
}

.hero-container {
  background: radial-gradient(circle at top left, var(--accent-soft), transparent 55%),
    linear-gradient(135deg, var(--bg-soft), var(--bg-soft));
  border-radius: 32px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-soft);
  padding: 3.2rem 3rem;
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1.2fr);
  gap: 2.8rem;
  align-items: center;
  backdrop-filter: blur(20px);
}

.hero-greeting {
  color: var(--muted);
  font-size: 0.95rem;
  margin-bottom: 0.3rem;
}

.hero-name {
  font-size: clamp(2.2rem, 3.1vw, 2.8rem);
  font-weight: 700;
}

.hero-role {
  margin-top: 0.4rem;
  font-size: 1.05rem;
  color: var(--accent);
}

.hero-description {
  margin-top: 1.2rem;
  color: var(--muted);
  line-height: 1.7;
  max-width: 440px;
}

.hero-social {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin-top: 1.6rem;
}

.social-icon {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #e5e7eb;
  text-decoration: none;
  font-size: 0.95rem;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}

body.light-theme .social-icon {
  color: #0f172a;
  background: rgba(248, 250, 252, 0.9);
}

.social-icon:hover {
  background: rgba(15, 23, 42, 0.95);
  border-color: var(--accent);
  box-shadow: 0 0 18px var(--accent-soft);
  transform: translateY(-1px);
}

/* Buttons */

.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.7rem 1.6rem;
  border-radius: 999px;
  border: none;
  outline: none;
  font-size: 0.96rem;
  font-weight: 500;
  cursor: pointer;
  background: radial-gradient(circle at 30% 0%, #ecfeff, #22d3ee);
  color: #020617;
  text-decoration: none;
  box-shadow: 0 16px 35px rgba(8, 47, 73, 0.7);
  margin-top: 1.8rem;
  transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
}

body.light-theme .btn-primary {
  background: radial-gradient(circle at 20% 0%, #eff6ff, #2563eb);
  box-shadow: 0 16px 32px rgba(37, 99, 235, 0.5);
}

.btn-primary:hover {
  transform: translateY(-1px);
  filter: brightness(1.04);
  box-shadow: 0 20px 40px rgba(8, 47, 73, 0.9);
}

/* Hero image floating */

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

.hexagon-wrap {
  position: relative;
  width: min(260px, 72vw);
  aspect-ratio: 1 / 1.05;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hexagon-glow {
  position: absolute;
  inset: 0;
  border-radius: 36px;
  filter: drop-shadow(0 0 40px var(--accent-soft));
}

.hexagon-glow::before {
  content: "";
  position: absolute;
  inset: -10px;
  background: radial-gradient(circle at 30% 0%, #e0f2fe, #22d3ee 45%, #06b6d4 75%);
  clip-path: polygon(25% 6%, 75% 6%, 100% 50%, 75% 94%, 25% 94%, 0% 50%);
}

.profile-img {
  position: relative;
  z-index: 1;
  width: 88%;
  height: 88%;
  object-fit: cover;
  border-radius: 30px;
  clip-path: polygon(25% 6%, 75% 6%, 100% 50%, 75% 94%, 25% 94%, 0% 50%);
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.9);
}

.floating {
  animation: floatY 4.5s ease-in-out infinite;
}

.floating-orbit::before {
  content: "";
  position: absolute;
  width: 180px;
  height: 180px;
  border-radius: 999px;
  border: 1px dashed rgba(148, 163, 184, 0.5);
  animation: orbit 16s linear infinite;
}

/* Skills */

.skills-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.skill-card {
  background: rgba(15, 23, 42, 0.85);
  border-radius: 18px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  padding: 0.9rem 1rem;
  font-size: 0.9rem;
  text-align: center;
  color: #e5e7eb;
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.9);
}

body.light-theme .skill-card {
  background: rgba(255, 255, 255, 0.9);
  color: #0f172a;
}

/* Projects carousel */

.projects-carousel {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.75rem;
}

.projects-grid {
  display: flex;
  gap: 1.4rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding: 20px;
  padding-bottom: 10px;
}

.projects-grid::-webkit-scrollbar {
  height: 8px;
}

.projects-grid::-webkit-scrollbar-thumb {
  background: rgba(0, 245, 255, 0.4);
  border-radius: 10px;
}

.project-card {
  min-width: 330px;
  max-width: 330px;
  flex-shrink: 0;
  scroll-snap-align: start;
  border-radius: 24px;
  border: 1px solid rgba(148, 163, 184, 0.25);
  padding: 1.25rem 1.3rem 1.3rem;
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.9);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}

.glass {
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.85), rgba(15, 23, 42, 0.7));
  backdrop-filter: blur(20px);
}

body.light-theme .glass {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(248, 250, 252, 0.92));
}

.project-card:hover {
  transform: translateY(-8px) scale(1.03);
  box-shadow: var(--shadow-accent);
  border-color: rgba(0, 245, 255, 0.6);
}

.project-icon {
  font-size: 32px;
  color: var(--accent);
  margin-bottom: 8px;
}

.badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 6px 0 14px 0;
}

.badge {
  background: var(--accent-soft);
  color: var(--accent);
  padding: 4px 10px;
  font-size: 11px;
  border-radius: 999px;
  border: 1px solid rgba(0, 245, 255, 0.3);
}

.project-card h3 {
  font-size: 1.05rem;
  margin-bottom: 0.4rem;
}

.project-card p {
  color: var(--muted);
  font-size: 0.9rem;
  margin-bottom: 0.8rem;
  line-height: 1.6;
}

.project-link {
  font-size: 0.9rem;
  color: var(--accent);
  text-decoration: none;
}

/* Scroll buttons */

.scroll-btn {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.4);
  background: rgba(15, 23, 42, 0.9);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #e5e7eb;
  cursor: pointer;
  box-shadow: 0 10px 25px rgba(15, 23, 42, 0.7);
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, border-color 0.18s ease;
}

body.light-theme .scroll-btn {
  background: rgba(255, 255, 255, 0.96);
  color: #0f172a;
}

.scroll-btn:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
  box-shadow: 0 14px 28px rgba(15, 23, 42, 0.8);
}

/* Contact */

.contact-content {
  display: grid;
  gap: 1.6rem;
}

@media (min-width: 768px) {
  .contact-content {
    grid-template-columns: 0.9fr 1.1fr;
    align-items: start;
  }
}

.contact-content p {
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.65;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.form-row {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}

.form-row input,
.contact-form textarea {
  width: 100%;
}

@media (min-width: 600px) {
  .form-row {
    flex-direction: row;
  }

  .form-row input {
    flex: 1;
  }
}

.contact-form input,
.contact-form textarea {
  background: #020617;
  border: 1px solid rgba(148, 163, 184, 0.5);
  border-radius: 14px;
  padding: 0.75rem 0.85rem;
  font-size: 0.9rem;
  color: #e5e7eb;
  outline: none;
}

body.light-theme .contact-form input,
body.light-theme .contact-form textarea {
  background: rgba(255, 255, 255, 0.96);
  color: #0f172a;
}

.contact-form input:focus,
.contact-form textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent-soft);
}

/* Footer */

.footer {
  padding: 2rem 0 2.4rem;
}

.footer-container {
  text-align: center;
  color: var(--muted);
  font-size: 0.85rem;
}

/* Responsive hero */

@media (max-width: 900px) {
  .hero-container {
    grid-template-columns: minmax(0, 1fr);
    padding: 2.3rem 1.9rem 2.5rem;
  }

  .hero-image {
    margin-top: 1.8rem;
  }

  .hero-description {
    max-width: none;
  }
}

@media (max-width: 640px) {
  .hero {
    padding-top: 3.2rem;
  }

  .hero-container {
    padding: 2rem 1.5rem 2.2rem;
  }

  .section-container {
    padding: 2rem 1.6rem 2.1rem;
  }

  .projects-carousel {
    grid-template-columns: minmax(0, 1fr);
  }

  .scroll-btn {
    display: none;
  }
}

/* Reveal on scroll (Framer-like) */

.reveal {
  opacity: 0;
  transform: translateY(18px) scale(0.98);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* Keyframes */

@keyframes floatY {
  0% { transform: translateY(0px); }
  50% { transform: translateY(-12px); }
  100% { transform: translateY(0px); }
}

@keyframes orbit {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.contact-link {
  color: var(--accent);
  text-decoration: none;
}
.contact-link:hover {
  text-decoration: underline;
}


.education-list {
  display: grid;
  gap: 1.4rem;
}

.education-item {
  padding: 1.4rem 1.6rem;
  border-radius: 18px;
  background: var(--glass);
  border: 1px solid rgba(148,163,184,0.35);
  box-shadow: 0 12px 28px rgba(15,23,42,0.85);
}

body.light-theme .education-item {
  background: rgba(255,255,255,0.92);
}

.edu-college {
  color: var(--muted);
  margin: 0.35rem 0;
}

.edu-grade {
  font-size: 0.93rem;
  color: var(--accent);
}



/* Toast Notifications */
#toastContainer {
  position: fixed;
  bottom: 25px;
  right: 25px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 9999;
}

.toast {
  padding: 12px 18px;
  border-radius: 12px;
  color: white;
  font-size: 0.9rem;
  animation: fadeInUp 0.4s ease, fadeOut 0.4s ease 3s forwards;
  box-shadow: 0 8px 20px rgba(0,0,0,0.3);
}

.toast-success { background: #10b981; }
.toast-error { background: #ef4444; }

@keyframes fadeInUp {
  0% { opacity: 0; transform: translateY(20px); }
  100% { opacity: 1; transform: translateY(0); }
}

@keyframes fadeOut {
  to { opacity: 0; transform: translateY(20px); }
}

/* Invalid input shake */
.input-error {
  border-color: #ef4444 !important;
  animation: shake 0.25s ease;
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  75% { transform: translateX(5px); }
}

/* Send button spinner */
.button-loading {
  position: relative;
  pointer-events: none;
  opacity: 0.8;
}

.button-loading::after {
  content: "";
  position: absolute;
  right: 18px;
  top: 50%;
  width: 16px;
  height: 16px;
  border: 3px solid white;
  border-top-color: transparent;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  transform: translateY(-50%);
}

@keyframes spin {
  to { transform: translateY(-50%) rotate(360deg); }
}



/* Education + Certification Grid */
.edu-cert-grid {
  display: grid;
  gap: 2rem;
}

@media (min-width: 768px) {
  .edu-cert-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.education-box, .certifications-box {
  padding: 1.6rem 1.8rem;
  border-radius: 22px;
  border: 1px solid var(--border);
  background: var(--glass);
  box-shadow: var(--shadow-soft);
}

.education-item, .cert-item {
  background: rgba(255,255,255,0.04);
  padding: 0.9rem 1rem;
  margin-bottom: 0.8rem;
  border-radius: 14px;
  border: 1px solid var(--border);
}

.cert-item {
  display: flex;
  gap: 0.6rem;
  align-items: center;
}

.cert-icon {
  color: var(--accent);
  font-size: 1rem;
}

