:root {
  --bg-color: #0f172a;
  --text-color: #f8fafc;
  --accent-color: #818cf8;
  --accent-glow: rgba(129, 140, 248, 0.2);
  --secondary-text: #94a3b8;
  --card-bg: #1e293b;
  --nav-bg: rgba(15, 23, 42, 0.85);
  --nav-height: 80px;
  --font-main: "Outfit", sans-serif;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg-color);
  color: var(--text-color);
  font-family: var(--font-main);
  line-height: 1.6;
  overflow-x: hidden;
  /* Background Orbs for Glass Effect */
  background-image: 
    radial-gradient(circle at 15% 50%, rgba(129, 140, 248, 0.08), transparent 25%),
    radial-gradient(circle at 85% 30%, rgba(99, 102, 241, 0.08), transparent 25%);
  background-attachment: fixed;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}

ul {
  list-style: none;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* Navbar */
.navbar {
  height: var(--nav-height);
  display: flex;
  align-items: center;
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 1000;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

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

.logo {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent-color);
  letter-spacing: 1px;
}

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

.nav-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-color);
}

.nav-links a:hover {
  color: var(--accent-color);
}

/* Hero Section */
.hero {
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding-top: var(--nav-height);
  text-align: center;
}

.hero-container {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.subtitle {
  color: var(--accent-color);
  font-size: 1.2rem;
  margin-bottom: 1.5rem;
  display: block;
  font-weight: 500;
  letter-spacing: 2px;
}

.title {
  font-size: 5rem;
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 1.5rem;
  color: #f1f5f9;
  background: linear-gradient(to right, #f8fafc, #94a3b8);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.title span {
  opacity: 0;
  display: inline-block;
  animation: typeLetter 0.1s forwards;
  /* Ensure gradient text works on spans */
  background: inherit;
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

@keyframes typeLetter {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.role {
  font-size: 2.5rem;
  font-weight: 600;
  color: var(--secondary-text);
  margin-bottom: 2rem;
  line-height: 1.3;
}

.highlight {
  color: var(--accent-color);
}

.bio {
  max-width: 600px;
  font-size: 1.2rem;
  color: var(--secondary-text);
  margin-bottom: 3rem;
  line-height: 1.8;
}

.cta-group {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
}

.btn {
  padding: 1rem 2rem;
  border-radius: 4px;
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition);
}

.btn.primary {
  border: 1px solid var(--accent-color);
  color: var(--accent-color);
  background: transparent;
}

.btn.primary:hover {
  background: var(--accent-glow);
  box-shadow: 0 0 20px var(--accent-glow);
}

.btn.secondary {
  color: var(--text-color);
  border: 1px solid transparent;
}

.btn.secondary:hover {
  color: var(--accent-color);
}

/* Scroll Indicator */
.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  opacity: 0.7;
}

.mouse {
  width: 24px;
  height: 40px;
  border: 2px solid var(--secondary-text);
  border-radius: 20px;
  position: relative;
}

.mouse::before {
  content: "";
  position: absolute;
  top: 6px;
  left: 50%;
  transform: translateX(-50%);
  width: 4px;
  height: 4px;
  background-color: var(--accent-color);
  border-radius: 50%;
  animation: scroll 2s infinite;
}

@keyframes scroll {
  0% {
    transform: translate(-50%, 0);
    opacity: 1;
  }
  100% {
    transform: translate(-50%, 15px);
    opacity: 0;
  }
}

/* Sections */
.section {
  padding: 6rem 0;
}

.section-title {
  font-size: 2rem;
  margin-bottom: 3rem;
  display: flex;
  align-items: center;
  color: #f1f5f9;
}

.section-title::after {
  content: "";
  display: block;
  width: 200px;
  height: 1px;
  background-color: var(--secondary-text);
  opacity: 0.3;
  margin-left: 20px;
}

/* About */
.about-content {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 4rem;
}

.about-text p {
  margin-bottom: 1rem;
  color: var(--secondary-text);
}

.skills-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 0;
}

.skill-item {
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: var(--accent-color);
  padding: 0.5rem 1.5rem;
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 500;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
  transition: var(--transition);
}

.skill-item:hover {
  background: rgba(129, 140, 248, 0.2);
  transform: translateY(-2px);
}

/* Projects - Alternating Rows */
.projects-list {
  display: flex;
  flex-direction: column;
  gap: 6rem;
}

.project-row {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 4rem;
  align-items: center;
}

.project-row.reverse {
  grid-template-columns: 1fr 1.2fr;
  direction: rtl;
}

.project-social {
  background-image: url("images/social-dist.png");
}
.project-hoard {
  background-image: url("images/hoard-store.png");
}
.project-census {
  background-image: url("images/census.png");
}
.project-row.reverse .project-content {
  direction: ltr;
}

.project-image-container {
  height: 350px;
  width: 100%;
  border-radius: 12px;
  background-size: cover;
  background-position: center;
  position: relative;
  overflow: hidden;
  /* Glass Border Effect */
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.5);
  transition: var(--transition);
}

.project-row:hover .project-image-container {
  transform: translateY(-5px);
  box-shadow: 0 30px 50px -20px rgba(0, 0, 0, 0.6);
}

.project-image-container::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(15, 23, 42, 0.2);
  transition: var(--transition);
}

.project-row:hover .project-image-container::after {
  background: transparent;
}

.project-content {
  padding: 1rem;
}

.project-content h3 {
  color: var(--text-color);
  font-size: 2rem;
  margin-bottom: 1rem;
  font-weight: 700;
}

.project-content p {
  color: var(--secondary-text);
  font-size: 1.1rem;
  margin-bottom: 2rem;
  line-height: 1.7;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 2rem;
  font-size: 0.9rem;
  color: var(--accent-color);
  font-family: monospace;
}

.project-link {
  display: inline-flex;
  align-items: center;
  color: var(--text-color);
  font-size: 1rem;
  font-weight: 500;
  border-bottom: 1px solid var(--accent-color);
  padding-bottom: 2px;
}

.project-link:hover {
  color: var(--accent-color);
}

/* Contact */
.contact-text {
  max-width: 600px;
  color: var(--secondary-text);
  margin-bottom: 3rem;
  font-size: 1.1rem;
}

.big-btn {
  padding: 1.25rem 3rem;
  font-size: 1.1rem;
}

.footer {
  margin-top: 8rem;
  text-align: center;
  color: var(--secondary-text);
  font-size: 0.9rem;
}

.social-links {
  margin-top: 1rem;
  display: flex;
  justify-content: center;
  gap: 1.5rem;
}

.social-links a:hover {
  color: var(--accent-color);
}

/* Mobile Responsive */
.hamburger {
  display: none;
  cursor: pointer;
}

@media (max-width: 768px) {
  .title {
    font-size: 3rem;
  }
  .role {
    font-size: 2rem;
  }

  .hamburger {
    display: block;
    width: 30px;
    height: 24px;
    position: relative;
    z-index: 1001;
  }

  .hamburger span {
    display: block;
    width: 100%;
    height: 2px;
    background-color: var(--accent-color);
    margin-bottom: 6px;
    transition: var(--transition);
  }

  .nav-links {
    position: fixed;
    top: 0;
    right: 0;
    height: 100vh;
    width: 70%;
    background-color: var(--card-bg);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transform: translateX(100%);
    transition: var(--transition);
    box-shadow: -10px 0px 30px -15px rgba(2, 12, 27, 0.7);
  }

  .nav-links.active {
    transform: translateX(0);
  }

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

/* Timeline (Education & Experience) */
.timeline {
  position: relative;
  max-width: 800px;
  margin: 0 auto;
}

.timeline::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 2px;
  background: rgba(255, 255, 255, 0.1);
}

.timeline-item {
  position: relative;
  padding-left: 3rem;
  margin-bottom: 3rem;
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: -6px;
  top: 0;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--bg-color);
  border: 2px solid var(--accent-color);
}

.timeline-content {
  background: rgba(30, 41, 59, 0.4);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  padding: 2rem;
  border-radius: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.05);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
}

.timeline-content:hover {
  transform: translateX(10px);
  border-color: var(--accent-color);
}

.timeline-content .date {
  display: inline-block;
  font-size: 0.9rem;
  color: var(--accent-color);
  margin-bottom: 0.5rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.timeline-content h3 {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
  color: var(--text-color);
}

.timeline-content .institution {
  font-size: 1.1rem;
  color: var(--secondary-text);
  margin-bottom: 1rem;
  font-style: italic;
}

.timeline-content .details {
  font-size: 1rem;
  color: var(--secondary-text);
  line-height: 1.6;
}

.alt-bg {
  background-color: rgba(255, 255, 255, 0.02);
}

/* Page Intro */
.page-intro {
  color: var(--secondary-text);
  font-size: 1.2rem;
  max-width: 600px;
  margin-bottom: 4rem;
}

/* Photography Grid - Masonry Layout */
.photo-grid {
  column-count: 3;
  column-gap: 2rem;
}

@media (max-width: 768px) {
  .photo-grid {
    column-count: 2;
  }
}

@media (max-width: 480px) {
  .photo-grid {
    column-count: 1;
  }
}

.photo-item {
  break-inside: avoid;
  margin-bottom: 2rem;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
  transition: var(--transition);
  background: rgba(255, 255, 255, 0.03);
}

.photo-item img {
  width: 100%;
  height: auto;
  display: block;
}

.photo-item:hover {
  transform: translateY(-5px);
  border-color: var(--accent-color);
}

.photo-placeholder {
  width: 100%;
  height: 100%;
  background: linear-gradient(45deg, var(--card-bg), rgba(129, 140, 248, 0.1));
}

/* Blog List */
.blog-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 2rem;
}

.blog-card {
  background: rgba(30, 41, 59, 0.4);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.05);
  padding: 2rem;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.blog-card:hover {
  transform: translateY(-5px);
  border-color: var(--accent-color);
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
}

.blog-date {
  font-size: 0.85rem;
  color: var(--accent-color);
  margin-bottom: 0.5rem;
  display: block;
}

.blog-title {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--text-color);
  line-height: 1.3;
}

.blog-excerpt {
  color: var(--secondary-text);
  margin-bottom: 1.5rem;
  flex-grow: 1;
}

.blog-tags {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
  font-size: 0.85rem;
  color: var(--secondary-text);
}

.read-more {
  color: var(--accent-color);
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

/* Blog Post */
.blog-post {
  max-width: 800px;
  margin: 0 auto;
}

.back-link {
  display: inline-block;
  margin-bottom: 2rem;
  color: var(--secondary-text);
}

.back-link:hover {
  color: var(--accent-color);
}

.post-header {
  margin-bottom: 3rem;
  text-align: center;
}

.post-title {
  font-size: 3rem;
  margin: 1rem 0;
  background: linear-gradient(to right, #f8fafc, #94a3b8);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.post-content {
  color: var(--secondary-text);
  font-size: 1.1rem;
  line-height: 1.8;
}

.post-content h2 {
  color: var(--text-color);
  margin: 2rem 0 1rem;
  font-size: 1.8rem;
}

.post-content p {
  margin-bottom: 1.5rem;
}

.post-content pre {
  background: rgba(0, 0, 0, 0.3);
  padding: 1.5rem;
  border-radius: 8px;
  overflow-x: auto;
  margin: 2rem 0;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

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