/**
* Template Name: Folio - v2.1.0
* Template URL: https://bootstrapmade.com/folio-bootstrap-portfolio-template/
* Author: BootstrapMade.com
* License: https://bootstrapmade.com/license/
*/

/*--------------------------------------------------------------
# General
--------------------------------------------------------------*/
body {
  background: #1a1a2e !important;
  background-color: #1a1a2e !important;
  color: #898989;
  font-family: 'Poppins', helvetica;
  font-size: 15px;
  font-weight: 300;
  line-height: 20px;
  letter-spacing: 0.02em;
  overflow-x: hidden;
  margin: 0 auto;
  padding: 0;
  -ms-box-sizing: border-box;
  -o-box-sizing: border-box;
  box-sizing: border-box;
}

/*--------------------------------------------------------------
# Performance Optimizations
--------------------------------------------------------------*/
/* GPU acceleration for animated elements */
.btn-primary,
.btn-secondary,
.stat-item,
.arcade-card,
.arcade-card-inner,
.career-content,
.viewport-tab,
.gizmo-toggle,
.retro-menu-item {
  transform: translateZ(0);
  backface-visibility: hidden;
}

/* Hint browser about upcoming animations */
.btn-primary:hover,
.btn-secondary:hover,
.stat-item:hover,
.arcade-card:hover {
  will-change: transform, box-shadow;
}

/* Reduce motion for users who prefer it AND for performance */
/* Disabled prefers-reduced-motion to allow animations on all devices */
/* @media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  
  .particles,
  .particle {
    display: none !important;
  }
  
  Remove expensive backdrop-filter
  .viewport-toolbar,
  .viewport-stats,
  .viewport-scene-info,
  .stat-item,
  .career-content,
  .retro-sidebar,
  .arcade-card-inner,
  .popup_portfolio {
    backdrop-filter: none !important;
  }
} */

/*--------------------------------------------------------------
# Global Scrollbar Styling
--------------------------------------------------------------*/
/* WebKit browsers (Chrome, Safari, Edge) */
::-webkit-scrollbar {
  width: 12px;
  height: 12px;
}

::-webkit-scrollbar-track {
  background: rgba(26, 26, 46, 0.4);
  border-radius: 6px;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #667eea 0%, #764ba2 100%);
  border-radius: 6px;
  border: 2px solid rgba(26, 26, 46, 0.6);
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #7e8ff0 0%, #8d5cb8 100%);
  border: 2px solid rgba(26, 26, 46, 0.8);
}

::-webkit-scrollbar-corner {
  background: rgba(26, 26, 46, 0.4);
}

/* Firefox */
* {
  scrollbar-width: thin;
  scrollbar-color: #667eea rgba(26, 26, 46, 0.4);
}

h1, h2, h3, h4, h5, h6 {
  margin: 0;
}

h2 {
  color: #292929;
  font-weight: 600;
}

h4 {
  color: #292929;
  font-size: 14px;
  font-weight: 600;
}

a {
  color: #292929;
  text-decoration: none !important;
  transition: all 0.5s ease-in-out 0s;
}

a:hover {
  transition: all 0.5s ease-in-out 0s;
}

a:hover, a:focus {
  color: #b8a07e;
  text-decoration: underline;
}

nav ul li a {
  padding: 2px 0 0 0;
  position: relative;
  display: block;
  font-size: 12px;
  color: #999999;
  letter-spacing: 0.1em;
  font-weight: 500;
  line-height: 14px;
  text-transform: uppercase;
  transition: all 0.5s ease-in-out 0s;
}

p {
  margin: 25px 0;
  padding: 0;
  font-size: 15px;
  color: #999999;
  line-height: 28px;
}

::-moz-selection {
  background: #b8a07e;
  color: #fff;
}

::selection {
  background: #b8a07e;
  color: #fff;
}

.section-title {
  margin-bottom: 70px;
}

.section-title h2 {
  font-size: 25px;
  letter-spacing: 2px;
  text-transform: uppercase;
}

/*--------------------------------------------------------------
# Navbar
--------------------------------------------------------------*/
nav {
  position: fixed;
  background: #fff;
  z-index: 1000;
  width: 100%;
  padding: 20px;
  display: none;
  box-shadow: 0px 2px 92px 0px rgba(0, 0, 0, 0.18);
}

.nav-menu {
  float: right;
  line-height: 32px;
  margin-bottom: 0;
  padding-top: 16px;
}

nav ul li {
  float: left;
  margin-right: 15px;
  font-family: 'Poppins', sans-serif;
  font-size: 14px;
  margin-left: 40px;
}

nav ul li a {
  padding: 2px 0 0 0;
  position: relative;
  display: block;
  font-size: 14px;
  color: #999999;
  font-family: 'Poppins', helvetica;
  font-weight: 500;
  line-height: 16px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  text-transform: capitalize;
}

.responsive {
  display: none;
  font-size: 23px;
}

.active {
  color: #afafaf;
}

/*--------------------------------------------------------------
# Hero
--------------------------------------------------------------*/
#hero {
  background: url("../img/home-bg.jpg") repeat scroll center center/cover;
  height: 100vh;
  width: 100%;
}

#hero .hero-content {
  height: 100vh;
  text-align: left;
  width: 100%;
  display: flex;
  justify-content: center;
  flex-direction: column;
  padding-top: 100px; /* Always preserve 100px space from top */
  box-sizing: border-box;
}

.hero-content h1 {
  font-size: 40px;
  font-weight: 700;
  margin-bottom: 10px;
  text-transform: uppercase;
  color: #fff;
}

.hero-content p {
  font-size: 13px;
  letter-spacing: 3px;
  margin-top: 0;
  margin-bottom: 30px;
  text-transform: capitalize;
  color: #fff;
  font-weight: 500;
}

.hero-content .list-social li {
  float: left;
  margin-right: 20px;
}

.hero-content .list-social li i {
  color: #fff;
  font-size: 15px;
}

/*--------------------------------------------------------------
# Breadcrumbs
--------------------------------------------------------------*/

/*-----------------------------------------------------------------------------------*/
/*  About
/*-----------------------------------------------------------------------------------*/

/*--------------------------------------------------------------
# Services
--------------------------------------------------------------*/

.services-carousel .owl-stage-outer {
  overflow: hidden;
}

.services-carousel .owl-dots {
  margin-top: 5px;
  text-align: center;
}

.services-carousel .owl-dot {
  display: inline-block;
  margin: 0 5px;
  width: 12px !important;
  height: 12px !important;
  border-radius: 50%;
  border: 0;
  padding: 0 !important;
  background-color: #ddd;
  cursor: pointer;
}

.services-carousel .owl-dot.active {
  background-color: #b8a07e;
}

/*--------------------------------------------------------------
# Portfolio
--------------------------------------------------------------*/

#portfolio #portfolio-flters {
  padding: 0;
  margin: 0 auto 35px auto;
  list-style: none;
  text-align: center;
  border-radius: 50px;
  padding: 2px 15px;
}

#portfolio #portfolio-flters li {
  cursor: pointer;
  display: inline-block;
  padding: 10px 15px 8px 15px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  text-transform: uppercase;
  color: #999999;
  margin-bottom: 5px;
  transition: all 0.3s ease-in-out;
}

#portfolio #portfolio-flters li:hover, #portfolio #portfolio-flters li.filter-active {
  color: #b8a07e;
}

#portfolio #portfolio-flters li:last-child {
  margin-right: 0;
}

#portfolio .portfolio-item {
  margin-bottom: 30px;
}

#portfolio .portfolio-item .portfolio-info {
  opacity: 0;
  position: absolute;
  left: 30px;
  right: 30px;
  bottom: 0;
  z-index: 3;
  transition: all ease-in-out 0.3s;
  background: rgba(255, 255, 255, 0.9);
  padding: 15px;
}

#portfolio .portfolio-item .portfolio-info h4 {
  font-size: 18px;
  color: #666;
  font-weight: 600;
  margin-bottom: 10px;
}

#portfolio .portfolio-item .portfolio-info p {
  color: #999;
  font-size: 14px;
  margin: 0;
  padding: 0;
}

#portfolio .portfolio-item .portfolio-info .preview-link, #portfolio .portfolio-item .portfolio-info .details-link {
  position: absolute;
  right: 40px;
  font-size: 24px;
  top: calc(50% - 18px);
  color: #b8a07e;
}

#portfolio .portfolio-item .portfolio-info .preview-link:hover, #portfolio .portfolio-item .portfolio-info .details-link:hover {
  color: #cab89f;
}

#portfolio .portfolio-item .portfolio-info .details-link {
  right: 10px;
}

#portfolio .portfolio-item:hover .portfolio-info {
  opacity: 1;
  bottom: 20px;
}

/*--------------------------------------------------------------
# Portfolio Details
--------------------------------------------------------------*/

.portfolio-details .portfolio-details-carousel {
  position: relative;
  z-index: 1;
}

.portfolio-details .portfolio-details-carousel .owl-nav, .portfolio-details .portfolio-details-carousel .owl-dots {
  margin-top: 5px;
  text-align: left;
}

.portfolio-details .portfolio-details-carousel .owl-dot {
  display: inline-block;
  margin: 0 10px 0 0;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background-color: #ddd !important;
}

.portfolio-details .portfolio-details-carousel .owl-dot.active {
  background-color: #b8a07e !important;
}

/*--------------------------------------------------------------
# Journal
--------------------------------------------------------------*/

/*--------------------------------------------------------------
# Journal
--------------------------------------------------------------*/

@-webkit-keyframes animate-loading {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

@keyframes animate-loading {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/*--------------------------------------------------------------
# Blog
--------------------------------------------------------------*/
/*  Navbar fixd page */
.subpage-nav {
  display: block !important;
}

/*-----------------------------------------------------------------------------------*/
/*  /* Single page */
/*-----------------------------------------------------------------------------------*/

/* main content */

/* Commonts */

/* Commonts form */

blockquote {
  padding: 40px;
  background-color: #f2f2f2;
  margin: 30px 0;
  border: none;
  border-left: 4px solid #b8a07e;
}

/*--------------------------------------------------------------
# Footer
--------------------------------------------------------------*/

/** Width between 1200x to 0
 *  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 */
/** Width between 992px to 1199px
 *  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 */
/** Width between 768px to 991px
 *  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 */
@media (min-width: 768px) and (max-width: 991px) {
  /* Navbar */
  nav {
    padding: 10px 15px;
  }
  .nav-menu {
    margin-top: 40px;
    display: none;
    float: none;
    width: 100%;
  }
  .nav-menu li {
    float: none;
    width: 100%;
    text-align: center;
    border-top: 1px solid #f7f7f7;
    line-height: 45px;
    margin-left: 0;
    padding-top: 10px;
    padding-bottom: 10px;
  }
  .responsive {
    float: right;
    padding-top: 15px;
    display: block;
  }
  /* About */

  /* portfolio */
  
  /* journal */
  
  /* Contact */
  
  /* Footer */
  
}

/** Width between 767px to 0
 *  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 */
@media (max-width: 767px) {
  /* Navbar */
  nav {
    padding: 20px 15px;
  }
  .nav-menu {
    margin-top: 40px;
    display: none;
    float: none;
    width: 100%;
  }
  .nav-menu li {
    float: none;
    width: 100%;
    text-align: center;
    border-top: 1px solid #f7f7f7;
    line-height: 45px;
    margin-left: 0;
    padding-top: 10px;
    padding-bottom: 10px;
  }
  .responsive {
    float: right;
    padding-top: 15px;
    display: block;
  }
  /* About */

  /* portfolio */
  
  /* journal */
  
  /* Contact */
  
  /* Footer */
  
}

/** Width between 600px to 0
 *  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 */
@media (max-width: 600px) {
  /* Navbar */
  nav {
    padding: 20px 15px;
  }
  .nav-menu {
    margin-top: 40px;
    display: none;
    float: none;
    width: 100%;
  }
  .nav-menu li {
    float: none;
    width: 100%;
    text-align: center;
    border-top: 1px solid #f7f7f7;
    line-height: 45px;
    margin-left: 0;
    padding-top: 10px;
    padding-bottom: 10px;
  }
  .responsive {
    float: right;
    padding-top: 15px;
    display: block;
  }
  /* About */

  /* portfolio */
  
  /* journal */
  
  /* Contact */
  
  /* Footer */
  
}

/** Width between 480px to 0
 *  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 */
@media (max-width: 480px) {
  /* Navbar */
  nav {
    padding: 20px 15px;
  }
  .nav-menu {
    margin-top: 40px;
    display: none;
    float: none;
    width: 100%;
  }
  .nav-menu li {
    float: none;
    width: 100%;
    text-align: center;
    border-top: 1px solid #f7f7f7;
    line-height: 45px;
    margin-left: 0;
    padding-top: 10px;
    padding-bottom: 10px;
  }
  .responsive {
    float: right;
    padding-top: 15px;
    display: block;
  }
  /* About */

  /* portfolio */
  
  /* journal */
  
  /* Contact */
  
  /* Footer */
  
}

/** Width between 320px to 0
 *  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 */
@media (max-width: 320px) {
  /* Navbar */
  nav {
    padding: 20px 15px;
  }
  .nav-menu {
    margin-top: 40px;
    display: none;
    float: none;
    width: 100%;
  }
  .nav-menu li {
    float: none;
    width: 100%;
    text-align: center;
    border-top: 1px solid #f7f7f7;
    line-height: 45px;
    margin-left: 0;
    padding-top: 10px;
    padding-bottom: 10px;
  }
  .responsive {
    float: right;
    padding-top: 15px;
    display: block;
  }
  /* About */

  /* portfolio */
  
  /* journal */
  
  /* Contact */
  
  /* Footer */
  
  /* Single page */
  
}

/*--------------------------------------------------------------
# Modern Portfolio Enhancements
--------------------------------------------------------------*/

/* Hero Section */
.hero-section {
  position: relative;
  height: 100vh;
  min-height: 700px; /* Ensure minimum height for content */
  width: 100%;
  max-width: 100vw;
  display: flex;
  align-items: flex-start; /* Anchor content to top */
  justify-content: center;
  overflow: hidden;
  background: transparent;
  z-index: 1;
  box-sizing: border-box;
}

/* Game Engine Viewport Frame - Modern Style */
.viewport-frame {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
  z-index: 10;
}

.viewport-toolbar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 38px;
  background: linear-gradient(180deg, rgba(30, 32, 40, 0.98) 0%, rgba(22, 24, 30, 0.98) 100%);
  border-bottom: 1px solid rgba(102, 126, 234, 0.2);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 500;
  pointer-events: auto;
  backdrop-filter: blur(10px);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}

.toolbar-left,
.toolbar-center,
.toolbar-right {
  display: flex;
  align-items: center;
  gap: 6px;
}

.toolbar-center {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.viewport-tab {
  padding: 8px 16px;
  color: rgba(160, 165, 180, 0.8);
  cursor: pointer;
  border-radius: 6px;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  font-weight: 500;
  letter-spacing: 0.3px;
}

.viewport-tab.active {
  color: #fff;
  background: linear-gradient(135deg, rgba(102, 126, 234, 0.4) 0%, rgba(118, 75, 162, 0.3) 100%);
  box-shadow: 0 0 15px rgba(102, 126, 234, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.viewport-tab:hover:not(.active) {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
  transform: translateY(-1px);
}

.play-btn, .pause-btn, .step-btn {
  width: 32px;
  height: 28px;
  background: linear-gradient(180deg, rgba(45, 48, 58, 0.9) 0%, rgba(35, 38, 48, 0.9) 100%);
  border: 1px solid rgba(102, 126, 234, 0.25);
  border-radius: 6px;
  color: rgba(180, 185, 200, 0.9);
  cursor: pointer;
  font-size: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.play-btn.active,
.play-btn:disabled {
  background: linear-gradient(135deg, rgba(102, 126, 234, 0.6) 0%, rgba(118, 75, 162, 0.5) 100%);
  border-color: rgba(102, 126, 234, 0.7);
  color: #fff;
  cursor: default;
  box-shadow: 
    0 0 15px rgba(102, 126, 234, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.15),
    0 2px 8px rgba(0, 0, 0, 0.3);
  pointer-events: none;
}

.pause-btn.active,
.pause-btn[disabled] {
  background: linear-gradient(135deg, rgba(255, 160, 80, 0.6) 0%, rgba(255, 120, 60, 0.5) 100%);
  border-color: rgba(255, 160, 80, 0.7);
  color: #fff;
  cursor: default;
  box-shadow: 
    0 0 15px rgba(255, 160, 80, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.15),
    0 2px 8px rgba(0, 0, 0, 0.3);
  pointer-events: none;
}

/* Paused state - freeze all animations */
.hero-section.paused .particle,
.hero-section.paused .particle-glow,
.hero-section.paused .particle-trail,
.hero-section.paused .particle-orb {
  animation-play-state: paused !important;
}

.hero-section.paused .cursor {
  animation-play-state: paused !important;
  opacity: 1 !important;
}

.hero-section.paused .typing-text {
  animation-play-state: paused !important;
}

.hero-section.paused .hero-image-overlay,
.hero-section.paused .hero-image-overlay::before {
  animation-play-state: paused !important;
}

/* Game view mode - hides editor gizmos (axis, grid, stats, scene info) */
.hero-section.game-view .coordinate-axis {
  opacity: 0;
  pointer-events: none;
}

.hero-section.game-view .hero-image-overlay::before {
  opacity: 0;
}

.hero-section.game-view .viewport-stats {
  opacity: 0;
  pointer-events: none;
}

.hero-section.game-view .viewport-scene-info {
  opacity: 0;
  pointer-events: none;
}

/* 2D/3D view mode - toggles Z-axis visibility */
/* Hide Z-axis elements in 2D mode */
.hero-section.view-2d .coordinate-axis .z-axis {
  opacity: 0;
}

/* Ensure Z-axis elements have transition for smooth show/hide */
.coordinate-axis .z-axis {
  transition: opacity 0.3s ease;
}

/* 3D mode - buttons get 3D appearance */
.hero-section.view-3d .btn-primary,
.hero-section.view-3d .btn-secondary {
  transform: perspective(500px) rotateX(10deg) translateY(-2px);
  box-shadow: 
    0 4px 0 rgba(0, 0, 0, 0.3),
    0 8px 15px rgba(0, 0, 0, 0.3),
    0 15px 30px rgba(102, 126, 234, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
  border-bottom-width: 4px;
}

.hero-section.view-3d .btn-primary:hover,
.hero-section.view-3d .btn-secondary:hover {
  transform: perspective(500px) rotateX(5deg) translateY(0);
  box-shadow: 
    0 2px 0 rgba(0, 0, 0, 0.3),
    0 4px 10px rgba(0, 0, 0, 0.3),
    0 8px 20px rgba(102, 126, 234, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.hero-section.view-3d .btn-primary:active,
.hero-section.view-3d .btn-secondary:active {
  transform: perspective(500px) rotateX(0deg) translateY(2px);
  box-shadow: 
    0 0 0 rgba(0, 0, 0, 0.3),
    0 2px 5px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* Smooth transition for buttons */
.hero-buttons .btn-primary,
.hero-buttons .btn-secondary {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* 3D mode - stat items get 3D appearance */
.hero-section.view-3d .stat-item {
  transform: perspective(500px) rotateX(8deg) translateY(-2px);
  box-shadow: 
    0 4px 0 rgba(0, 0, 0, 0.25),
    0 8px 15px rgba(0, 0, 0, 0.2),
    0 12px 25px rgba(102, 126, 234, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  border-bottom: 3px solid rgba(102, 126, 234, 0.3);
}

.hero-section.view-3d .stat-item:hover {
  transform: perspective(500px) rotateX(4deg) translateY(0);
  box-shadow: 
    0 2px 0 rgba(0, 0, 0, 0.25),
    0 4px 10px rgba(0, 0, 0, 0.2),
    0 8px 20px rgba(102, 126, 234, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* Smooth transition for stat items */
.hero-stats .stat-item {
  transition: transform 0.3s ease, box-shadow 0.3s ease, border 0.3s ease;
}

/* 3D mode - hero text gets 3D appearance */
.hero-section.view-3d .hero-title {
  transform: scale(1.02);
}

.hero-section.view-3d .hero-title .title-line {
  text-shadow: 
    0 1px 0 rgba(0, 0, 0, 0.2),
    0 2px 0 rgba(0, 0, 0, 0.15),
    0 3px 0 rgba(0, 0, 0, 0.1),
    0 4px 8px rgba(0, 0, 0, 0.2);
}

.hero-section.view-3d .hero-title .title-line.highlight {
  text-shadow: 
    0 1px 0 rgba(0, 0, 0, 0.2),
    0 2px 0 rgba(0, 0, 0, 0.15),
    0 3px 0 rgba(0, 0, 0, 0.1),
    0 4px 8px rgba(0, 0, 0, 0.2),
    0 0 15px rgba(102, 126, 234, 0.5),
    0 0 30px rgba(102, 126, 234, 0.2);
}

.hero-section.view-3d .hero-specialize {
  transform: perspective(600px) rotateX(6deg);
  text-shadow: 
    0 2px 0 rgba(0, 0, 0, 0.2),
    0 4px 8px rgba(0, 0, 0, 0.3);
}

.hero-section.view-3d .hero-subtitle {
  transform: perspective(600px) rotateX(6deg);
  text-shadow: 
    0 2px 0 rgba(0, 0, 0, 0.2),
    0 4px 0 rgba(0, 0, 0, 0.15),
    0 6px 10px rgba(0, 0, 0, 0.3),
    0 10px 20px rgba(102, 126, 234, 0.15);
}

.hero-section.view-3d .hero-description {
  transform: scale(1.01);
  text-shadow: 
    0 2px 0 rgba(0, 0, 0, 0.25),
    0 4px 0 rgba(0, 0, 0, 0.15),
    0 6px 10px rgba(0, 0, 0, 0.3),
    0 10px 20px rgba(102, 126, 234, 0.15);
}

/* Smooth transitions for hero text elements */
.hero-title,
.hero-specialize,
.hero-subtitle,
.hero-description {
  transition: transform 0.3s ease, text-shadow 0.3s ease;
}

.pause-btn:hover, .step-btn:hover {
  background: linear-gradient(135deg, rgba(102, 126, 234, 0.5) 0%, rgba(118, 75, 162, 0.4) 100%);
  border-color: rgba(102, 126, 234, 0.6);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.pause-btn:active, .step-btn:active {
  transform: translateY(0);
}

.gizmo-toggle {
  padding: 6px 14px;
  color: rgba(140, 145, 160, 0.8);
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  border-radius: 6px;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid transparent;
}

.gizmo-toggle.active {
  color: #fff;
  background: linear-gradient(135deg, rgba(102, 126, 234, 0.5) 0%, rgba(118, 75, 162, 0.4) 100%);
  border-color: rgba(102, 126, 234, 0.4);
  box-shadow: 0 0 12px rgba(102, 126, 234, 0.3);
}

.gizmo-toggle:hover:not(.active) {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}

.viewport-stats {
  position: absolute;
  top: 100px;
  right: 15px;
  background: linear-gradient(135deg, rgba(18, 20, 28, 0.95) 0%, rgba(25, 28, 38, 0.95) 100%);
  padding: 12px 16px;
  border-radius: 10px;
  border: 1px solid rgba(102, 126, 234, 0.15);
  font-family: 'JetBrains Mono', 'Consolas', 'Monaco', monospace;
  font-size: 11px;
  color: rgba(150, 200, 150, 0.9);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  transition: opacity 0.3s ease;
}

.stat-row {
  display: flex;
  gap: 8px;
  line-height: 1.7;
}

.stat-key {
  color: rgba(160, 165, 180, 0.5);
  font-weight: 500;
}

.stat-val {
  color: rgba(130, 190, 220, 0.75);
  font-weight: 500;
}

.viewport-scene-info {
  position: absolute;
  top: 52px;
  right: 15px;
  background: linear-gradient(135deg, rgba(18, 20, 28, 0.95) 0%, rgba(25, 28, 38, 0.95) 100%);
  padding: 10px 16px;
  border-radius: 10px;
  border: 1px solid rgba(102, 126, 234, 0.15);
  font-family: 'JetBrains Mono', 'Consolas', 'Monaco', monospace;
  font-size: 11px;
  color: rgba(180, 180, 200, 0.8);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  display: flex;
  align-items: center;
  gap: 8px;
  transition: opacity 0.3s ease;
}

.viewport-scene-info::before {
  content: '◆';
  color: rgba(102, 126, 234, 0.8);
  font-size: 8px;
}

.scene-name {
  color: rgba(180, 160, 255, 0.95);
  font-weight: 600;
}

/* Viewport border glow - modern */
.hero-section::after {
  content: '';
  position: absolute;
  top: 38px;
  left: 0;
  right: 0;
  bottom: 0;
  border: 1px solid rgba(102, 126, 234, 0.1);
  pointer-events: none;
  z-index: 11;
  box-shadow: 
    inset 0 0 80px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(102, 126, 234, 0.1);
}

/* Hide viewport UI on mobile */

.hero-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.hero-image-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    /* Subtle radial spotlight effect */
    radial-gradient(ellipse at 30% 40%, rgba(102, 126, 234, 0.15) 0%, transparent 50%),
    radial-gradient(ellipse at 70% 60%, rgba(118, 75, 162, 0.12) 0%, transparent 50%),
    /* Base gradient - lighter and more dynamic */
    linear-gradient(135deg, 
      #1a1a2e 0%, 
      #1e2a4a 25%, 
      #1a1e35 50%, 
      #1d2538 75%, 
      #1a1a2e 100%
    );
  background-size: 100% 100%;
  background-position: center;
  z-index: 1;
  opacity: 1;
  animation: subtleGlow 8s ease-in-out infinite;
  pointer-events: none;
}


.hero-background .particles {
  z-index: 5 !important;
}

.hero-image-overlay::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  /* Game engine-style coordinate grid */
  background: 
    /* Main grid - Unity-style */
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 99px,
      rgba(102, 126, 234, 0.08) 99px,
      rgba(102, 126, 234, 0.08) 100px
    ),
    repeating-linear-gradient(
      90deg,
      transparent,
      transparent 99px,
      rgba(102, 126, 234, 0.08) 99px,
      rgba(102, 126, 234, 0.08) 100px
    ),
    /* Sub-grid for detail */
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 19px,
      rgba(102, 126, 234, 0.03) 19px,
      rgba(102, 126, 234, 0.03) 20px
    ),
    repeating-linear-gradient(
      90deg,
      transparent,
      transparent 19px,
      rgba(118, 75, 162, 0.03) 19px,
      rgba(118, 75, 162, 0.03) 20px
    );
  background-size: 100px 100px, 100px 100px, 20px 20px, 20px 20px;
  animation: gridDrift 30s linear infinite;
  pointer-events: none;
  opacity: 1;
  transition: opacity 0.3s ease;
}

.hero-image-overlay::after {
  display: none;
}

/* Game engine viewport elements */
.hero-background::before {
  display: none;
}

/* 3D Coordinate Axis SVG indicator */
.coordinate-axis {
  position: absolute;
  bottom: 20px;
  right: 20px;
  width: 90px;
  height: 90px;
  pointer-events: none;
  opacity: 0.7;
  z-index: 3;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.3));
  transition: opacity 0.3s ease;
}

.coordinate-axis:hover {
  opacity: 0.95;
}

/* Adjust axis on mobile for cleaner look */

.hero-background::after {
  display: none;
}

@keyframes ambientBreath {
  0%, 100% {
    filter: brightness(1) saturate(1);
    opacity: 1;
  }
  50% {
    filter: brightness(1.02) saturate(1.02);
    opacity: 0.98;
  }
}

@keyframes subtleGlow {
  0%, 100% {
    filter: brightness(1) saturate(1);
  }
  50% {
    filter: brightness(1.08) saturate(1.05);
  }
}

@keyframes gridDrift {
  0% {
    background-position: 0 0, 0 0, 0 0, 0 0;
  }
  100% {
    background-position: 100px 100px, 100px 100px, 20px 20px, 20px 20px;
  }
}

@keyframes perspectiveShift {
  0%, 100% {
    transform: translate(-50%, -50%) perspective(1000px) rotateX(2deg) rotateY(2deg);
    opacity: 1;
  }
  50% {
    transform: translate(-50%, -50%) perspective(1000px) rotateX(-1deg) rotateY(-1deg);
    opacity: 0.8;
  }
}

@keyframes framePulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.85;
  }
}

@keyframes hudPulse {
  0%, 100% {
    opacity: 1;
    filter: brightness(1);
  }
  50% {
    opacity: 0.9;
    filter: brightness(1.1);
  }
}

@keyframes ambientFloat {
  0%, 100% {
    background-position: 0% 0%, 100% 100%, 50% 50%, 0% 100%, 100% 0%;
    transform: translate(0, 0);
  }
  25% {
    background-position: 15% 15%, 85% 85%, 55% 45%, 10% 90%, 90% 10%;
    transform: translate(2px, -3px);
  }
  50% {
    background-position: 30% 30%, 70% 70%, 50% 50%, 20% 80%, 80% 20%;
    transform: translate(0, -5px);
  }
  75% {
    background-position: 15% 45%, 85% 55%, 45% 55%, 10% 70%, 90% 30%;
    transform: translate(-2px, -3px);
  }
}

@keyframes ambientDrift {
  0% {
    background-position: 0 0, 0 0, 0 0;
    opacity: 0.6;
  }
  50% {
    background-position: 25px 25px, 15px 15px, 20px 20px;
    opacity: 0.5;
  }
  100% {
    background-position: 50px 50px, 30px 30px, 40px 40px;
    opacity: 0.6;
  }
}

@keyframes scanLine {
  0% {
    transform: translateY(-100%);
    opacity: 0;
  }
  50% {
    opacity: 0.4;
  }
  100% {
    transform: translateY(100vh);
    opacity: 0;
  }
}

@keyframes hexDrift {
  0% {
    background-position: 0 0, 0 0;
    opacity: 0.3;
  }
  50% {
    background-position: 20px 20px, -20px -20px;
    opacity: 0.25;
  }
  100% {
    background-position: 40px 40px, -40px -40px;
    opacity: 0.3;
  }
}

/* Subtle ambient overlay */
.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  /* Subtle vignette for depth */
  background: radial-gradient(ellipse at center, transparent 30%, rgba(10, 10, 20, 0.3) 100%);
  pointer-events: none;
  opacity: 1;
  z-index: 4;
}

@keyframes glitch {
  0%, 90%, 100% {
    transform: translate(0);
    opacity: 0.5;
  }
  91% {
    transform: translate(-2px, 1px);
    opacity: 0.6;
  }
  92% {
    transform: translate(2px, -1px);
    opacity: 0.6;
  }
  93% {
    transform: translate(-1px, 2px);
    opacity: 0.5;
  }
  94% {
    transform: translate(1px, -2px);
    opacity: 0.5;
  }
  95% {
    transform: translate(0);
    opacity: 0.5;
  }
}

.particles {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 3;
  pointer-events: none;
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
}

.particle {
  position: absolute;
  width: 3px;
  height: 3px;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 50%;
  animation: float 4s infinite ease-in-out;
  animation-play-state: running;
  box-shadow: 
    0 0 4px rgba(255, 255, 255, 0.8),
    0 0 8px rgba(255, 255, 255, 0.4);
  pointer-events: none;
  display: block !important;
  visibility: visible !important;
}

.particle-glow {
  width: 4px;
  height: 4px;
  background: rgba(102, 126, 234, 0.9);
  box-shadow: 
    0 0 6px rgba(102, 126, 234, 1),
    0 0 12px rgba(102, 126, 234, 0.6),
    0 0 18px rgba(102, 126, 234, 0.3);
  animation: floatGlow 5s infinite ease-in-out;
}

.particle-trail {
  width: 4px;
  height: 4px;
  background: rgba(118, 75, 162, 0.8);
  box-shadow: 
    0 0 5px rgba(118, 75, 162, 0.9),
    0 0 10px rgba(118, 75, 162, 0.5),
    0 0 15px rgba(118, 75, 162, 0.3);
  animation: floatTrail 6s infinite ease-in-out;
}

.particle-orb {
  position: absolute;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(102, 126, 234, 0.3) 0%, transparent 70%);
  box-shadow: 0 0 20px rgba(102, 126, 234, 0.4), 0 0 40px rgba(102, 126, 234, 0.2);
  animation: orbFloat 20s infinite ease-in-out;
  filter: blur(1px);
}

@keyframes float {
  0%, 100% {
    transform: translate(0, 0) scale(1);
    opacity: 0;
  }
  10% {
    opacity: 1;
  }
  90% {
    opacity: 1;
  }
  100% {
    transform: translate(calc(50px * var(--drift, 1)), -100vh) scale(0.5);
    opacity: 0;
  }
}

@keyframes floatGlow {
  0%, 100% {
    transform: translate(0, 0) scale(1);
    opacity: 0;
  }
  10% {
    opacity: 0.8;
  }
  50% {
    transform: translate(30px, -50vh) scale(1.2);
    opacity: 1;
  }
  90% {
    opacity: 0.8;
  }
  100% {
    transform: translate(60px, -100vh) scale(0.3);
    opacity: 0;
  }
}

@keyframes floatTrail {
  0%, 100% {
    transform: translate(0, 0) scale(1);
    opacity: 0;
  }
  10% {
    opacity: 0.6;
  }
  50% {
    transform: translate(-40px, -50vh) scale(1.1);
    opacity: 0.8;
  }
  90% {
    opacity: 0.6;
  }
  100% {
    transform: translate(-80px, -100vh) scale(0.4);
    opacity: 0;
  }
}

@keyframes orbFloat {
  0%, 100% {
    transform: translate(0, 0) scale(1);
    opacity: 0.3;
  }
  25% {
    transform: translate(30px, -20px) scale(1.1);
    opacity: 0.5;
  }
  50% {
    transform: translate(0, -40px) scale(1.2);
    opacity: 0.6;
  }
  75% {
    transform: translate(-30px, -20px) scale(1.1);
    opacity: 0.5;
  }
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  color: #fff;
  padding: 85px 20px 0 20px; /* Fixed 85px gap from top toolbar */
  max-width: 1200px;
  margin: 0 auto;
  background: transparent !important;
  background-color: transparent !important;
}

.hero-text {
  background: transparent !important;
  background-color: transparent !important;
}

.hero-title {
  font-size: 72px;
  font-weight: 800;
  margin-bottom: 5px;
  line-height: 1.2;
  text-transform: uppercase;
  letter-spacing: 4px;
}

.hero-title .title-line {
  display: block;
  opacity: 0;
  animation: fadeInUp 1s ease-out forwards;
}

.hero-title .title-line:nth-child(2) {
  animation-delay: 0.3s;
}

.hero-title .title-line.highlight {
  color: #fff;
  text-shadow: 
    0 0 20px rgba(102, 126, 234, 0.6),
    0 0 40px rgba(102, 126, 234, 0.3),
    0 4px 0 rgba(0, 0, 0, 0.3);
}

.hero-stats {
  display: flex;
  gap: 30px;
  margin: 40px 0;
  flex-wrap: wrap;
  justify-content: center;
}

.stat-item {
  flex: 1;
  min-width: 160px;
  max-width: 220px;
  text-align: center;
  padding: 20px 28px;
  background: linear-gradient(180deg, rgba(26, 26, 46, 0.9), rgba(40, 41, 43, 0.9)) !important;
  background-color: rgba(26, 26, 46, 0.9) !important;
  border: 2px solid rgba(102, 126, 234, 0.3);
  border-radius: 8px;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.stat-item:hover {
  border-color: rgba(102, 126, 234, 0.6);
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(102, 126, 234, 0.3);
}

.stat-number {
  font-size: 28px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 8px;
  font-family: 'Inter', sans-serif;
  text-shadow: none;
}

.stat-label {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.7);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-family: 'Inter', sans-serif;
}

.hero-description strong {
  color: #FFD700;
  font-weight: 600;
}

/* Scroll Indicator */
.scroll-indicator {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  z-index: 10;
  opacity: 0.7;
  animation: fadeInScrollIndicator 2s ease-out;
  transition: opacity 0.5s ease, pointer-events 0.5s ease;
}

@keyframes fadeInScrollIndicator {
  0% {
    opacity: 0;
    transform: translateX(-50%) translateY(-10px);
  }
  100% {
    opacity: 0.7;
    transform: translateX(-50%) translateY(0);
  }
}

.scroll-text {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.6);
  text-transform: uppercase;
  letter-spacing: 2px;
  font-family: 'Inter', sans-serif;
  font-weight: 500;
}

.scroll-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  animation: bounceArrow 2s infinite;
  color: rgba(102, 126, 234, 0.8);
}

@keyframes bounceArrow {
  0%, 100% {
    transform: translateY(0);
    opacity: 0.8;
  }
  50% {
    transform: translateY(8px);
    opacity: 1;
  }
}

.scroll-arrow svg {
  filter: drop-shadow(0 0 4px rgba(102, 126, 234, 0.5));
}

.scroll-indicator:hover {
  opacity: 1;
}

.scroll-indicator:hover .scroll-arrow {
  animation-duration: 1s;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-specialize {
  font-size: 18px;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.7);
  margin-top: 0;
  margin-bottom: 15px;
  text-align: center;
  font-family: 'Inter', sans-serif;
  letter-spacing: 0.5px;
}

.hero-subtitle {
  font-size: 32px;
  font-weight: 300;
  margin-bottom: 20px;
  min-height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  font-family: 'Courier New', 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
}

.typing-text {
  color: #fff;
  font-weight: 400;
  font-family: 'Courier New', 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
}

.cursor {
  animation: blink 1s infinite;
  color: #fff;
}

@keyframes blink {
  0%, 50% {
    opacity: 1;
  }
  51%, 100% {
    opacity: 0;
  }
}

.hero-description {
  font-size: 18px;
  margin-top: 15px;
  margin-bottom: 30px;
  opacity: 0.9;
  font-weight: 300;
  text-align: center;
  font-family: 'Inter', sans-serif;
}

.hero-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 80px; /* Space for scroll indicator and axis */
}

.btn-primary, .btn-secondary {
  padding: 15px 40px;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: all 0.3s ease;
  display: inline-block;
  position: relative;
  overflow: hidden;
}

.btn-primary {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
  background-color: #667eea !important;
  color: #fff !important;
  box-shadow: 0 10px 30px rgba(102, 126, 234, 0.3);
  border: none;
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 15px 40px rgba(102, 126, 234, 0.5);
  background: linear-gradient(135deg, #764ba2 0%, #667eea 100%) !important;
}

.btn-secondary {
  background: transparent !important;
  background-color: transparent !important;
  color: #fff !important;
  border: 2px solid #fff !important;
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1) !important;
  background-color: rgba(255, 255, 255, 0.1) !important;
  color: #fff !important;
  border-color: #667eea !important;
  transform: translateY(-3px);
}

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

@keyframes arrow {
  0% {
    opacity: 0;
  }
  50% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}

/* Professional Sidebar Navigation */
.retro-sidebar {
  position: fixed;
  left: 0;
  top: 0;
  width: 280px;
  height: 100vh;
  background: rgba(26, 22, 37, 0.95);
  backdrop-filter: blur(20px);
  border-right: 1px solid rgba(102, 126, 234, 0.2);
  box-shadow: 
    2px 0 20px rgba(0, 0, 0, 0.3);
  z-index: 1000;
  display: flex;
  flex-direction: column;
  padding: 0;
  overflow-y: auto;
  overflow-x: hidden;
  font-family: 'Inter', sans-serif;
  transition: width 0.3s ease, transform 0.3s ease;
}

.retro-sidebar::-webkit-scrollbar {
  width: 10px;
}

.retro-sidebar::-webkit-scrollbar-track {
  background: rgba(26, 26, 46, 0.6);
  border-radius: 5px;
}

.retro-sidebar::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #667eea 0%, #764ba2 100%);
  border-radius: 5px;
  border: 2px solid rgba(26, 26, 46, 0.6);
}

.retro-sidebar::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #7e8ff0 0%, #8d5cb8 100%);
}

.sidebar-header {
  padding: 40px 30px 30px;
  border-bottom: 1px solid rgba(102, 126, 234, 0.15);
  position: relative;
}

.sidebar-initials {
  display: none;
}

/* Sidebar Collapse Button */
.sidebar-collapse-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 28px;
  height: 28px;
  background: rgba(40, 45, 60, 0.8);
  border: 1px solid rgba(102, 126, 234, 0.3);
  border-radius: 6px;
  color: rgba(200, 205, 220, 0.8);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  z-index: 10;
}

.sidebar-collapse-btn:hover {
  background: rgba(102, 126, 234, 0.3);
  border-color: rgba(102, 126, 234, 0.6);
  color: #fff;
}

/* Hide collapse button on mobile (hamburger handles it) */
@media (max-width: 768px) {
  .sidebar-collapse-btn {
    display: none;
  }
}

.retro-screen {
  position: relative;
  transition: opacity 0.3s ease 0.15s, transform 0.3s ease 0.15s, visibility 0.3s ease 0.15s;
  white-space: nowrap;
}

.sidebar-logo {
  font-size: 24px !important;
  font-weight: 700;
  color: #fff;
  margin: 0 0 6px 0;
  letter-spacing: -0.5px;
  font-family: 'Inter', sans-serif;
  line-height: 1.3;
  transform: none !important;
  zoom: 1 !important;
  white-space: nowrap;
}

.retro-divider {
  display: none;
}

.sidebar-slogan {
  font-size: 13px !important;
  color: rgba(255, 255, 255, 0.6);
  margin: 0;
  font-weight: 400;
  font-family: 'Inter', sans-serif;
  letter-spacing: 0.3px;
  transform: none !important;
  zoom: 1 !important;
  transition: transform 0.3s ease 0.15s;
}

.retro-menu {
  list-style: none;
  padding: 20px 15px;
  margin: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.retro-menu li {
  margin: 0;
}

.retro-menu-item {
  display: flex;
  align-items: center;
  padding: 14px 30px;
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  background: transparent;
  border: none;
  border-left: 3px solid transparent;
  transition: color 0.2s ease, background 0.2s ease, padding 0.3s ease;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.2px;
  font-family: 'Inter', sans-serif;
  position: relative;
}

.retro-menu-item::before {
  display: none;
}

.retro-menu-item:hover {
  color: #fff;
  background: rgba(102, 126, 234, 0.1);
  border-left-color: rgba(102, 126, 234, 0.5);
  transition: color 0.2s ease, background 0.2s ease, border-left-color 0.2s ease;
}

.retro-menu-item.active {
  color: #fff;
  background: rgba(102, 126, 234, 0.15);
  border-left-color: #667eea;
  font-weight: 600;
  transition: color 0.2s ease, padding 0.3s ease, background 0.2s ease 0.5s !important;
}

.retro-menu-item.active::before {
  display: none;
}

.menu-icon {
  display: inline-block;
  flex-shrink: 0;
  margin-right: 12px;
  width: 18px;
  height: 18px;
  opacity: 0.8;
  transition: opacity 0.2s ease;
}

.retro-menu-item:hover .menu-icon,
.retro-menu-item.active .menu-icon {
  opacity: 1;
}

.menu-text {
  flex: 1;
  transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease, width 0.3s ease;
}

.sidebar-footer {
  margin-top: auto;
  padding: 25px 30px;
  border-top: 1px solid rgba(102, 126, 234, 0.15);
  position: relative;
}

.sidebar-footer::before {
  display: none;
}

.sidebar-contact {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.sidebar-link {
  color: rgba(255, 255, 255, 0.5);
  font-size: 13px;
  text-decoration: none;
  transition: all 0.3s ease;
  font-family: 'Inter', sans-serif;
  font-weight: 400;
  letter-spacing: 0.2px;
}

.sidebar-link:hover {
  color: rgba(255, 255, 255, 0.8);
}

.sidebar-email,
.sidebar-github {
  display: flex;
  align-items: center;
  gap: 8px;
}

.email-icon,
.github-icon {
  width: 16px;
  height: 16px;
  fill: currentColor;
  flex-shrink: 0;
  transition: transform 0.3s ease;
}

.sidebar-email:hover .email-icon {
  transform: scale(1.1);
}

.sidebar-github:hover .github-icon {
  transform: scale(1.1) rotate(5deg);
}

/* Adjust content to account for sidebar */
#wrapper {
  margin-left: 280px;
  width: calc(100% - 280px);
  transition: margin-left 0.3s ease, width 0.3s ease;
  overflow-x: hidden;
  max-width: 100vw;
  box-sizing: border-box;
}

/* Collapsed sidebar state - shows 60px wide with icons only (all breakpoints) */
.retro-sidebar.collapsed {
  width: 60px;
  transform: translateX(0);
  overflow-x: hidden;
  cursor: pointer;
}

/* Prevent border flash during sidebar transitions */
.retro-sidebar.collapsed .retro-menu-item,
.retro-sidebar:not(.collapsed) .retro-menu-item {
  border-left-color: transparent !important;
  transition: color 0.2s ease, background 0.2s ease, padding 0.3s ease !important;
}

.retro-sidebar:not(.collapsed) .retro-menu-item.active {
  background: rgba(102, 126, 234, 0.15) !important;
  transition: color 0.2s ease, padding 0.3s ease !important;
}

.retro-sidebar.collapsed .sidebar-header {
  padding: 20px 0;
  margin: 0;
  opacity: 1;
  visibility: visible;
  width: 100%;
  min-height: 60px;
  height: 60px;
  border-bottom: 1px solid rgba(102, 126, 234, 0.15);
  display: flex;
  justify-content: center;
  align-items: center;
  box-sizing: border-box;
}

.retro-sidebar.collapsed .retro-screen {
  opacity: 0;
  visibility: hidden;
  max-width: 0;
  width: 0;
  overflow: hidden;
  transform: translateX(-30px);
  transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s ease, max-width 0.3s ease, width 0.3s ease;
  position: absolute;
  white-space: nowrap;
}

/* Smooth slide-in animation for header text when expanding */
.retro-sidebar:not(.collapsed) .retro-screen {
  opacity: 1;
  visibility: visible;
  max-width: 100%;
  width: auto;
  min-width: 200px;
  overflow: visible;
  transform: translateX(0);
  transition: opacity 0.3s ease 0.15s, transform 0.3s ease 0.15s, visibility 0.3s ease 0.15s, max-width 0.3s ease 0.15s, width 0.3s ease 0.15s, min-width 0.3s ease 0.15s;
  position: relative;
  white-space: nowrap;
}

.retro-sidebar.collapsed .sidebar-initials {
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  letter-spacing: 1px;
  font-family: 'Inter', sans-serif;
  margin: 0;
}

.retro-sidebar.collapsed .sidebar-footer {
  opacity: 1;
  visibility: visible;
  width: 100%;
  height: auto;
  padding: 20px 0;
  margin: 0;
  border-top: 1px solid rgba(102, 126, 234, 0.15);
  display: flex;
  justify-content: center;
  align-items: center;
}

.retro-sidebar.collapsed .sidebar-contact {
  flex-direction: column;
  gap: 12px;
  justify-content: center;
  align-items: center;
}

.retro-sidebar.collapsed .sidebar-link {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 8px;
}

.retro-sidebar.collapsed .sidebar-link span {
  display: none;
  opacity: 0;
  transform: translateX(-20px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

/* Smooth slide-in animation for footer link text when expanding */
.retro-sidebar:not(.collapsed) .sidebar-link span {
  opacity: 1;
  transform: translateX(0);
  transition: opacity 0.3s ease 0.15s, transform 0.3s ease 0.15s;
}

.retro-sidebar.collapsed .email-icon,
.retro-sidebar.collapsed .github-icon {
  width: 20px;
  height: 20px;
  margin: 0;
}

.retro-sidebar.collapsed .menu-text {
  opacity: 0;
  visibility: hidden;
  width: 0;
  overflow: hidden;
  flex: 0;
  margin: 0;
  padding: 0;
  transform: translateX(-20px);
  transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease, width 0.3s ease;
}

/* Smooth slide-in animation when expanding */
.retro-sidebar:not(.collapsed) .menu-text {
  opacity: 1;
  visibility: visible;
  transform: translateX(0);
  transition: opacity 0.3s ease 0.15s, visibility 0.3s ease 0.15s, transform 0.3s ease 0.15s, width 0.3s ease 0.15s;
}

.retro-sidebar.collapsed .retro-menu {
  padding: 20px 0;
  gap: 8px;
  align-items: center;
}

/* Ensure list items fill full width when collapsed */
.retro-sidebar.collapsed .retro-menu li {
  width: 100%;
  display: block;
}

.retro-sidebar.collapsed .retro-menu-item {
  padding: 14px 0;
  justify-content: center;
  align-items: center;
  border-left: none;
  border-right: none;
  transition: color 0.2s ease, background 0.2s ease, padding 0.3s ease;
  border-bottom: 2px solid transparent;
  min-height: 46px;
  width: 100%;
  height: 100%;
  display: flex;
  border-radius: 0;
  background: transparent;
  position: relative;
  /* Make the entire area clickable - ensure it covers full width and height */
  box-sizing: border-box;
  cursor: pointer;
}

.retro-sidebar.collapsed .retro-menu-item:hover {
  background: transparent;
}

.retro-sidebar.collapsed .retro-menu-item.active {
  background: transparent !important;
  border-bottom: 2px solid transparent;
  transition: none !important;
  animation: activeUnderline 0.2s ease 0.15s forwards;
}

@keyframes activeUnderline {
  to {
    border-bottom-color: #667eea;
  }
}

.retro-sidebar.collapsed .menu-icon {
  margin-right: 0;
  margin-left: 0;
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.retro-sidebar.collapsed .menu-icon svg {
  width: 26px !important;
  height: 26px !important;
}

.retro-sidebar.collapsed .sidebar-collapse-btn {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

#wrapper.sidebar-collapsed {
  margin-left: 60px;
  width: calc(100% - 60px);
}

/* Hide hamburger on desktop when sidebar is collapsed (since sidebar is visible) */
@media (min-width: 1025px) {
  .menu-toggle.visible {
    display: none !important;
  }
}

/* Mobile: use collapsed sidebar approach - reuse same collapsed styles */
@media (max-width: 1024px) {
  .retro-sidebar {
    overflow-x: hidden;
  }

  /* Default to collapsed at 1024px unless explicitly opened */
  .retro-sidebar:not(.open) {
    width: 60px;
    transform: translateX(0);
  }

  /* Apply collapsed content styles when not opened */
  .retro-sidebar:not(.open) .sidebar-header {
    padding: 20px 0;
    margin: 0;
    opacity: 1;
    visibility: visible;
    width: 100%;
    min-height: 60px;
    height: 60px;
    border-bottom: 1px solid rgba(102, 126, 234, 0.15);
    display: flex;
    justify-content: center;
    align-items: center;
    box-sizing: border-box;
  }

  .retro-sidebar:not(.open) .retro-screen {
    opacity: 0;
    visibility: hidden;
    max-width: 0;
    min-width: 0;
    overflow: hidden;
    transform: translateX(-30px);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s ease, max-width 0.3s ease, min-width 0.3s ease;
    white-space: nowrap;
  }

  .retro-sidebar:not(.open) .sidebar-initials {
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 20px;
    font-weight: 700;
    color: #fff;
    letter-spacing: 1px;
    font-family: 'Inter', sans-serif;
    margin: 0;
  }

  .retro-sidebar:not(.open) .sidebar-footer {
    opacity: 1;
    visibility: visible;
    width: 100%;
    height: auto;
    padding: 20px 0;
    margin: 0;
    border-top: 1px solid rgba(102, 126, 234, 0.15);
    display: flex;
    justify-content: center;
    align-items: center;
  }

  .retro-sidebar:not(.open) .sidebar-contact {
    flex-direction: column;
    gap: 12px;
    justify-content: center;
    align-items: center;
  }

  .retro-sidebar:not(.open) .sidebar-link {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 8px;
  }

  .retro-sidebar:not(.open) .sidebar-link span {
    display: none;
  }

  .retro-sidebar:not(.open) .email-icon,
  .retro-sidebar:not(.open) .github-icon {
    width: 20px;
    height: 20px;
    margin: 0;
  }

  .retro-sidebar:not(.open) .menu-text {
    opacity: 0;
    visibility: hidden;
    width: 0;
    overflow: hidden;
    transform: translateX(-20px);
    transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease, width 0.3s ease;
  }
  
  .retro-sidebar:not(.open) .retro-screen {
    transform: translateX(-30px);
    transition: opacity 0.3s ease, transform 0.3s ease;
  }
  
  .retro-sidebar:not(.open) .sidebar-link span {
    transform: translateX(-20px);
    transition: opacity 0.3s ease, transform 0.3s ease;
  }

  .retro-sidebar:not(.open) .retro-menu {
    padding: 20px 0;
    gap: 8px;
    align-items: center;
  }

  .retro-sidebar:not(.open) .retro-menu-item {
    padding: 14px 0;
    justify-content: center;
    align-items: center;
    border-left: none;
    border-right: none;
    border-bottom: 2px solid transparent;
    min-height: 46px;
    width: 100%;
    display: flex;
  }

  .retro-sidebar:not(.open) .retro-menu-item:hover {
    background: transparent;
  }

  .retro-sidebar:not(.open) .retro-menu-item.active {
    background: transparent !important;
    border-bottom: 2px solid transparent;
    transition: none !important;
    animation: activeUnderline 0.2s ease 0.15s forwards;
  }

  .retro-sidebar:not(.open) .menu-icon {
    margin-right: 0;
    margin-left: 0;
    width: 26px;
    height: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
  }

  .retro-sidebar:not(.open) .menu-icon svg {
    width: 26px !important;
    height: 26px !important;
  }

  /* Hide collapse button when sidebar is collapsed at 1024px */
  .retro-sidebar:not(.open) .sidebar-collapse-btn {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
  }
  
  /* Show collapse button when sidebar is expanded at 1024px */
  .retro-sidebar.open .sidebar-collapse-btn {
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    display: flex !important;
  }

  /* When sidebar is opened via hamburger, show full width */
  .retro-sidebar.open {
    width: 280px;
    transform: translateX(0) !important;
  }

  /* When sidebar is opened, restore full content with smooth slide-in transitions */
  .retro-sidebar.open .sidebar-header,
  .retro-sidebar.open .menu-text,
  .retro-sidebar.open .sidebar-link span {
    opacity: 1;
    visibility: visible;
    width: auto;
    height: auto;
    display: block;
  }
  
  /* Smooth slide-in animations for text when opening at 1024px */
  .retro-sidebar.open .retro-screen {
    opacity: 1;
    visibility: visible;
    max-width: 100%;
    width: auto;
    min-width: 200px;
    overflow: visible;
    transform: translateX(0);
    transition: opacity 0.3s ease 0.15s, transform 0.3s ease 0.15s, visibility 0.3s ease 0.15s, max-width 0.3s ease 0.15s, width 0.3s ease 0.15s, min-width 0.3s ease 0.15s;
    display: block;
    white-space: nowrap;
    position: relative;
  }
  
  .retro-sidebar.open .menu-text {
    transform: translateX(0);
    transition: opacity 0.3s ease 0.15s, visibility 0.3s ease 0.15s, transform 0.3s ease 0.15s, width 0.3s ease 0.15s;
  }
  
  .retro-sidebar.open .sidebar-link span {
    transform: translateX(0);
    transition: opacity 0.3s ease 0.15s, transform 0.3s ease 0.15s, visibility 0.3s ease 0.15s;
  }

  .retro-sidebar.open .retro-screen {
    display: block;
  }

  .retro-sidebar.open .sidebar-initials {
    display: none;
  }

  .retro-sidebar.open .sidebar-contact {
    flex-direction: column;
  }

  .retro-sidebar.open .retro-menu {
    padding: 20px 15px;
  }

  .retro-sidebar.open .retro-menu-item {
    padding: 14px 30px;
    justify-content: flex-start;
    border-left: 3px solid transparent;
    border-bottom: none;
  }

  .retro-sidebar.open .retro-menu-item.active {
    background: rgba(102, 126, 234, 0.15) !important;
    transition: color 0.2s ease, padding 0.3s ease !important;
  }

  .retro-sidebar.open .menu-icon {
    margin-right: 12px;
  }

  .retro-sidebar.open .menu-icon svg {
    width: 18px !important;
    height: 18px !important;
  }

  /* Wrapper margin - collapsed by default at 1024px */
  #wrapper {
    margin-left: 60px;
    width: calc(100% - 60px);
  }

  /* Adjust wrapper when sidebar is open */
  body:has(.retro-sidebar.open) #wrapper,
  .retro-sidebar.open ~ * #wrapper {
    margin-left: 280px !important;
    width: calc(100% - 280px) !important;
  }
}

/* Hide hamburger on desktop - only show on mobile */
@media (min-width: 769px) {
  .menu-toggle {
    display: none !important;
  }
}

.menu-toggle.visible {
  display: flex !important;
  position: fixed;
  top: 58px;
  left: 18px;
  width: 34px;
  height: 34px;
  z-index: 900;
  background: rgba(40, 45, 60, 0.85);
  border: 1px solid rgba(102, 126, 234, 0.35);
  border-radius: 6px;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  padding: 6px;
  backdrop-filter: blur(12px);
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.35);
}

.menu-toggle.visible span {
  display: block;
  width: 18px;
  height: 2px;
  background: rgba(200, 205, 220, 0.9);
  border-radius: 2px;
  transition: all 0.2s ease;
}

/* Non-home pages (portfolio, skills, contact) place hamburger higher on desktop */
#wrapper.portfolio .menu-toggle.visible,
#wrapper.inner .menu-toggle.visible {
  top: 20px;
}

/* Hide old header */

/* Responsive sidebar */
@media (max-width: 1024px) {
  .retro-sidebar {
    width: 60px;
    transform: translateX(0);
    transition: width 0.3s ease, transform 0.3s ease;
    z-index: 9999;
    visibility: visible;
    display: flex;
  }
  
  .retro-sidebar.open {
    width: 280px;
    transform: translateX(0) !important;
    visibility: visible !important;
    display: flex !important;
  }

  .retro-sidebar.open .sidebar-header,
  .retro-sidebar.open .retro-screen,
  .retro-sidebar.open .menu-text,
  .retro-sidebar.open .sidebar-link span {
    opacity: 1;
    visibility: visible;
    width: auto;
    height: auto;
    display: block;
  }

  .retro-sidebar.open .sidebar-initials {
    display: none;
  }

  .retro-sidebar.open .sidebar-contact {
    flex-direction: column;
  }

  .retro-sidebar.open .retro-menu {
    padding: 20px 15px;
  }

  .retro-sidebar.open .retro-menu-item {
    padding: 14px 30px;
    justify-content: flex-start;
    border-left: 3px solid transparent;
    border-bottom: none;
  }

  .retro-sidebar.open .retro-menu-item.active {
    background: rgba(102, 126, 234, 0.15) !important;
    transition: color 0.2s ease, padding 0.3s ease !important;
  }

  .retro-sidebar.open .menu-icon {
    margin-right: 12px;
  }

  .retro-sidebar.open .menu-icon svg {
    width: 18px !important;
    height: 18px !important;
  }

  /* Adjust wrapper when sidebar is open */
  body:has(.retro-sidebar.open) #wrapper,
  .retro-sidebar.open ~ * #wrapper {
    margin-left: 280px !important;
    width: calc(100% - 280px) !important;
  }
  
  #wrapper {
    margin-left: 60px;
    width: calc(100% - 60px);
  }
  
  /* Mobile menu toggle button - Game Boy style */

}

.menu_trigger {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 30px;
  height: 25px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  cursor: pointer;
  z-index: 1001;
}

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

.menu_trigger:hover span {
  background: #667eea;
}

/* Modern Timeline */
/* About Section */

/* Career Section - Professional Timeline */
.career-section {
  padding: 100px 40px;
  background: linear-gradient(180deg, #1a1625 0%, #0f0d1a 100%) !important;
  background-color: #1a1625 !important;
  max-width: 100%;
  overflow-x: hidden;
  box-sizing: border-box;
}

.career-header {
  text-align: center;
  margin-bottom: 80px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.career-timeline {
  max-width: 900px;
  margin: 0 auto;
  position: relative;
  padding-left: 60px;
  box-sizing: border-box;
  width: 100%;
}

.timeline-line {
  position: absolute;
  left: 17px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(180deg, #667eea 0%, #764ba2 100%);
  box-shadow: 0 0 10px rgba(102, 126, 234, 0.3);
  pointer-events: none; /* Allow hover events to pass through to career items */
}

.career-item {
  position: relative;
  margin-bottom: 50px;
  opacity: 1;
  transform: translateX(0);
  transition: opacity 0.5s ease, transform 0.5s ease; /* Only transition specific properties */
}

.career-item.animate,
.career-item.active {
  opacity: 1;
  transform: translateX(0);
}

.career-marker {
  position: absolute;
  left: -50px;
  top: 25px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  border: 4px solid #1a1625;
  box-shadow: 
    0 0 0 2px rgba(102, 126, 234, 0.3),
    0 0 15px rgba(102, 126, 234, 0.5);
  z-index: 2;
}

.career-item.active .career-marker {
  background: linear-gradient(135deg, #aeecc2 0%, #667eea 100%);
  box-shadow: 
    0 0 0 2px rgba(174, 236, 194, 0.3),
    0 0 20px rgba(174, 236, 194, 0.6);
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.1);
    opacity: 0.8;
  }
}

.career-content {
  background: rgba(26, 22, 37, 0.92);
  border: 1px solid rgba(102, 126, 234, 0.2);
  border-radius: 12px;
  padding: 30px;
  transition: background-color 0.3s ease, border-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
  position: relative;
  display: flex;
  gap: 20px;
  align-items: flex-start;
  z-index: 1;
  pointer-events: auto;
  will-change: transform;
}

.career-company-icon {
  width: 64px;
  height: 64px;
  min-width: 64px;
  object-fit: contain;
  border-radius: 8px;
  background: transparent;
  padding: 0;
  flex-shrink: 0;
  margin-top: 30px; /* Align with role title, not date */
}

.career-text {
  flex: 1;
}

.career-content::before {
  content: '';
  position: absolute;
  left: -1px;
  top: 12px; /* Start after top rounded corner (matches border-radius) */
  bottom: 12px; /* End before bottom rounded corner (matches border-radius) */
  width: 3px;
  background: linear-gradient(180deg, 
    rgba(102, 126, 234, 0.4) 0%,
    #667eea 20%,
    #764ba2 50%,
    #667eea 80%,
    rgba(102, 126, 234, 0.4) 100%
  );
  border-radius: 2px;
  opacity: 0;
  transition: opacity 0.3s ease;
  box-shadow: 0 0 6px rgba(102, 126, 234, 0.3);
  pointer-events: none; /* Don't block hover events on career items */
}

.career-item:hover .career-content,
.career-item.active .career-content {
  background: rgba(26, 22, 37, 0.8);
  border-color: rgba(102, 126, 234, 0.4);
  box-shadow: 
    0 8px 25px rgba(0, 0, 0, 0.3),
    0 0 20px rgba(102, 126, 234, 0.2);
  transform: translateX(5px);
}

.career-item:hover .career-content::before,
.career-item.active .career-content::before {
  opacity: 1;
}

.career-date {
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  margin-bottom: 12px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  font-family: 'Inter', sans-serif;
}

.career-item.active .career-date {
  color: #8b9dcf;
}

.career-title {
  font-size: 22px;
  font-weight: 700;
  color: #fff;
  margin: 0 0 8px 0;
  line-height: 1.3;
  font-family: 'Inter', sans-serif;
}

.career-item.active .career-title {
  color: #ffffff;
  text-shadow: 0 0 10px rgba(182, 255, 117, 0.3);
}

.career-company {
  font-size: 16px;
  font-weight: 600;
  color: #FCA803;
  margin: 0 0 15px 0;
  font-family: 'Inter', sans-serif;
}

.career-item.active .career-company {
  color: #FCA803;
}

.career-description {
  font-size: 15px;
  color: rgba(255, 255, 255, 0.7);
  line-height: 1.7;
  margin: 0;
  font-family: 'Inter', sans-serif;
}

/* Non-active career items - all text white */
.career-item:not(.active) .career-date,
.career-item:not(.active) .career-title,
.career-item:not(.active) .career-description {
  color: #fff !important;
}

/* Responsive Career Timeline */

/* CTA Section */

.section-title {
  font-size: 48px;
  font-weight: 800;
  color: #fff;
  text-align: center;
  margin-bottom: 60px;
  text-shadow: 0 2px 10px rgba(102, 126, 234, 0.3);
  position: relative;
  padding-bottom: 20px;
  white-space: nowrap;
}

.portfolio-header {
  text-align: center;
  margin-bottom: 15px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  position: relative;
  animation: headerFloat 6s ease-in-out infinite;
}

/* Skills page header spacing */
.skills-container .portfolio-header {
  margin-bottom: 40px;
}

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

.portfolio-header .section-title {
  position: relative;
  display: inline-block;
  margin-bottom: 0 !important;
  padding-bottom: 0 !important;
}

.portfolio-header .section-title::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background: linear-gradient(90deg, 
    transparent, 
    rgba(102, 126, 234, 0.8), 
    rgba(118, 75, 162, 0.8), 
    transparent);
  border-radius: 2px;
  animation: titleGlow 3s ease-in-out infinite;
}

@keyframes titleGlow {
  0%, 100% {
    opacity: 0.6;
    width: 60px;
  }
  50% {
    opacity: 1;
    width: 100px;
  }
}

.portfolio-intro {
  font-size: 24px;
  color: #fff;
  margin-top: 35px;
  margin-bottom: -15px;
  line-height: 1.6;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-shadow: 0 0 20px rgba(102, 126, 234, 0.3);
  animation: introFade 1s ease-out;
}

@keyframes introFade {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background: linear-gradient(90deg, #667eea, #764ba2);
  border-radius: 2px;
}

.timeline-item.active .timeline-marker {
  background: #667eea;
  box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.4);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% {
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.4);
  }
  50% {
    box-shadow: 0 0 0 10px rgba(102, 126, 234, 0.1);
  }
}

/* Override all white backgrounds */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  background: #1a1a2e !important;
  background-color: #1a1a2e !important;
  overflow-x: hidden;
  width: 100%;
}

body,
html body,
body#wrapper,
body #wrapper {
  background: #1a1a2e !important;
  background-color: #1a1a2e !important;
}

#wrapper,
#wrapper.portfolio,
#wrapper.inner {
  background: transparent !important;
  background-color: transparent !important;
}

.wrapper-holder,
.wrapper-holder:not(.grey),
div.wrapper-holder,
div.wrapper-holder:not(.grey) {
  background: transparent !important;
  background-color: transparent !important;
  max-width: 100%;
  overflow-x: hidden;
  box-sizing: border-box;
}

/* Ensure grey background is applied */
.wrapper-holder.grey,
div.wrapper-holder.grey,
#wrapper .wrapper-holder.grey {
  background: #1a1a2e !important;
  background-color: #1a1a2e !important;
}

/* Override any section backgrounds */
section,
#main,
#about,
#career,
#cta {
  background: transparent !important;
  background-color: transparent !important;
}

.about-section,
.career-section,
.cta-section {
  background: #1a1a2e !important;
  background-color: #1a1a2e !important;
}

/* Override any container backgrounds */
.about-container,
.cta-container,
.career-timeline {
  background: transparent !important;
  background-color: transparent !important;
}

.wrapper-holder.grey * {
  color: inherit;
}

.wrapper-holder.grey h2 {
  color: #fff !important;
}

.wrapper-holder.grey #main {
  background: transparent !important;
  background-image: none !important;
}

.wrapper-holder.grey #main h2 {
  color: #fff !important;
}

/* Make all text white in skills section */
.wrapper-holder.grey p,
.wrapper-holder.grey li,
.wrapper-holder.grey span,
.wrapper-holder.grey .skills_holder p,
.wrapper-holder.grey .skills_holder li,
.wrapper-holder.grey .skills_holder span,
.wrapper-holder.grey .progress li,
.wrapper-holder.grey .progress span {
  color: rgba(255, 255, 255, 0.9) !important;
}

/* Override for arcade card subtitle to allow custom color */
.wrapper-holder.grey .arcade-card-subtitle {
  color: rgba(255, 255, 255, 0.65) !important;
}

.wrapper-holder.grey .column p {
  color: rgba(255, 255, 255, 0.8) !important;
}

/* Skills Page - Modern Card-Based Design */
.skills-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Toggle Switch - Matching Portfolio Filter Buttons */
.skills-toggle-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 30px;
  margin-top: 50px;
  margin-bottom: 50px;
  flex-wrap: wrap;
  width: 100%;
}

.skills-toggle-btn {
  padding: 12px 30px;
  background: rgba(26, 22, 37, 0.6);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(102, 126, 234, 0.3);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  font-weight: 600;
  text-transform: uppercase;
  font-size: 13px;
  letter-spacing: 1px;
  position: relative;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  color: rgba(255, 255, 255, 0.8) !important;
  font-family: 'Inter', sans-serif;
  overflow: hidden;
  display: flex;
  align-items: center;
  gap: 8px;
}

.skills-toggle-btn svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  transition: all 0.3s ease;
}

.skills-toggle-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, 
    transparent, 
    rgba(102, 126, 234, 0.3), 
    transparent);
  transition: left 0.5s ease;
}

.skills-toggle-btn:hover::before {
  left: 100%;
}

.skills-toggle-btn:hover {
  border-color: rgba(102, 126, 234, 0.6);
  background: rgba(26, 22, 37, 0.9);
  transform: translateY(-3px) scale(1.05);
  box-shadow: 
    0 8px 25px rgba(102, 126, 234, 0.4),
    0 0 20px rgba(102, 126, 234, 0.2);
  color: #fff !important;
}

.skills-toggle-btn.active {
  background: linear-gradient(135deg, rgba(102, 126, 234, 0.25), rgba(118, 75, 162, 0.25));
  border-color: rgba(102, 126, 234, 0.7);
  box-shadow: 
    0 8px 25px rgba(102, 126, 234, 0.5),
    0 0 25px rgba(102, 126, 234, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  color: #fff !important;
  animation: activePulse 2s ease-in-out infinite;
}

/* Skills Sections Wrapper */
.skills-sections-wrapper {
  position: relative;
  min-height: 500px;
}

.skills-section {
  opacity: 0;
  visibility: hidden;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  transform: translateY(20px);
  transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  pointer-events: none;
}

.skills-section.active {
  opacity: 1;
  visibility: visible;
  position: relative;
  transform: translateY(0);
  pointer-events: all;
}

.skills-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
}

.skills-icon-wrapper {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  border: 2px solid rgba(102, 126, 234, 0.5);
  border-radius: 12px;
  color: #fff;
  flex-shrink: 0;
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.skills-header h2 {
  font-family: 'Inter', sans-serif;
  font-size: 32px;
  font-weight: 700;
  background: linear-gradient(135deg, #fff 0%, #b8a9ff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin: 0;
  letter-spacing: -0.5px;
  text-shadow: 0 0 30px rgba(102, 126, 234, 0.3);
}

.skills-description {
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 80px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
  text-shadow: 0 2px 10px rgba(102, 126, 234, 0.2);
}

.skills-subsection {
  margin-bottom: 48px;
}

.skills-subsection:last-child {
  margin-bottom: 0;
}

.subsection-title {
  font-size: 22px;
  font-weight: 600;
  color: #ffffff !important;
  margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 2px solid rgba(102, 126, 234, 0.3);
  text-shadow: 0 2px 10px rgba(102, 126, 234, 0.2);
  letter-spacing: 0.5px;
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(215px, 265px));
  gap: 16px;
  margin-top: 24px;
  justify-content: start;
}

.skill-card {
  background: rgba(35, 35, 55, 0.9);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 12px;
  padding: 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  position: relative;
  overflow: hidden;
  box-shadow: 
    0 4px 20px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.skill-card:hover {
  transform: translateY(-12px) scale(1.02);
  background: rgba(40, 40, 60, 0.95);
  box-shadow: 
    0 20px 60px rgba(102, 126, 234, 0.4),
    0 0 40px rgba(118, 75, 162, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  border-color: rgba(102, 126, 234, 0.5);
}

.skill-icon {
  width: 62px;
  height: 62px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(20, 20, 30, 0.6);
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.7);
  flex-shrink: 0;
  transition: all 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 7px;
}

.skill-icon img {
  width: 96%;
  height: 96%;
  object-fit: contain;
  opacity: 0.9;
  transition: all 0.3s ease;
}

.skill-icon-text {
  background: rgba(20, 20, 30, 0.6) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
}

.skill-icon-text span {
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: #ffffff;
  text-transform: uppercase;
  letter-spacing: 1.5px;
}


/* Apply white filter only to Unity and Unreal Engine logos */
.skill-icon img.white-logo {
  filter: brightness(0) invert(1);
}

.skill-card:hover .skill-icon {
  background: rgba(26, 26, 46, 0.9);
  border-color: rgba(102, 126, 234, 0.3);
}

.skill-card:hover .skill-icon img {
  opacity: 1;
  transform: scale(1.05);
}

.skill-card:hover .skill-icon img.white-logo {
  filter: brightness(0) invert(1);
}

.skill-content {
  flex: 1;
  min-width: 0;
  position: relative;
}

.skill-content h3 {
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  font-weight: 600;
  color: #ffffff !important;
  margin: 0 0 5px 0;
  line-height: 1.3;
  text-transform: uppercase;
  letter-spacing: 1.3px;
}

.skill-level {
  display: inline-block;
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-top: 4px;
}

.skill-level.skill-advanced {
  background: linear-gradient(135deg, rgba(76, 175, 80, 0.3), rgba(56, 142, 60, 0.3));
  color: #81c784;
  border: 1px solid rgba(76, 175, 80, 0.5);
  box-shadow: 0 2px 8px rgba(76, 175, 80, 0.2);
}

.skill-level.skill-intermediate {
  background: linear-gradient(135deg, rgba(252, 168, 3, 0.25), rgba(255, 193, 7, 0.25));
  color: #ffd54f;
  border: 1px solid rgba(252, 168, 3, 0.4);
  box-shadow: 0 2px 8px rgba(252, 168, 3, 0.15);
}

.skill-level.skill-beginner {
  background: rgba(33, 150, 243, 0.2);
  color: #64b5f6;
  border: 1px solid rgba(33, 150, 243, 0.3);
  box-shadow: 0 2px 8px rgba(33, 150, 243, 0.15);
}


/* Responsive Design for Skills */
@media only screen and (max-width: 980px) {
  .skills-grid {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 16px;
  }
  
  .skills-header h2 {
    font-size: 28px;
  }
  
  .skill-card {
    padding: 20px;
  }
  
  .skills-toggle-btn {
    padding: 10px 20px;
    font-size: 14px;
  }
  
  .skills-toggle-btn svg {
    width: 18px;
    height: 18px;
  }
}

@media only screen and (max-width: 768px) {
  .skills-container {
    padding: 0 15px;
  }
  
  .skills-sections-wrapper {
    min-height: 400px;
  }
  
  .skills-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  
  .skills-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  
  .skills-header h2 {
    font-size: 24px;
  }
  
  .skills-description {
    font-size: 15px;
    margin-bottom: 25px;
  }
  
  .skill-card {
    padding: 18px;
  }
  
  .skill-icon {
    width: 62px;
    height: 62px;
  }
  
  .skill-content h3 {
    font-size: 16px;
    color: #ffffff !important;
  }
  
  .skills-toggle-wrapper {
    flex-direction: column;
    gap: 10px;
    align-items: stretch;
  }
  
  .skills-toggle-btn {
    width: 100%;
    padding: 12px 20px !important;
    font-size: 12px !important;
    justify-content: center;
  }
}

/* Smooth Scrolling */
html {
  scroll-behavior: smooth;
}

/* Responsive Design */

/* Portfolio Page Enhancements */
#portfolio .portfolio-item {
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  overflow: hidden;
  border-radius: 10px;
}

#portfolio .portfolio-item:hover {
  transform: translateY(-10px) scale(1.02);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

#portfolio .portfolio-item img {
  transition: transform 0.6s ease;
}

#portfolio .portfolio-item:hover img {
  transform: scale(1.1);
}

#portfolio .portfolio-item .portfolio-info {
  background: linear-gradient(to top, rgba(102, 126, 234, 0.95), rgba(118, 75, 162, 0.95));
  color: #fff;
}

#portfolio .portfolio-item .portfolio-info h4 {
  color: #fff;
}

#portfolio .portfolio-item .portfolio-info p {
  color: rgba(255, 255, 255, 0.9);
}

/* Navigation Enhancements */
#nav {
  transition: all 0.3s ease;
}

#nav ul li a {
  position: relative;
  transition: all 0.3s ease;
}

#nav ul li a::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #667eea, #764ba2);
  transition: width 0.3s ease;
}

#nav ul li a:hover::after,
#nav ul li a.active::after {
  width: 100%;
}

/* Loading Animation */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

body {
  animation: fadeIn 0.5s ease-in;
}

/* Override old timeline styles */

/* Professional Portfolio Section */
.portfolio-section {
  padding: 90px 40px 15px 40px;
  background: linear-gradient(180deg, #1a1625 0%, #0f0d1a 100%) !important;
  background-color: #1a1625 !important;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.portfolio-section > * {
  width: 100%;
  max-width: 1600px;
  margin-left: auto;
  margin-right: auto;
}

@keyframes titleGlow {
  0%, 100% {
    text-shadow: 
      0 0 25px rgba(102, 126, 234, 0.8),
      0 0 50px rgba(102, 126, 234, 0.5),
      0 4px 0 rgba(0, 0, 0, 0.5);
  }
  50% {
    text-shadow: 
      0 0 35px rgba(102, 126, 234, 1),
      0 0 70px rgba(102, 126, 234, 0.7),
      0 4px 0 rgba(0, 0, 0, 0.5);
  }
}

/* Arcade Grid - Game Boy Cartridge Style */
.arcade-grid,
#container.arcade-grid,
.item-list.arcade-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fill, 320px) !important;
  gap: 40px 40px !important;
  padding: 30px 60px !important;
  max-width: 1800px !important;
  margin: 0 auto !important;
  width: 100% !important;
  list-style: none !important;
  overflow: visible !important;
  text-align: left !important;
  justify-content: center !important;
}

/* Bottom gap after grid - ensures space even when scrolling */
#wrapper.portfolio .wrapper-holder.grey {
  padding-bottom: 15px !important;
}

#wrapper.portfolio .portfolio-section {
  padding-bottom: 0 !important;
  margin-bottom: 0 !important;
}

.arcade-grid li,
#container.arcade-grid li,
.item-list.arcade-grid li {
  width: 320px !important;
  margin: 0 !important;
  padding: 0 !important;
  display: block !important;
  font-size: initial !important;
}

.arcade-card,
.arcade-grid .item {
  position: relative;
  list-style: none;
  margin: 0 !important;
  width: 330px !important;
  height: 400px !important;
  display: block !important;
  text-align: left !important;
  cursor: pointer;
}

.arcade-card[style*="display: none"] {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  height: 0 !important;
  width: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: hidden !important;
}

.arcade-card-inner {
  background: rgba(26, 26, 46, 0.8);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  position: relative;
  box-shadow: 
    0 4px 20px rgba(0, 0, 0, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
  padding: 0;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.arcade-card-inner::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: linear-gradient(45deg, 
    rgba(102, 126, 234, 0.5), 
    rgba(118, 75, 162, 0.5), 
    rgba(252, 168, 3, 0.5), 
    rgba(102, 126, 234, 0.5));
  background-size: 300% 300%;
  border-radius: 12px;
  z-index: -1;
  opacity: 0;
  transition: opacity 0.4s ease;
  animation: borderGlow 3s ease-in-out infinite;
}

.arcade-card-inner::after {
  content: '';
  position: absolute;
  top: 8px;
  left: 8px;
  width: 20px;
  height: 20px;
  border-top: 2px solid rgba(102, 126, 234, 0.6);
  border-left: 2px solid rgba(102, 126, 234, 0.6);
  border-radius: 4px 0 0 0;
  opacity: 0;
  transition: opacity 0.4s ease;
  z-index: 2;
}

@keyframes borderGlow {
  0%, 100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

.arcade-card:hover .arcade-card-inner {
  transform: translateY(-12px) scale(1.02);
  box-shadow: 
    0 20px 60px rgba(102, 126, 234, 0.4),
    0 0 40px rgba(118, 75, 162, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  border-color: rgba(102, 126, 234, 0.5);
}

.arcade-card:hover .arcade-card-inner::before {
  opacity: 1;
}

.arcade-card:hover .arcade-card-inner::after {
  opacity: 1;
  animation: cornerPulse 1.5s ease-in-out infinite;
}

.arcade-card:hover .arcade-card-inner .arcade-card-screen::after {
  content: '';
  position: absolute;
  bottom: 8px;
  right: 8px;
  width: 20px;
  height: 20px;
  border-bottom: 2px solid rgba(118, 75, 162, 0.6);
  border-right: 2px solid rgba(118, 75, 162, 0.6);
  border-radius: 0 0 4px 0;
  opacity: 1;
  z-index: 2;
  animation: cornerPulse 1.5s ease-in-out infinite 0.3s;
}

@keyframes cornerPulse {
  0%, 100% {
    opacity: 0.6;
    transform: scale(1);
  }
  50% {
    opacity: 1;
    transform: scale(1.1);
  }
}

.arcade-card-screen {
  position: relative;
  width: 100%;
  height: 220px;
  overflow: hidden;
  background: #0a0a12;
  border: none;
  border-radius: 0;
  margin-bottom: 0;
  box-shadow: none;
  flex-shrink: 0;
}

.arcade-card-screen img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  filter: brightness(0.92) contrast(1.08) saturate(1.05);
}

.arcade-card:hover .arcade-card-screen img {
  transform: scale(1.08);
  filter: brightness(1.05) contrast(1.15) saturate(1.15);
}

/* Subtle overlay effect */
.scanlines {
  display: none;
}

@keyframes scanlineMove {
  0% {
    background-position: 0 0;
  }
  100% {
    background-position: 0 20px;
  }
}

.arcade-card-info {
  padding: 22px 24px 24px;
  text-align: center;
  background: rgba(20, 20, 30, 0.65);
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

/* Label border effect */
.arcade-card-info::before {
  content: '';
  position: absolute;
  top: 0;
  left: 8px;
  right: 8px;
  height: 1px;
  background: rgba(102, 126, 234, 0.4);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.5);
}

.arcade-card-title {
  font-size: 19px;
  font-weight: 700;
  color: #fff !important;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 6px;
  font-family: 'Inter', sans-serif;
  line-height: 1.3;
  transition: all 0.3s ease;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  flex-shrink: 0;
}

.arcade-card:hover .arcade-card-title {
  color: #fff !important;
}

/* Force white color for portfolio titles - override any other CSS */
.portfolio-section h1,
.portfolio-section .arcade-title,
.portfolio-section h1.arcade-title {
  color: #fff !important;
}

.portfolio-section h3,
.portfolio-section .arcade-card-title,
.portfolio-section h3.arcade-card-title {
  color: #fff !important;
}

.arcade-card-subtitle,
.arcade-card-info .arcade-card-subtitle,
.wrapper-holder.grey .arcade-card-subtitle,
.portfolio-section .arcade-card-subtitle {
  font-size: 12px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.7) !important;
  text-transform: capitalize;
  letter-spacing: 0.5px;
  margin-top: 0;
  margin-bottom: 0px;
  line-height: 1.2;
  font-family: 'Inter', sans-serif;
  flex-shrink: 0;
  vertical-align: middle;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 9px;
  flex-wrap: wrap;
}

.arcade-card-tags {
  display: flex;
  flex-wrap: nowrap;
  gap: 5px;
  justify-content: center;
  align-items: center;
  margin-bottom: 10px;
  margin-top: 0;
  padding: 0;
  height: 53px;
  flex-shrink: 0;
  align-content: flex-start;
  vertical-align: middle;
}

.arcade-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.95);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 4px 9px;
  position: relative;
  border: none;
  border-radius: 6px;
  background: linear-gradient(135deg, 
    rgba(102, 126, 234, 0.2) 0%, 
    rgba(118, 75, 162, 0.15) 100%);
  font-family: 'Inter', sans-serif;
  line-height: 1.3;
  white-space: nowrap;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  box-shadow: 
    0 2px 8px rgba(0, 0, 0, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.1),
    0 0 0 1px rgba(102, 126, 234, 0.3);
  overflow: hidden;
  flex-shrink: 0;
}


.arcade-card-details {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.55);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  font-weight: 500;
  font-family: 'Inter', sans-serif;
  margin-top: 0;
  line-height: 1.5;
  flex-shrink: 0;
}

.arcade-card-link {
  position: absolute;
  top: 0;
  left: 1px;
  width: 100%;
  height: 100%;
  z-index: 10;
  text-decoration: none;
  cursor: pointer;
  display: block;
}

/* Arcade Portfolio Modal - Redesigned */

.popup_portfolio {
  max-width: 900px;
  width: 90%;
  margin: 0 auto;
  background: linear-gradient(135deg, rgba(26, 22, 37, 0.98), rgba(15, 13, 26, 0.98));
  backdrop-filter: blur(20px);
  border: 4px solid #667eea;
  border-radius: 12px;
  padding: 0;
  position: relative;
  overflow: visible;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
  max-height: 85vh;
  overflow-y: auto;
  overflow-x: hidden;
}

/* CRT Screen effect for modal */
.popup_portfolio::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
 /* background: 
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 1px,
      rgba(0, 0, 0, 0.1) 1px,
      rgba(0, 0, 0, 0.1) 2px
    );
    */
  pointer-events: none;
  z-index: 1;
  opacity: 0.3;
  mix-blend-mode: overlay;
}

.popup_portfolio::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  /*
  background: 
    radial-gradient(
      ellipse at center,
      transparent 0%,
      transparent 50%,
      rgba(0, 0, 0, 0.2) 90%,
      rgba(0, 0, 0, 0.4) 100%
    );
    */
  pointer-events: none;
  z-index: 1;
  mix-blend-mode: multiply;
}

.popup_portfolio > * {
  position: relative;
  z-index: 2;
}

.popup_portfolio img {
  width: 100%;
  height: auto;
  border-radius: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  display: block;
  filter: brightness(0.95) contrast(1.05);
}

.popup_portfolio h3 {
  padding: 30px 40px 10px;
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  color: #fff !important;
  font-size: 28px;
  line-height: 1.3;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin: 0;
}

.popup_portfolio time {
  display: block;
  padding: 0 40px 0;
  font-family: 'Inter', sans-serif;
  color: rgba(255, 255, 255, 0.7) !important;
  font-size: 13px;
  line-height: 1.5;
  text-transform: uppercase;
  letter-spacing: 2px;
  text-shadow: 0 1px 0 rgba(0, 0, 0, 0.8);
  margin-bottom: 0;
}

.popup_portfolio p {
  padding: 15px 40px;
  color: rgba(255, 255, 255, 0.9) !important;
  font-size: 16px;
  line-height: 1.8;
  font-family: 'Inter', sans-serif;
  margin: 0;
  text-shadow: 0 1px 0 rgba(0, 0, 0, 0.5);
}

.popup_portfolio p:first-of-type {
  padding-top: 20px;
}

.popup_portfolio time + p {
  font-style: italic !important;
  padding-top: 0 !important;
  margin-top: 0 !important;
}

/* Remove spacing between paragraphs and lists */
.popup_portfolio p + ul {
  margin-top: -15px !important;
  padding-top: 0 !important;
}

.popup_portfolio ul {
  padding: 10px 40px 30px;
  margin: 0;
  list-style: none !important;
  list-style-type: none !important;
}

.popup_portfolio ul li {
  font-size: 15px;
  margin: 12px 0;
  padding-left: 25px;
  color: rgba(255, 255, 255, 0.85) !important;
  line-height: 1.6;
  font-family: 'Inter', sans-serif;
  position: relative;
  text-shadow: 0 1px 0 rgba(0, 0, 0, 0.5);
  list-style: none !important;
  list-style-type: none !important;
}

.popup_portfolio ul li::before {
  content: '•';
  position: absolute;
  left: 0;
  color: rgba(255, 255, 255, 0.4);
  font-size: 16px;
  font-weight: bold;
}

.popup_portfolio ul li::marker {
  display: none !important;
  content: '' !important;
}

.popup_portfolio a {
  color: #667eea !important;
  text-decoration: underline;
  text-decoration-color: rgba(102, 126, 234, 0.5);
  text-underline-offset: 3px;
  transition: all 0.3s ease;
  display: inline !important;
  margin: 0 !important;
  padding: 0 !important;
  margin-left: 0 !important;
  padding-left: 0 !important;
}

.popup_portfolio a:hover {
  color: #764ba2 !important;
  text-decoration-color: rgba(118, 75, 162, 0.7);
}

.popup_portfolio u {
  text-decoration: none;
  display: inline !important;
  margin: 0 !important;
  padding: 0 !important;
  margin-left: 0 !important;
  padding-left: 0 !important;
}

.popup_portfolio p u,
.popup_portfolio p a {
  display: inline !important;
  margin: 0 !important;
  padding: 0 !important;
  margin-left: 0 !important;
  padding-left: 0 !important;
}

.popup_portfolio p u a,
.popup_portfolio u a {
  display: inline !important;
  margin: 0 !important;
  padding: 0 !important;
  margin-left: 0 !important;
  padding-left: 0 !important;
}

/* Ensure u tags with br tags are properly aligned */
.popup_portfolio u + br + u {
  display: inline-block !important;
  width: 100%;
  margin-top: 8px;
}

.popup_portfolio br + u {
  display: inline-block !important;
  width: 100%;
  margin-top: 8px;
}

/* Override any list-style or padding that might affect links */
.popup_portfolio > u {
  display: block !important;
  margin: 0 !important;
  padding: 0 0 0 40px !important;
  margin-top: 8px !important;
}

.popup_portfolio > u a {
  display: inline !important;
  margin: 0 !important;
  padding: 0 !important;
}

.popup_portfolio > br + u {
  display: block !important;
  padding-left: 40px !important;
  margin-top: 8px !important;
}

/* Fancybox container styling - CRITICAL for popup background */
.fancybox-wrap {
  left: 50% !important;
  top: 50% !important;
  transform: translate(-50%, -50%) !important;
  margin: 0 !important;
  max-height: 90vh;
  overflow: visible !important; /* Allow arrows to be positioned outside */
}

/* Create a blocking overlay that prevents navigation arrow clicks in the top-right corner */
/* Positioned to avoid overlapping the close button (which is at right: -20px, width: 40px) */
.fancybox-wrap::before {
  content: '';
  position: absolute;
  top: -30px;
  right: 30px; /* Start after close button area */
  width: calc(40% - 30px); /* Match right navigation width minus the blocked area */
  height: 60px;
  z-index: 8041 !important; /* Just above navigation (8040) but below close button (9999) */
  pointer-events: auto; /* Block navigation clicks in this area */
  background: transparent;
}

.fancybox-skin {
  background: transparent !important;
  padding: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  overflow: visible !important; /* Allow arrows to be positioned outside */
}

.fancybox-opened .fancybox-skin {
  padding: 0 !important;
  border-radius: 0 !important;
}

/* Custom scrollbar styling for popup portfolio */
.popup_portfolio::-webkit-scrollbar,
.fancybox-inner::-webkit-scrollbar,
.fancybox-wrap::-webkit-scrollbar,
.fancybox-skin::-webkit-scrollbar {
  width: 12px;
  height: 12px;
}

.popup_portfolio::-webkit-scrollbar-track,
.fancybox-inner::-webkit-scrollbar-track,
.fancybox-wrap::-webkit-scrollbar-track,
.fancybox-skin::-webkit-scrollbar-track {
  background: rgba(26, 26, 46, 0.4);
  border-radius: 6px;
}

.popup_portfolio::-webkit-scrollbar-thumb,
.fancybox-inner::-webkit-scrollbar-thumb,
.fancybox-wrap::-webkit-scrollbar-thumb,
.fancybox-skin::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #667eea 0%, #764ba2 100%);
  border-radius: 6px;
  border: 2px solid rgba(26, 26, 46, 0.6);
}

.popup_portfolio::-webkit-scrollbar-thumb:hover,
.fancybox-inner::-webkit-scrollbar-thumb:hover,
.fancybox-wrap::-webkit-scrollbar-thumb:hover,
.fancybox-skin::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #7e8ff0 0%, #8d5cb8 100%);
  border: 2px solid rgba(26, 26, 46, 0.8);
}

/* Firefox scrollbar styling */
.popup_portfolio,
.fancybox-inner,
.fancybox-wrap,
.fancybox-skin {
  scrollbar-width: thin;
  scrollbar-color: #667eea rgba(26, 26, 46, 0.4);
}

.fancybox-stage {
  overflow: visible !important;
}

.fancybox-inner {
  overflow: visible !important; /* Allow arrows to be positioned outside */
}

.fancybox-outer {
  overflow: visible !important; /* Allow arrows to be positioned outside */
}

/* Fancybox close button - Professional style */
/* Using fixed positioning to prevent drift as viewport width changes */
.fancybox-close {
  width: 40px !important;
  height: 40px !important;
  /* Position relative to .fancybox-skin top-right corner */
  top: -20px !important;
  right: 28px !important;
  left: auto !important;
  background: rgba(20, 20, 30, 0.95) !important;
  backdrop-filter: blur(10px);
  border: 2px solid rgba(102, 126, 234, 0.6) !important;
  border-radius: 50% !important;
  background-image: none !important;
  position: absolute !important;
  z-index: 9999 !important;
  cursor: pointer !important;
  transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4), 0 0 15px rgba(102, 126, 234, 0.3);
  pointer-events: auto !important;
}

/* Ensure navigation arrows don't interfere with close button or scrolling */
.fancybox-nav {
  z-index: 8040 !important; /* Match Fancybox default, but lower than close button */
  pointer-events: none !important; /* Allow scroll events to pass through the navigation area */
  cursor: default !important;
}

.fancybox-prev,
.fancybox-next {
  z-index: 8040 !important;
  pointer-events: none !important; /* Allow scroll events to pass through */
  cursor: default !important;
}

/* Make only the arrow icon clickable, not the entire navigation area */
.fancybox-nav span {
  pointer-events: auto !important; /* Only the arrow icon is clickable */
  cursor: pointer !important;
  visibility: visible !important; /* Always show arrows so users know they can click */
  /* Space arrows further from the popup box */
  width: 50px !important;
  height: 50px !important;
  margin-top: -25px !important;
  /* Style to match popup color scheme */
  background: rgba(20, 20, 30, 0.85) !important;
  backdrop-filter: blur(10px) !important;
  border: 2px solid rgba(102, 126, 234, 0.5) !important;
  border-radius: 50% !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  transition: all 0.3s ease !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3), 0 0 15px rgba(102, 126, 234, 0.2) !important;
}

/* Position arrows further outside the popup box */
.fancybox-prev span {
  left: -70px !important;
  background-position: center center !important;
  background-size: 20px 20px !important;
  background-repeat: no-repeat !important;
  background-image: none !important;
}

.fancybox-next span {
  right: -70px !important;
  background-position: center center !important;
  background-size: 20px 20px !important;
  background-repeat: no-repeat !important;
  background-image: none !important;
}

/* Create arrow icons using pseudo-elements to match color scheme */
.fancybox-prev span::before {
  content: '';
  position: absolute;
  width: 0;
  height: 0;
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  border-right: 12px solid rgba(102, 126, 234, 0.9);
  left: 50%;
  top: 50%;
  transform: translate(-60%, -50%);
  transition: all 0.3s ease;
}

.fancybox-next span::before {
  content: '';
  position: absolute;
  width: 0;
  height: 0;
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  border-left: 12px solid rgba(102, 126, 234, 0.9);
  left: 50%;
  top: 50%;
  transform: translate(-40%, -50%);
  transition: all 0.3s ease;
}

/* Hover effects */
.fancybox-nav span:hover {
  background: rgba(30, 30, 40, 0.95) !important;
  border-color: rgba(102, 126, 234, 0.8) !important;
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4), 0 0 20px rgba(102, 126, 234, 0.4) !important;
}

.fancybox-prev span:hover::before {
  border-right-color: rgba(118, 75, 162, 1);
}

.fancybox-next span:hover::before {
  border-left-color: rgba(118, 75, 162, 1);
}

/* Navigation arrows - positioned below the blocking overlay */
/* The ::before pseudo-element on .fancybox-wrap creates a dead zone in top-right corner */

/* Ensure close button is always on top and clickable */
.fancybox-close {
  pointer-events: auto !important;
  z-index: 9999 !important;
}

.fancybox-close::before,
.fancybox-close::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 16px;
  height: 1.5px;
  background: rgba(255, 255, 255, 0.7);
  transform: translate(-50%, -50%) rotate(45deg);
}

.fancybox-close::after {
  transform: translate(-50%, -50%) rotate(-45deg);
}

.fancybox-close:hover {
  background: rgba(30, 30, 40, 0.9) !important;
  border-color: rgba(255, 255, 255, 0.2) !important;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.5), 0 0 20px rgba(102, 126, 234, 0.4);
}

.fancybox-close:hover::before,
.fancybox-close:hover::after {
  background: #fff;
}

/* Fancybox overlay - Dark with purple tint */
.fancybox-overlay {
  background: rgba(10, 8, 18, 0.95) !important;
  backdrop-filter: blur(5px);
}

/* Hide prev/next buttons on small screens where they don't fit */
@media (max-width: 1050px) {
  .fancybox-prev,
  .fancybox-next,
  .fancybox-nav {
    display: none !important;
    visibility: hidden !important;
  }
}

/* Responsive modal */

@media (max-width: 480px) {
  .popup_portfolio {
    max-height: 85vh;
    overflow-y: auto;
    overflow-x: hidden;
  }
  
  .popup_portfolio img {
    max-height: 150px;
    object-fit: cover;
  }
  
  .popup_portfolio h3 {
    padding: 20px 15px 10px;
    font-size: 20px;
  }
  
  .popup_portfolio time {
    padding: 0 15px 10px;
  }
  
  .popup_portfolio p {
    padding: 10px 15px;
  }
  
  .popup_portfolio ul {
    padding: 10px 15px 20px;
  }
  
  .popup_portfolio ul li {
    margin: 6px 0;
    line-height: 1.4;
    font-size: 13px;
  }
  
  .popup_portfolio p {
    line-height: 1.5;
    margin-bottom: 10px;
  }
}

/* Arcade Filter Buttons */
.arcade-filters {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 30px;
  margin-top: 0;
  margin-bottom: 30px;
  flex-wrap: wrap;
  list-style: none;
  padding: 0;
  width: 100%;
}

.filter-btn {
  padding: 12px 30px;
  background: rgba(26, 22, 37, 0.6);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(102, 126, 234, 0.3);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  font-weight: 600;
  text-transform: uppercase;
  font-size: 13px;
  letter-spacing: 1px;
  position: relative;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  color: rgba(255, 255, 255, 0.8) !important;
  font-family: 'Inter', sans-serif;
  overflow: hidden;
}

.filter-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, 
    transparent, 
    rgba(102, 126, 234, 0.3), 
    transparent);
  transition: left 0.5s ease;
}

.filter-btn:hover::before {
  left: 100%;
}

.filter-btn:hover {
  border-color: rgba(102, 126, 234, 0.6);
  background: rgba(26, 22, 37, 0.9);
  transform: translateY(-3px) scale(1.05);
  box-shadow: 
    0 8px 25px rgba(102, 126, 234, 0.4),
    0 0 20px rgba(102, 126, 234, 0.2);
  color: #fff !important;
}

.filter-btn.active {
  background: linear-gradient(135deg, rgba(102, 126, 234, 0.25), rgba(118, 75, 162, 0.25));
  border-color: rgba(102, 126, 234, 0.7);
  box-shadow: 
    0 8px 25px rgba(102, 126, 234, 0.5),
    0 0 25px rgba(102, 126, 234, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  color: #fff !important;
  animation: activePulse 2s ease-in-out infinite;
}

@keyframes activePulse {
  0%, 100% {
    box-shadow: 
      0 8px 25px rgba(102, 126, 234, 0.5),
      0 0 25px rgba(102, 126, 234, 0.3),
      inset 0 1px 0 rgba(255, 255, 255, 0.1);
  }
  50% {
    box-shadow: 
      0 8px 30px rgba(102, 126, 234, 0.6),
      0 0 35px rgba(102, 126, 234, 0.4),
      inset 0 1px 0 rgba(255, 255, 255, 0.15);
  }
}

.arcade-filters li {
  padding: 15px 35px;
  background: linear-gradient(135deg, rgba(26, 26, 46, 0.9), rgba(40, 41, 43, 0.9));
  border: 3px solid #667eea;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  font-weight: 800;
  text-transform: uppercase;
  font-size: 14px;
  letter-spacing: 3px;
  position: relative;
  overflow: hidden;
  box-shadow: 
    0 5px 15px rgba(102, 126, 234, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.arcade-filters li:hover {
  border-color: #aeecc2;
  transform: translateY(-3px) scale(1.05);
  box-shadow: 
    0 10px 30px rgba(102, 126, 234, 0.5),
    0 0 25px rgba(174, 236, 194, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.arcade-filters li:hover .filter-glow {
  color: #fff;
  text-shadow: 
    0 0 15px rgba(255, 255, 255, 1),
    0 0 30px rgba(174, 236, 194, 0.8);
}

.arcade-filters li.active {
  background: linear-gradient(135deg, rgba(102, 126, 234, 0.3), rgba(118, 75, 162, 0.3));
  border-color: #aeecc2;
  box-shadow: 
    0 10px 30px rgba(102, 126, 234, 0.6),
    0 0 30px rgba(174, 236, 194, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.arcade-filters li.active .filter-glow {
  color: #fff;
  text-shadow: 
    0 0 20px rgba(255, 255, 255, 1),
    0 0 40px rgba(174, 236, 194, 1);
}

/* Responsive Arcade Portfolio */
@media (max-width: 1400px) {
  .arcade-grid,
  #container.arcade-grid,
  .item-list.arcade-grid {
    gap: 30px !important;
    padding: 30px 30px !important;
  }
}

@media (max-width: 1100px) {
  .arcade-grid,
  #container.arcade-grid,
  .item-list.arcade-grid {
    gap: 25px !important;
    padding: 25px 20px !important;
    grid-template-columns: repeat(auto-fill, 300px) !important;
    justify-content: center !important;
  }
  
  .arcade-grid li,
  #container.arcade-grid li,
  .item-list.arcade-grid li {
    width: 300px !important;
  }
  
  .arcade-card,
  .arcade-grid .item {
    width: 300px !important;
  }
}


/* Portfolio filter buttons */

.sub_nav li.active {
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 5px 20px rgba(102, 126, 234, 0.5);
}

/* Contact Section - Modern Design */
.contact-section {
  padding: 100px 40px;
  min-height: calc(100vh - 200px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  max-width: 1200px;
  margin: 0 auto;
}

.contact-header {
  text-align: center;
  margin-bottom: 50px;
}

.contact-profile {
  margin-bottom: 25px;
  display: flex;
  justify-content: center;
}

.profile-image {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid rgba(102, 126, 234, 0.3);
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.3),
    0 0 0 8px rgba(26, 26, 46, 0.5);
}

.contact-title {
  font-size: 48px;
  font-weight: 700;
  color: #fff !important;
  text-transform: uppercase;
  letter-spacing: 3px;
  margin-bottom: 16px;
  font-family: 'Inter', sans-serif;
}

.contact-subtitle {
  font-size: 18px;
  color: rgba(255, 255, 255, 0.7) !important;
  font-weight: 400;
  font-family: 'Inter', sans-serif;
  margin: 0;
}

.contact-content {
  display: flex;
  gap: 120px;
  flex-wrap: wrap;
  justify-content: center;
  width: 100%;
  max-width: 900px;
}

.contact-card-link {
  flex: 1;
  min-width: 300px;
  max-width: 400px;
  text-decoration: none;
  display: block;
}

.contact-card {
  width: 100%;
  background: rgba(26, 26, 46, 0.8);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 40px;
  text-align: center;
  transition: all 0.3s ease;
  box-shadow: 
    0 4px 20px rgba(0, 0, 0, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.contact-card-link:hover .contact-card {
  transform: translateY(-8px);
  box-shadow: 
    0 12px 40px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  border-color: rgba(102, 126, 234, 0.3);
}

.contact-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 24px;
  background: rgba(102, 126, 234, 0.1);
  border: 2px solid rgba(102, 126, 234, 0.2);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #667eea;
  transition: all 0.3s ease;
}

.contact-card-link:hover .contact-icon {
  background: rgba(102, 126, 234, 0.2);
  border-color: rgba(102, 126, 234, 0.4);
  transform: scale(1.1);
  color: #764ba2;
}

.contact-card-title {
  font-size: 20px;
  font-weight: 600;
  color: #fff !important;
  margin-bottom: 16px;
  font-family: 'Inter', sans-serif;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.contact-link {
  display: inline-block;
  color: rgba(255, 255, 255, 0.8) !important;
  font-size: 16px;
  font-weight: 500;
  text-decoration: none;
  font-family: 'Inter', sans-serif;
  transition: all 0.3s ease;
  border-bottom: 1px solid transparent;
  padding-bottom: 2px;
}

.contact-card-link:hover .contact-link {
  color: #fff !important;
  border-bottom-color: #667eea;
}

/* Responsive Contact */

/* Consistent header styling across all pages - override original green background */
.wrapper-holder:not(.grey) {
  background: #28292b !important;
}

.wrapper-holder:not(.grey) #header {
  background: transparent !important;
}

/* Fix for index.html specifically - transparent over hero */
#wrapper:has(.hero-section) .wrapper-holder:not(.grey) {
  background: transparent !important;
}

#wrapper:has(.hero-section) .wrapper-holder:not(.grey) #header {
  background: transparent !important;
}

/* Header adjustments for hero section */
.hero-section {
  position: relative;
  z-index: 1;
}

#wrapper:has(.hero-section) .wrapper-holder:not(.grey) {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background: transparent !important;
  transition: background 0.3s ease;
}

#wrapper:has(.hero-section) .wrapper-holder:not(.grey).scrolled {
  background: rgba(40, 41, 43, 0.95) !important;
  backdrop-filter: blur(10px);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}

#wrapper:has(.hero-section) #header {
  padding: 20px 0 !important;
  margin: 0 auto !important;
  max-width: 100% !important;
  background: transparent !important;
}

#wrapper:has(.hero-section) #header .logo,
#wrapper:has(.hero-section) #header .slogan {
  display: none;
}

#wrapper:has(.hero-section) #header #nav {
  margin: 0 auto !important;
}

#wrapper:has(.hero-section) #header #nav ul li a {
  color: #fff;
  border-bottom-color: rgba(255, 255, 255, 0.5);
}

#wrapper:has(.hero-section) .wrapper-holder:not(.grey).scrolled #header #nav ul li a {
  color: #aeecc2;
  border-bottom-color: #aeecc2;
}

#wrapper:has(.hero-section) #header #nav ul li a:hover,
#wrapper:has(.hero-section) #header #nav ul li a.active {
  color: #fff;
  border-bottom-color: #fff;
}

#wrapper:has(.hero-section) .wrapper-holder:not(.grey).scrolled #header #nav ul li a:hover,
#wrapper:has(.hero-section) .wrapper-holder:not(.grey).scrolled #header #nav ul li a.active {
  color: #fff;
  border-bottom-color: #fff;
}

/* Navigation styling for all pages (non-hero pages) */
#wrapper:not(:has(.hero-section)) .wrapper-holder:not(.grey) {
  background: #28292b !important;
}

#wrapper:not(:has(.hero-section)) #header {
  background: transparent !important;
  padding: 69px 0 50px !important;
}

#wrapper:not(:has(.hero-section)) #header #nav ul li a {
  color: #aeecc2;
  border-bottom-color: #62bb7f;
}

#wrapper:not(:has(.hero-section)) #header #nav ul li a:hover,
#wrapper:not(:has(.hero-section)) #header #nav ul li a.active {
  color: #fff;
  border-bottom-color: #fff;
}

/* Additional overrides to ensure no white backgrounds */

.wrapper-holder:not(.grey) {
  background: #28292b !important;
}

/* For pages with hero section, make header transparent */
body:has(.hero-section) .wrapper-holder:not(.grey) {
  background: transparent !important;
}

body:has(.hero-section) #header {
  background: transparent !important;
}

/* Smooth transitions for all interactive elements */
* {
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

/* Final overrides to ensure no white/green backgrounds on navigation */
.wrapper-holder:not(.grey),
#wrapper .wrapper-holder:not(.grey),
body .wrapper-holder:not(.grey) {
  background: #28292b !important;
}

#header,
#wrapper #header,
body #header {
  background: transparent !important;
}

/* Hero section pages get transparent header */
body:has(.hero-section) .wrapper-holder:not(.grey),
body:has(.hero-section) #header {
  background: transparent !important;
}

/* Additional scroll animations */
@keyframes slideInFromLeft {
  from {
    opacity: 0;
    transform: translateX(-50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInFromRight {
  from {
    opacity: 0;
    transform: translateX(50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Enhanced button styles */
a.btn-primary, a.btn-secondary {
  position: relative;
  overflow: hidden;
}

a.btn-primary::before, a.btn-secondary::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

a.btn-primary:hover::before, a.btn-secondary:hover::before {
  width: 300px;
  height: 300px;
}

/* Disable transitions during window resize to prevent jitter */
body.resizing * {
  transition: none !important;
  animation-play-state: paused !important; /* Pause animations during resize */
}

/* Exclude particles and typing text from animation disable - keep them running */
body.resizing .particle {
  animation: float 4s infinite ease-in-out !important;
}

body.resizing .particle-glow {
  animation: floatGlow 5s infinite ease-in-out !important;
}

body.resizing .particle-trail {
  animation: floatTrail 6s infinite ease-in-out !important;
}

body.resizing .retro-sidebar {
  transition: transform 0.1s ease !important;
}

/* Optimize transitions - reduce repaints during resize */
@media (max-width: 1024px) {
  /* Reduce layout shifts and improve performance */
  .career-item,
  .arcade-card {
    transform: translateZ(0);
    -webkit-transform: translateZ(0);
  }
}

/* ============================================
   COMPREHENSIVE MOBILE RESPONSIVENESS
   ============================================ */

/* Mobile Sidebar Navigation */
@media (max-width: 1024px) {
  #wrapper {
    margin-left: 60px !important;
    width: calc(100% - 60px) !important;
  }
  
  .wrapper-holder {
    margin-left: 0 !important;
    padding-left: 20px !important;
    padding-right: 20px !important;
    max-width: 100vw !important;
    overflow-x: hidden !important;
  }
  
  /* Prevent sidebar header text from scaling */
  .sidebar-logo {
    font-size: 24px !important;
  }
  
  .sidebar-slogan {
    font-size: 13px !important;
  }
}

@media (max-width: 1024px) {
  /* Sidebar - Collapsed by default (60px), toggle with hamburger to full width (280px) */
  .retro-sidebar {
    width: 60px;
    transform: translateX(0);
    transition: width 0.3s ease, transform 0.3s ease;
    z-index: 9999;
    visibility: visible;
    display: flex;
  }
  
  .retro-sidebar.open {
    width: 280px;
    transform: translateX(0) !important;
    visibility: visible !important;
    display: flex !important;
  }
  
  /* Hamburger Menu Button */
  .menu-toggle {
    position: fixed;
    top: 58px;
    left: 18px;
    right: auto;
    width: 34px;
    height: 34px;
    z-index: 900;
    background: rgba(40, 45, 60, 0.9);
    border: 1px solid rgba(102, 126, 234, 0.35);
    border-radius: 6px;
    display: flex !important;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    padding: 6px;
    backdrop-filter: blur(12px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.35);
    pointer-events: auto !important;
    visibility: visible !important;
  }
  
  .menu-toggle span {
    display: block;
    width: 18px;
    height: 2px;
    background: rgba(200, 205, 220, 0.9);
    border-radius: 2px;
    transition: all 0.2s ease;
  }

  #wrapper.portfolio .menu-toggle,
  #wrapper.inner .menu-toggle {
    top: 24px;
  }
  
  .menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
  }
  
  .menu-toggle.active span:nth-child(2) {
    opacity: 0;
  }
  
  .menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
  }
  
  /* Overlay when sidebar is open */
  .sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    z-index: 9998;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    display: block;
  }
  
  .sidebar-overlay.active {
    opacity: 1;
    pointer-events: auto;
  }
  
  /* Sidebar header adjustments for mobile - only when sidebar is open */
  .retro-sidebar.open .sidebar-header {
    padding-top: 60px !important; /* Add space at top so hamburger doesn't overlap */
  }
  
  /* Keep sidebar header text consistent at all mobile sizes - only when open */
  .retro-sidebar.open .sidebar-logo {
    font-size: 24px !important;
  }
  
  .retro-sidebar.open .sidebar-slogan {
    font-size: 13px !important;
  }
  
  /* Fix Fancybox popup positioning - center between collapsed sidebar (60px) and window edge */
  .fancybox-wrap {
    left: calc(30px + 50vw) !important;
    transform: translate(-50%, -50%) !important;
  }
  
}

/* Extra small mobile stat items (between 480-600px) */
@media (max-width: 600px) and (min-width: 481px) {
  .hero-stats {
    gap: 8px !important;
  }
  
  .stat-item {
    width: calc(50% - 8px) !important;
    min-width: unset !important;
    max-width: none !important;
    padding: 10px 12px !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    align-items: center !important;
  }
  
  .stat-item:last-child {
    width: 50% !important;
  }
  
  .stat-number {
    font-size: 20px !important;
  }
  
  .stat-label {
    font-size: 11px !important;
    letter-spacing: 0.5px !important;
  }
}


/* Hide mobile menu on desktop */
@media (min-width: 1025px) {
  .sidebar-overlay {
    display: none !important;
  }
  
  /* Only show sidebar if not collapsed */
  .retro-sidebar:not(.collapsed) {
    transform: translateX(0);
  }
}

/* Respect user's motion preferences */
/* Disabled prefers-reduced-motion to allow animations on all devices */
/* @media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  
  .particles {
    display: none !important;
  }
} */

/* Performance optimizations for mobile - only hide particles */
@media (max-width: 768px) {
  /* Hide sidebar completely on mobile when not open */
  .retro-sidebar:not(.open) {
    transform: translateX(-100%) !important;
    width: 240px !important;
  }
  
  /* Ensure sidebar shows all text when open on mobile - narrower width */
  .retro-sidebar.open {
    transform: translateX(0) !important;
    width: 240px !important;
    z-index: 9999 !important;
  }
  
  .retro-sidebar.open .sidebar-header {
    padding: 25px 20px 20px !important;
    min-height: auto !important;
    height: auto !important;
  }
  
  .retro-sidebar.open .retro-screen {
    display: block !important;
  }
  
  .retro-sidebar.open .sidebar-initials {
    display: none !important;
  }
  
  .retro-sidebar.open .sidebar-logo {
    font-size: 20px !important;
  }
  
  .retro-sidebar.open .sidebar-slogan {
    font-size: 11px !important;
  }
  
  .retro-sidebar.open .retro-menu {
    padding: 20px 15px !important;
    display: flex !important;
    flex-direction: column !important;
  }
  
  .retro-sidebar.open .retro-menu-item {
    display: flex !important;
    padding: 14px 20px !important;
    justify-content: flex-start !important;
    align-items: center !important;
    border-left: 3px solid transparent !important;
    border-bottom: none !important;
    opacity: 1 !important;
    visibility: visible !important;
  }
  
  .retro-sidebar.open .menu-text {
    opacity: 1 !important;
    visibility: visible !important;
    width: auto !important;
    display: inline !important;
    flex: 1 !important;
  }
  
  .retro-sidebar.open .menu-icon {
    margin-right: 12px !important;
    display: flex !important;
  }
  
  .retro-sidebar.open .menu-icon svg {
    width: 18px !important;
    height: 18px !important;
  }
  
  .retro-sidebar.open .sidebar-footer {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    padding: 25px 20px !important;
  }
  
  .retro-sidebar.open .sidebar-contact {
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
  }
  
  .retro-sidebar.open .sidebar-link {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    text-align: center !important;
  }
  
  .retro-sidebar.open .sidebar-link span {
    display: inline !important;
  }
  
  .retro-sidebar.open .sidebar-email,
  .retro-sidebar.open .sidebar-github {
    justify-content: center !important;
    align-items: center !important;
  }
  
  /* Show hamburger button always on mobile - override any .visible class sizes */
  .menu-toggle,
  .menu-toggle.visible {
    display: flex !important;
    position: fixed;
    top: 20px !important;
    left: 20px !important;
    width: 40px !important;
    height: 40px !important;
    z-index: 9998; /* Behind sidebar (9999) but above overlay (9998) */
    background: rgba(40, 45, 60, 0.9);
    border: 1px solid rgba(102, 126, 234, 0.35);
    border-radius: 6px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px !important;
    cursor: pointer;
    padding: 8px !important;
    backdrop-filter: blur(12px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.35);
    pointer-events: auto !important;
    visibility: visible !important;
  }
  
  /* Lower hamburger button on home page to avoid viewport toolbar overlap */
  #hero .menu-toggle,
  #hero ~ * .menu-toggle,
  body:has(#hero) .menu-toggle,
  body:has(.hero-section) .menu-toggle {
    top: 60px !important; /* Below viewport toolbar (38px height + padding) */
  }
  
  /* Override portfolio-specific positioning on mobile */
  #wrapper.portfolio .menu-toggle,
  #wrapper.portfolio .menu-toggle.visible,
  #wrapper.inner .menu-toggle,
  #wrapper.inner .menu-toggle.visible {
    top: 20px !important;
    width: 40px !important;
    height: 40px !important;
  }
  
  /* Hide hamburger button when sidebar is open on mobile */
  .retro-sidebar.open ~ * .menu-toggle,
  body:has(.retro-sidebar.open) .menu-toggle {
    z-index: 9997 !important; /* Behind sidebar when open */
  }
  
  .menu-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    background: rgba(200, 205, 220, 0.9);
    border-radius: 2px;
    transition: all 0.2s ease;
  }
  
  .menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(7px, 7px);
  }
  
  .menu-toggle.active span:nth-child(2) {
    opacity: 0;
  }
  
  .menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
  }
  
  /* Remove wrapper margin on mobile when sidebar is hidden */
  #wrapper {
    margin-left: 0 !important;
    width: 100% !important;
  }
  
  /* Adjust wrapper when sidebar is open on mobile */
  body:has(.retro-sidebar.open) #wrapper,
  .retro-sidebar.open ~ * #wrapper {
    margin-left: 0 !important;
    width: 100% !important;
  }
  
  /* Show sidebar overlay on mobile when sidebar is open */
  .sidebar-overlay {
    display: block !important;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
  }
  
  .sidebar-overlay.active {
    opacity: 1;
    visibility: visible;
  }
  
  /* Hide particles on mobile for better performance */
  .particles,
  .particle,
  .particle-glow,
  .particle-trail {
    display: none !important;
  }
  
  /* Hide Play/Pause/Step buttons on mobile */
  .toolbar-center {
    display: none !important;
  }
  
  /* Hide Gizmo toggles (2D/3D) on mobile */
  .toolbar-right {
    display: none !important;
  }
  
  /* Hide FPS stats on mobile */
  .viewport-stats {
    display: none !important;
  }
  
  /* Hide scene info (Portfolio_HomeScene) on mobile */
  .viewport-scene-info {
    display: none !important;
  }
  
  /* Professional Experience section mobile styles */
  .career-section {
    padding: 40px 20px !important;
  }
  
  .career-header {
    margin-bottom: 40px;
  }
  
  .section-title {
    font-size: 32px !important;
    margin-bottom: 30px !important;
    white-space: normal !important; /* Allow wrapping on mobile to prevent cut-off */
  }
  
  .career-timeline {
    padding-left: 40px !important;
  }
  
  .career-marker {
    left: -33px !important;
    width: 14px !important;
    height: 14px !important;
  }
  
  .timeline-line {
    left: 13px !important;
    width: 2px;
  }
  
  .career-content {
    padding: 20px !important;
    flex-direction: column;
    gap: 15px;
  }
  
  .career-company-icon {
    width: 56px !important;
    height: 56px !important;
    min-width: 56px !important;
    margin-top: 0 !important;
  }
  
  .career-item {
    margin-bottom: 35px;
  }
  
  /* Portfolio filter buttons mobile positioning */
  .arcade-filters {
    flex-direction: column;
    gap: 10px;
    align-items: stretch;
  }
  
  .filter-btn {
    width: 100%;
    padding: 12px 20px !important;
    font-size: 12px !important;
  }
  
  /* Fix Fancybox popup positioning on mobile - center since sidebar is hidden */
  .fancybox-wrap {
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
  }
  
  .popup_portfolio {
    max-width: calc(100vw - 40px) !important;
  }
  
  /* Contact page - reduce gap between buttons on mobile */
  .contact-content {
    flex-direction: column;
    gap: 30px !important;
  }
  
  .contact-card-link {
    width: 100%;
    max-width: 100%;
  }
}

@media (max-width: 480px) {
  /* Hide particles on very small screens for performance */
  .particles,
  .particle,
  .particle-glow,
  .particle-trail {
    display: none !important;
  }
  
  /* Simplify card hover effects */
  .arcade-card:hover .arcade-card-inner {
    transform: none !important;
  }
  
  .hero-title {
    font-size: 28px !important;
    letter-spacing: 1px !important;
  }
  
  .hero-subtitle {
    font-size: 18px !important;
  }
  
  .hero-description {
    font-size: 14px !important;
  }
  
  .hero-stats {
    flex-direction: column !important;
    align-items: center !important;
    gap: 8px !important;
  }
  
  .stat-item {
    width: 85% !important;
    max-width: 200px !important;
    min-width: unset !important;
    padding: 10px 15px !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 8px !important;
    text-align: center !important;
  }
  
  .stat-number {
    font-size: 20px !important;
    margin-bottom: 0 !important;
  }
  
  .stat-label {
    font-size: 11px !important;
    text-align: center !important;
  }
  
  .section-title {
    font-size: 24px !important;
  }
  
  .career-content {
    padding: 15px !important;
  }
  
  .btn-primary, .btn-secondary {
    padding: 12px 25px !important;
    font-size: 12px !important;
  }
  
  /* Keep sidebar header text consistent - prevent scaling */
  .sidebar-logo {
    font-size: 24px !important;
  }
  
  .sidebar-slogan {
    font-size: 13px !important;
  }
  
  .retro-menu-item {
    padding: 12px 20px !important;
    font-size: 14px !important;
  }
}

/* Touch-friendly improvements */
@media (hover: none) and (pointer: coarse) {
  .btn-primary, .btn-secondary {
    min-height: 44px;
    min-width: 44px;
  }
  
  .retro-menu-item {
    min-height: 44px;
    padding: 14px 30px;
  }
  
  .filter-btn {
    min-height: 44px;
    padding: 14px 25px;
  }
  
  /* Remove hover effects on touch devices */
  .arcade-card:hover {
    transform: none;
  }
  
  .stat-item:hover {
    transform: none;
  }
}

/* Lock hero elements in place for short viewports (below 780px height) */
@media (max-height: 890px) {
  .hero-section {
    display: block !important;
    position: relative !important;
    height: auto !important;
    min-height: 890px !important; /* Fixed minimum to prevent collapse */
    overflow: visible !important;
    padding-top: 150px !important; /* Always preserve 180px space from top */
    box-sizing: border-box !important;
  }
  
  .hero-content {
    position: relative !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    padding-top: 0 !important;
    margin: 0 auto !important;
    height: auto !important;
  }
  
  .hero-text {
    position: relative !important;
  }
  
  .hero-title {
    position: relative !important;
  }
  
  .hero-stats {
    position: relative !important;
  }
  
  .hero-buttons {
    position: relative !important;
    margin-bottom: 120px !important; /* Space for scroll indicator and axis */
  }
  
  .scroll-indicator {
    position: absolute !important;
    bottom: 30px !important;
  }
  
  .coordinate-axis {
    position: absolute !important;
    bottom: 25px !important;
    right: 20px !important;
  }
}

/* Final override: Bottom gap for portfolio page - must be at end of file */
.arcade-grid#container {
  margin-bottom: 15px !important;
}

.arcade-grid#container::after {
  content: '' !important;
  display: block !important;
  height: 15px !important;
  grid-column: 1 / -1 !important;
}
