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

body {
  font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu,
    Cantarell, sans-serif;
  background: #0a0a0a;
  color: #fff;
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
}

.icon {
  width: 20px;
  height: 20px;
}

.hidden {
  display: none;
}

/* Floating Classroom Chat Owl */
.floating-owl {
  position: fixed;
  top: 24px;
  left: 24px;
  z-index: 100;
  width: 95px;
  background: transparent;
  border: none;
  padding: 0;
  margin: 0;
  display: block;
  text-decoration: none;
  cursor: pointer;
  animation: owlFloat 3.5s ease-in-out infinite;
  user-select: none;
  -webkit-user-drag: none;
  -webkit-tap-highlight-color: transparent;
}

@keyframes owlFloat {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-8px);
  }
}

.floating-owl-img {
  display: block;
  width: 100%;
  height: auto;
  background: transparent;
  filter: drop-shadow(0 6px 14px rgba(14, 178, 187, 0.4));
  transition:
    transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1),
    filter 0.3s ease;
  will-change: transform, filter;
  pointer-events: auto;
}

.floating-owl:hover .floating-owl-img {
  transform: scale(1.12) rotate(4deg);
  filter: drop-shadow(0 12px 24px rgba(14, 178, 187, 0.65)) drop-shadow(0 0 10px rgba(0, 123, 255, 0.4));
}

.floating-owl:active .floating-owl-img {
  transform: scale(0.95);
}

.floating-owl:focus-visible {
  outline: 2px dashed #0eb2bb;
  outline-offset: 6px;
  border-radius: 12px;
}

@media (max-width: 768px) {
  .floating-owl {
    top: 16px;
    left: 16px;
    width: 72px;
  }
}

@media (max-width: 480px) {
  .floating-owl {
    top: 12px;
    left: 12px;
    width: 58px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .floating-owl {
    animation: none;
  }
  .floating-owl-img {
    transition: none;
  }
}

/* Navigation */
.nav {
  position: fixed;
  top: 48px;
  left: 0;
  right: 0;
  z-index: 50;
  background: rgba(17, 17, 17, 0.8);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border-bottom: 1px solid #2a2a2a;
}

.nav.top-zero {
  top: 0 !important;
  transition: top 0.3s ease; /* Smooth transition when banner closes */
}

.nav-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-size: 48px;
  font-weight: 700;
  background: linear-gradient(90deg, #0eb2bb, #007bff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  cursor: pointer;
  transition: transform 0.3s;
}

.nav-logo:hover {
  transform: scale(1.05);
}

.nav-links {
  display: none;
  gap: 32px;
}

@media (min-width: 768px) {
  .nav-links {
    display: flex;
  }
}

.nav-link {
  color: #ccc;
  text-decoration: none;
  transition: all 0.3s;
  position: relative;
}

.nav-link:hover {
  color: #0eb2bb;
  transform: scale(1.1);
}

.mobile-menu-btn {
  display: block;
  background: none;
  border: none;
  color: #ccc;
  padding: 8px;
  cursor: pointer;
}

@media (min-width: 768px) {
  .mobile-menu-btn {
    display: none;
  }
}

.mobile-menu {
  display: none;
  padding: 16px 0;
}

.mobile-menu.active {
  display: block;
}

.mobile-link {
  display: block;
  padding: 12px 24px;
  color: #ccc;
  text-decoration: none;
  transition: all 0.3s;
}

.mobile-link:hover {
  color: #fff;
  background: #2a2a2a;
  border-radius: 8px;
}

/* Hero */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  position: relative;
  animation: fadeIn 0.6s ease;
}

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

.hero-content {
  max-width: 1000px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 48px;
}

@media (min-width: 768px) {
  .hero-content {
    flex-direction: row;
  }
}

.hero-image {
  flex-shrink: 0;
  animation: scaleIn 0.8s ease 0.2s both;
}

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

.hero-image img {
  width: 256px;
  height: 256px;
  border-radius: 50%;
  border: 4px solid #0eb2bb;
  box-shadow: 0 0 30px rgba(14, 178, 187, 0.3);
  object-fit: cover;
}

.hero-text {
  flex: 1;
  text-align: center;
}

@media (min-width: 768px) {
  .hero-text {
    text-align: left;
  }
}

.hero-title {
  font-size: 48px;
  font-weight: 700;
  margin-bottom: 24px;
  background: linear-gradient(90deg, #0eb2bb, #007bff, #006666);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.2;
  animation: fadeIn 0.8s ease 0.3s both;
}

@media (min-width: 768px) {
  .hero-title {
    font-size: 64px;
  }
}

.hero-subtitle {
  font-size: 24px;
  margin-bottom: 16px;
  animation: fadeIn 1s ease 0.5s both;
}

@media (min-width: 768px) {
  .hero-subtitle {
    font-size: 32px;
  }
}

.hero-tagline {
  font-size: 18px;
  color: #999;
  margin-bottom: 32px;
  animation: fadeIn 1s ease 0.7s both;
}

.hero-social {
  display: flex;
  gap: 16px;
  justify-content: center;
  margin-bottom: 32px;
  animation: fadeIn 1s ease 0.9s both;
}

@media (min-width: 768px) {
  .hero-social {
    justify-content: flex-start;
  }
}

.social-link {
  padding: 12px;
  background: #2a2a2a;
  border-radius: 50%;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s;
  border: 1px solid transparent;
}

.social-link:hover {
  background: rgba(14, 178, 187, 0.2);
  border-color: #0eb2bb;
  transform: scale(1.1);
}

.hero-btn {
  padding: 12px 32px;
  background: linear-gradient(90deg, #0eb2bb, #007bff);
  border: none;
  border-radius: 50px;
  color: white;
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s;
  animation: fadeIn 1s ease 1.1s both;
}

.hero-btn:hover {
  box-shadow: 0 8px 20px rgba(14, 178, 187, 0.5);
  transform: scale(1.05);
}

.scroll-indicator {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  color: #999;
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%,
  100% {
    transform: translateX(-50%) translateY(0);
  }
  50% {
    transform: translateX(-50%) translateY(10px);
  }
}

/* Sections */
.section {
  padding: 128px 24px;
}

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

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

.section-header {
  text-align: center;
  margin-bottom: 48px;
}

.section-title {
  font-size: 40px;
  font-weight: 700;
  margin-bottom: 16px;
}

@media (min-width: 768px) {
  .section-title {
    font-size: 56px;
  }
}

.section-subtitle {
  color: #999;
  max-width: 640px;
  margin: 0 auto;
}

/* Projects */
.projects-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

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

.project-card {
  background: rgba(42, 42, 42, 0.5);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  border-radius: 12px;
  padding: 24px;
  border: 1px solid #3a3a3a;
  transition: all 0.3s;
  position: relative;
  overflow: hidden;
  cursor: pointer;
}

.project-card:hover {
  border-color: #555;
  transform: translateY(-4px);
}

.project-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  color: #ffc107;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.project-badge .icon {
  width: 16px;
  height: 16px;
}

.project-title-row {
  display: flex;
  margin-bottom: 12px;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
}

.project-title-row .project-title {
  margin-bottom: 0;
  flex: 1;
}

.project-title {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 12px;
}

.project-desc {
  color: #999;
  margin-bottom: 16px;
  line-height: 1.6;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

.tag {
  padding: 6px 12px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 50px;
  font-size: 12px;
  color: #ccc;
  transition: background 0.3s;
}

.tag:hover {
  background: rgba(255, 255, 255, 0.1);
}

.project-links {
  display: flex;
  gap: 16px;
}

.btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: 8px;
  text-decoration: none;
  font-size: 14px;
  transition: all 0.3s;
  border: none;
  cursor: pointer;
}

.btn-primary {
  background: linear-gradient(90deg, #0eb2bb, #007bff);
  color: white;
}

.btn-primary:hover {
  box-shadow: 0 4px 12px rgba(14, 178, 187, 0.5);
  transform: scale(1.05);
}

.btn-secondary {
  background: #3a3a3a;
  color: white;
}

.btn-secondary:hover {
  background: #4a4a4a;
}

.project-logo {
  width: 48px;
  height: 48px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.project-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* Skills */
.skills-svg-container {
  max-width: 800px;
  margin: 0 auto;
}

.tech-stack-svg {
  width: 100%;
  height: auto;
  display: block;
  overflow: visible;
}

.band-bg-1 {
  fill: #1a1a1a;
  stroke: #333;
}

.band-bg-2 {
  fill: #222;
  stroke: #333;
}

.band-inner {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 12px;
  font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
}

.eyebrow {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #888;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.chip {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border: 1px solid #333;
  border-radius: 8px;
  background: #2a2a2a;
}

.chip .tag-icon {
  font-size: 20px;
  height: 20px;
  width: auto;
  margin: 0;
  filter: drop-shadow(0 0 2px rgba(255, 255, 255, 0.4));
}

.chip:hover .tag-icon {
  transform: scale(1.1);
  filter: drop-shadow(0 0 2px rgba(255, 255, 255, 0.8));
}

.chip span {
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  white-space: nowrap;
}

.chip .tag-icon.invert-img {
  filter: invert(1);
}

@media (prefers-color-scheme: light) {
  .band-bg-1 {
    fill: #ffffff;
    stroke: #e7e7e5;
  }

  .band-bg-2 {
    fill: #f5f5f3;
    stroke: #e7e7e5;
  }

  .eyebrow {
    color: #b3b3ae;
  }

  .chip {
    background: #ffffff;
    border: 1px solid #e7e7e5;
  }

  .chip span {
    color: #151515;
  }

  .chip .tag-icon.invert-img {
    filter: none;
  }
}

/* Footer */
.footer {
  padding: 48px 24px;
  border-top: 1px solid #2a2a2a;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

@media (min-width: 768px) {
  .footer-content {
    flex-direction: row;
  }
}

.footer-left {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #999;
}

.footer-left .heart {
  color: #ef4444;
  fill: #ef4444;
}

.footer-social {
  display: flex;
  gap: 16px;
}

.footer-link {
  padding: 8px;
  color: #999;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
}

.footer-link:hover {
  color: white;
  background: #2a2a2a;
}
@media (prefers-color-scheme: light) {
  body {
    background: #f9f9f9;
    color: #222;
  }
  .nav {
    background: rgba(255, 255, 255, 0.8);
    border-bottom: 1px solid #e0e0e0;
  }
  .nav-link,
  .mobile-menu-btn,
  .mobile-link,
  .hero-tagline,
  .section-subtitle,
  .project-desc,
  .footer-left,
  .footer-link {
    color: #555;
  }
  .mobile-link:hover,
  .footer-link:hover {
    color: #111;
    background: #eaeaea;
  }
  .social-link {
    background: #eaeaea;
    color: #333;
  }
  .social-link:hover {
    background: rgba(14, 178, 187, 0.1);
  }
  .btn-secondary {
    background: #eaeaea;
    color: #333;
  }
  .btn-secondary:hover {
    background: #d4d4d4;
  }
  .project-card {
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid #e0e0e0;
  }
  .skill-card {
    background: #f9f9f9;
    border: 2px solid #999;
    box-shadow:
      0 15px 0 #d0d0d0,
      0 20px 15px rgba(0, 0, 0, 0.1);
  }
  .skill-title {
    color: #222;
  }
  .project-card:hover {
    border-color: #bbb;
  }
  .skill-card:hover {
    box-shadow:
      0 17px 0 #d0d0d0,
      0 22px 20px rgba(0, 0, 0, 0.15);
  }
  .tag {
    background: rgba(0, 0, 0, 0.05);
    color: #555;
  }
  .tag:hover {
    background: rgba(0, 0, 0, 0.1);
  }
  .section-alt {
    background: rgba(0, 0, 0, 0.03);
  }
  .footer {
    border-top: 1px solid #e0e0e0;
  }
  
  .tag-icon {
    filter: grayscale(100%) opacity(0.7);
  }
  .tag-icon:hover {
    filter: grayscale(0%) opacity(1);
  }
  .skill-tags .tag-icon,
  .chip .tag-icon {
    filter: none;
  }
  .skill-tags .tag-icon:hover,
  .chip:hover .tag-icon {
    filter: none;
  }
}

/* Lightbox Styles */
#lightbox {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
}
#lightbox.hidden {
  display: none !important;
}
#lightboxBackdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
}
#lightboxContent {
  position: relative;
  z-index: 10000;
  max-width: 90vw;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}
#lightboxHeader {
  display: flex;
  justify-content: space-between;
  width: 100%;
  color: white;
  padding: 10px;
  background: rgba(0, 0, 0, 0.5);
}
#lightboxClose,
#lightboxPrev,
#lightboxNext {
  background: none;
  border: none;
  color: white;
  cursor: pointer;
  font-size: 2rem;
}
#lightboxPrev {
  position: absolute;
  left: -50px;
  top: 50%;
  transform: translateY(-50%);
}
#lightboxNext {
  position: absolute;
  right: -50px;
  top: 50%;
  transform: translateY(-50%);
}
.lightbox-counter {
  margin-right: 15px;
}
.lightbox-img-container {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
}
.lightbox-img {
  max-width: 100%;
  max-height: 80vh;
  object-fit: contain;
}

@media (max-width: 768px) {
  #lightboxPrev {
    left: 10px;
    text-shadow: 0 0 5px black;
  }
  #lightboxNext {
    right: 10px;
    text-shadow: 0 0 5px black;
  }
  .nav {
    display: none !important;
  }
}

/* Access Modal Styles */
.access-modal {
  padding: 2rem;
  border-radius: 8px;
  border: none;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  max-width: 400px;
  text-align: center;
  margin: auto;
}
.access-modal-title {
  margin-bottom: 1rem;
  color: #1f2937;
  font-size: 1.5rem;
}
.access-modal-desc {
  margin-bottom: 1.5rem;
  color: #4b5563;
  line-height: 1.5;
}
.access-modal-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
}
.access-modal-link {
  text-decoration: none;
}

.tag-icon {
  font-size: 24px;
  height: 24px;
  width: auto;
  display: inline-block;
  vertical-align: middle;
  filter: drop-shadow(0 0 2px rgba(255, 255, 255, 0.4)) grayscale(100%) opacity(0.7);
  transition:
    transform 0.2s ease,
    filter 0.2s ease;
}

.tag-icon:hover {
  transform: scale(1.1);
  filter: drop-shadow(0 0 3px rgba(255, 255, 255, 0.8)) grayscale(0%) opacity(1);
}

.skill-tags .tag-icon {
  font-size: 48px;
  height: 48px;
  filter: drop-shadow(0 0 4px rgba(255, 255, 255, 0.4));
  opacity: 1;
}

.skill-tags .tag-icon:hover {
  transform: scale(1.2);
  filter: drop-shadow(0 0 6px rgba(255, 255, 255, 0.8));
}

img.tag-icon.invert-img {
  filter: invert(0.8) grayscale(100%) opacity(0.7);
}

img.tag-icon.invert-img:hover {
  filter: invert(1) grayscale(0%) opacity(1);
}

.skill-tags img.tag-icon.invert-img {
  filter: invert(1);
  opacity: 1;
}

/* --- Scroll Animation Enhancements --- */
.animate-hidden {
  opacity: 0;
  transition: opacity 0.6s cubic-bezier(0.25, 1, 0.5, 1), transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
  will-change: opacity, transform;
}

.animate-hidden.slide-up {
  transform: translateY(40px);
}

.animate-hidden.slide-left {
  transform: translateX(40px);
}

.animate-hidden.slide-right {
  transform: translateX(-40px);
}

.animate-hidden.scale-up {
  transform: scale(0.85);
}

.animate-visible {
  opacity: 1;
  transform: translate(0, 0) scale(1) !important;
}
