:root {
  --bg: #0f1724;
  --card: #ffffff;
  --muted: #7b7f8b;
  --accent: #00d4ff;
  --accent-2: #6a8cff;
  --text: #0b1220;
  --glass: rgba(255, 255, 255, 0.06);
  --radius: 12px;
  --maxw: 1100px;
}

/* Light theme variables (default) */
:root[data-theme="light"] {
  --bg: linear-gradient(135deg, #f7f9fc, #eef6ff);
  --card: #ffffff;
  --muted: #6b7280;
  --accent: #4facfe;
  --accent-2: #00f2fe;
  --text: #071022;
  --glass: rgba(10, 14, 20, 0.03);
}

/* Dark theme overrides */
:root[data-theme="dark"] {
  --bg: linear-gradient(135deg, #0f1724, #121827);
  --card: #0b1220;
  --muted: #9aa3b2;
  --accent: #00d4ff;
  --accent-2: #6a8cff;
  --text: #e6eef8;
  --glass: rgba(255, 255, 255, 0.03);
}

/* Reset + Base */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  height: 100%;
}

body {
  font-family: "Poppins", system-ui, -apple-system, Segoe UI, Roboto, "Helvetica Neue", Arial;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.5;
}

.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 20px;
}



/* NAV */
.site-header {
  backdrop-filter: blur(6px);
  position: sticky;
  top: 0;
  z-index: 80;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 12px;
}

.brand {
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--accent);
}

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

.nav-link {
  color: var(--text);
  text-decoration: none;
  padding: 8px 10px;
  border-radius: 8px;
  transition: all .18s;
}

.nav-link:hover {
  background: var(--glass);
}

.controls {
  display: flex;
  gap: 8px;
  align-items: center;
}

.icon-btn {
  background: transparent;
  border: 0;
  color: var(--text);
  font-size: 18px;
  cursor: pointer;
  padding: 6px;
  border-radius: 8px;
}

.hamburger {
  display: none;
}

.nav-link.active {
  color: var(--accent);
  /* highlighted link color */
  font-weight: 600;
}


/* S Logo in Nav */
#s-logo {
  width: 50px;
  /* smaller for nav */
  height: 50px;
  cursor: pointer;
  /* shows it's interactive */
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s ease;
}

/* Hover effect: slight scale and color glow */
#s-logo:hover {
  transform: scale(1.15);
}

/* Optional: Responsive for mobile nav */
@media (max-width: 768px) {
  #s-logo {
    width: 40px;
    height: 40px;
  }
}

.logo-brand {
  display: flex;
  align-items: center;
  gap: 6px;
  /* space between logo and text */
}



/* ===== Hero Section ===== */
header.hero {
  background: linear-gradient(135deg, #6a11cb 0%, #2575fc 100%);
  color: #fff;
  text-align: center;
  padding: 80px 20px;
}

header.hero h1 {
  font-size: 2.8rem;
  margin-bottom: 15px;
  font-weight: 700;
}

header.hero p {
  font-size: 1.2rem;
  color: #e0e0e0;
}

/* ===== Filters ===== */
.filters-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 15px;
  padding: 30px 20px;
  background: #fff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
  margin: -40px auto 40px;
  max-width: 1200px;
  border-radius: 12px;
  box-sizing: border-box;
}

.filters-container input,
.filters-container select {
  flex: 0 0 200px;
  min-width: 150px;
  max-width: 220px;
  padding: 10px 15px;
  font-size: 1rem;
  border-radius: 8px;
  border: 1px solid #ccc;
  outline: none;
  transition: all 0.3s ease;
  box-sizing: border-box;
}

.filters-container input:focus,
.filters-container select:focus {
  border-color: #2575fc;
  box-shadow: 0 0 8px rgba(37, 117, 252, 0.3);
}

/* ===== Projects Grid ===== */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  max-width: 1200px;
  margin: 0 auto 60px;
  padding: 0 20px;
  box-sizing: border-box;
}

/* ===== Project Card ===== */
.project-card {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  transition: transform 0.3s, box-shadow 0.3s;
  cursor: pointer;
}

.project-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
}

/* Project Image */
.project-card .project-img-wrapper {
  position: relative;
  overflow: hidden;
}

.project-card .project-img {
  width: 100%;
  height: auto;
  max-height: 200px;
  object-fit: cover;
  transition: transform 0.3s;
}

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

/* Overlay for buttons */
.project-card .project-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(37, 117, 252, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s;
}

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

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

.project-card .btn-small {
  padding: 8px 12px;
  background: #fff;
  color: #2575fc;
  font-size: 0.9rem;
  border-radius: 6px;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: background 0.3s, color 0.3s;
}

.project-card .btn-small:hover {
  background: #2575fc;
  color: #fff;
}

/* Project Content */
.project-card .project-name {
  font-size: 1.2rem;
  font-weight: 600;
  color: #2575fc;
  padding: 12px 16px 5px 16px;
}

.project-card .project-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0 16px 12px 16px;
}

.project-card .project-meta span {
  font-size: 0.8rem;
  background: #e0e0e0;
  color: #333;
  padding: 4px 8px;
  border-radius: 6px;
}

/* ===== Modal ===== */
#screenshotModal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  align-items: center;
  justify-content: center;
  overflow: auto;
  padding: 20px;
  box-sizing: border-box;
}

#modalContent {
  position: relative;
  max-width: 90%;
  max-height: 90%;
  width: auto;
  border-radius: 12px;
  overflow: auto;
  display: flex;
  justify-content: center;
  align-items: center;
}

#modalImg {
  width: auto;
  max-width: 100%;
  max-height: 100%;
  display: block;
  border-radius: 12px;
}

/* Close Button */
#modalClose {
  position: absolute;
  top: 10px;
  right: 20px;
  color: #ff4d4d;
  font-size: 2rem;
  font-weight: 700;
  cursor: pointer;
  transition: 0.3s;
  z-index: 10;
}

#modalClose:hover {
  color: #ff1a1a;
}

/* ===== Responsive ===== */
@media (max-width: 1024px) {
  #modalContent {
    max-width: 95%;
    max-height: 95%;
  }
}

@media (max-width: 768px) {
  header.hero h1 {
    font-size: 2.2rem;
  }

  header.hero p {
    font-size: 1.1rem;
  }

  .filters-container {
    flex-direction: column;
    gap: 12px;
    margin: 20px auto 30px;
  }

  .filters-container input,
  .filters-container select {
    flex: 1 1 100%;
    max-width: 100%;
  }

  .projects-grid {
    gap: 15px;
  }

  .project-card .project-img {
    max-height: 180px;
  }
}

@media (max-width: 480px) {
  header.hero h1 {
    font-size: 1.8rem;
  }

  header.hero p {
    font-size: 1rem;
  }

  .filters-container {
    flex-direction: column;
    gap: 10px;
  }

  .filters-container input,
  .filters-container select {
    width: 100%;
    max-width: 100%;
  }

  .projects-grid {
    grid-template-columns: 1fr;
  }

  .project-card .project-img {
    max-height: 150px;
  }
}




/* Professional Footer Design */
/* Footer */
.site-footer {
  background: var(--card);
  color: var(--text);
  padding: 60px 20px 30px;
  font-family: 'Poppins', sans-serif;
  border-top: 2px solid var(--accent-2);
  backdrop-filter: blur(8px);
  border-radius: var(--radius);
}

/* Footer Container */
.footer-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 35px;
  max-width: var(--maxw);
  margin: 0 auto 30px;
}

/* Footer Cards */
.footer-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-card h4 {
  font-size: 1.15rem;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 10px;
  position: relative;
}

.footer-card h4::after {
  content: '';
  display: block;
  width: 50px;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  margin-top: 6px;
  border-radius: 2px;
}

.footer-card ul {
  list-style: none;
  padding: 0;
}

.footer-card li {
  margin-bottom: 8px;
}

.footer-card a {
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
  transition: all 0.3s;
}

.footer-card a:hover {
  color: var(--accent-2);
  transform: translateX(4px);
}

.footer-card p {
  color: var(--muted);
  margin-bottom: 6px;
}

/* Social Icons */
.social-icons {
  display: flex;
  gap: 12px;
  margin-top: 6px;
}

.social-icons a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  font-size: 1.3rem;
  border-radius: 50%;
  background: var(--glass);
  color: var(--text);
  transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s;
}

.social-icons a i {
  color: inherit;
}

/* Brand colors on hover */
.social-icons a[aria-label="GitHub"]:hover {
  background: #181717;
  color: #fff;
}

.social-icons a[aria-label="LinkedIn"]:hover {
  background: #0077B5;
  color: #fff;
}

.social-icons a[aria-label="Twitter"]:hover {
  background: #1DA1F2;
  color: #fff;
}

.social-icons a:hover {
  transform: translateY(-3px) scale(1.1);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.15);
}

/* Footer Bottom */
.footer-bottom {
  text-align: center;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
  padding-top: 16px;
  color: var(--muted);
  font-size: 0.9rem;
  margin-top: 20px;
}

/* Responsive Footer */
@media (max-width: 700px) {
  .footer-container {
    grid-template-columns: 1fr;
    text-align: center;
  }

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

  .footer-card h4::after {
    margin: 6px auto 0;
  }
}


/* Responsive */
@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .profile-card {
    flex-direction: column;
    align-items: center;
  }

  .form-row {
    flex-direction: column;
  }

  .about-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 1.6rem;
  }

  .hero-sub {
    font-size: 1rem;
  }
}

/* ---------------- MOBILE NAV ---------------- */
@media (max-width: 768px) {

  /* Hide normal nav */
  .nav {
    display: none;
  }

  /* Show hamburger */
  .hamburger {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 27px;
    height: 22px;
    cursor: pointer;
    padding: 0;
    position: relative;
    font-size: 0;
    z-index: 2100;
  }

  .hamburger span {
    display: block;
    height: 3px;
    width: 100%;
    background: #53575f;
    border-radius: 4px;
    transition: all 0.3s ease;
  }

  /* Hamburger animation (X) */
  .hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }

  .hamburger.active span:nth-child(2) {
    opacity: 0;
  }

  .hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
  }

  /* Mobile nav container */
  .nav.mobile-active {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
    gap: 12px;

    position: fixed;
    top: 0;
    right: -100%;
    width: 70%;
    height: 100vh;

    background: var(--bg);
    backdrop-filter: blur(12px);
    padding: 80px 24px 24px;

    transition: right 0.4s ease;
    z-index: 2000;
    border-left: 1px solid rgba(255, 255, 255, 0.08);
  }

  .nav.mobile-active.show {
    right: 0;
  }

  /* Mobile nav links */
  .nav.mobile-active .nav-link {
    width: 100%;
    font-size: 1.05rem;
    padding: 12px 16px;
    border-radius: var(--radius);
    color: var(--text);
    text-decoration: none;
    transition: background 0.25s, color 0.25s, transform 0.2s;
  }

  .nav.mobile-active .nav-link:hover {
    background: var(--glass);
    color: var(--accent);
    transform: scale(1.03);
  }

  /* Nav row spacing */
  .nav-row {
    justify-content: space-between;
    align-items: center;
  }

}

/* Prevent body scroll when nav is open */
body.no-scroll {
  overflow: hidden;
  height: 100%;
}


/* Back Button Container - Centered Horizontally */
.back-btn {
  margin: 20px auto;
  /* top/bottom margin 20px, auto left/right to center */
  text-align: center;
  /* center the child inline element (.btn) */
  position: relative;
  /* keeps it in page flow */
  z-index: 100;
}


/* Button Style */
.back-btn .btn {
  display: inline-block;
  padding: 10px 18px;
  background: var(--accent);
  color: #fff;
  font-size: 0.95rem;
  font-weight: 500;
  border-radius: var(--radius);
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Hover Effect */
.back-btn .btn:hover {
  background-color: #00d4ff;
  /* new hover color */
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 212, 255, 0.3);
  /* optional glow */
}