/* ===================================
   RESET & BASE STYLES
   =================================== */

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

:root {
    /* Dark & Moody Color Palette */
    --primary-bg: #1a1a1a;
    --secondary-bg: #242424;
    --accent-green: #2d5f3f;
    --accent-gold: #D4AF37;
    --text-primary: #ffffff;
    --text-secondary: #c4c4c4;
    --text-gold: #D4AF37;
    
    /* Typography */
    --font-primary: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --font-secondary: Georgia, 'Times New Roman', serif;
    
    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;
    --spacing-xl: 6rem;
    
    /* Transitions */
    --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-primary);
    color: var(--text-primary);
    background-color: var(--primary-bg);
    line-height: 1.7;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

/* ===================================
   MOUNTAIN BACKGROUND (FIXED ACROSS ALL SECTIONS)
   =================================== */

.hero-background {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url('../images/home/photo5.JPG');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    opacity: 0.25;
    z-index: -2;
}

.hero-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(26, 26, 26, 0.78);
    z-index: -1;
}

/* ===================================
   NAVIGATION
   =================================== */

.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background-color: rgba(26, 26, 26, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    border-bottom: 1px solid rgba(212, 175, 55, 0.2);
    transition: var(--transition-smooth);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1.5rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    text-decoration: none;
    letter-spacing: 0.1em;
    transition: var(--transition-smooth);
}

.logo:hover {
    color: var(--accent-gold);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2.5rem;
    align-items: center;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 400;
    transition: var(--transition-smooth);
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background-color: var(--accent-gold);
    transition: width 0.3s ease;
}

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

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

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001;
}

.hamburger .bar {
    width: 25px;
    height: 2px;
    background-color: var(--text-primary);
    margin: 4px 0;
    transition: var(--transition-smooth);
}

.hamburger.active .bar:nth-child(1) {
    transform: translateY(10px) rotate(45deg);
}

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

.hamburger.active .bar:nth-child(3) {
    transform: translateY(-10px) rotate(-45deg);
}

/* ===================================
   HERO SECTION
   =================================== */

.hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: var(--spacing-xl) var(--spacing-md);
    padding-top: calc(var(--spacing-xl) + 80px);
    position: relative;
}

.hero-container {
    max-width: 1200px;
    width: 100%;
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: var(--spacing-lg);
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-left {
    padding-right: var(--spacing-md);
}

/* Large glossy "Hi!" */
.hero-greeting {
    font-family: "Inter", "Helvetica Neue", Arial, sans-serif;
    font-size: clamp(5rem, 12vw, 9rem);
    font-weight: 800;
    color: #2d5f3f;
    line-height: 1;
    margin-bottom: var(--spacing-sm);
    letter-spacing: -0.5px;
}

/* Rotating text container */
.hero-intro {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-top: var(--spacing-md);
}

.bouncing-icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.bouncing-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.bouncing-icon.bounce {
  animation: realisticBounce 0.9s ease-out;
}

@keyframes realisticBounce {
  0%   { transform: translateY(0) scaleY(1) scaleX(1); }
  15%  { transform: translateY(-25px) scaleY(1.05) scaleX(0.95); } /* first lift */
  30%  { transform: translateY(0) scaleY(0.9) scaleX(1.1); }       /* first impact */
  45%  { transform: translateY(-15px) scaleY(1.03) scaleX(0.97); } /* smaller lift */
  60%  { transform: translateY(0) scaleY(0.94) scaleX(1.06); }     /* second impact */
  75%  { transform: translateY(-7px) scaleY(1.02) scaleX(0.98); }  /* final lift */
  90%  { transform: translateY(0) scaleY(0.97) scaleX(1.03); }     /* settle */
  100% { transform: translateY(0) scaleY(1) scaleX(1); }
}


.rotating-text-container {
    position: relative;
    height: 60px;
    overflow: hidden;
    flex: 1;
}

.rotating-text {
    position: absolute;
    left: 0;
    top: 0;
    font-size: clamp(1.2rem, 2.5vw, 2rem);
    font-weight: 300;
    color: var(--accent-gold);
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
}

.rotating-text.active {
    opacity: 1;
    transform: translateY(0);
}

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

.portrait-circle {
    width: 380px;
    height: 380px;
    border-radius: 50%;
    overflow: hidden;
    position: relative;
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.5),
        0 10px 30px rgba(212, 175, 55, 0.15);
    transition: var(--transition-smooth);
}

.portrait-circle::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 50%;
    box-shadow: inset 0 0 100px 50px rgba(0, 0, 0, 0.6);
    pointer-events: none;
}

.portrait-circle:hover {
    transform: scale(1.02) translateY(-5px);
    box-shadow: 
        0 25px 70px rgba(0, 0, 0, 0.6),
        0 15px 40px rgba(212, 175, 55, 0.2);
}

.portrait-circle img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.scroll-indicator {
    position: absolute;
    bottom: var(--spacing-lg);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    color: var(--accent-gold);
    font-size: 0.9rem;
    animation: bounce 2s infinite;
    z-index: 1;
}

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

/* ===================================
   BIO SECTION (ON SAME DARK BACKGROUND)
   =================================== */

.bio-section {
    padding: var(--spacing-xl) var(--spacing-md);
    background-color: transparent;
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
}

.bio-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-xl);
    align-items: center;
}

.bio-left {
    position: relative;
    height: 820px;
    width: 100%;
    max-width: 400px;
}

.overlapping-photos {
    position: relative;
    width: 100%;
    height: 100%;
}

.photo-square {
    position: absolute;
    width: 340px;
    height: 240px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    left: 0;
    opacity: 0;
    transform: translateX(-150px);
}

.photo-square.visible {
    opacity: 1;
    transform: translateX(0);
}

.photo-square.hidden {
    opacity: 0;
    transform: translateX(-150px);
}

.photo-square:nth-child(1) {
    transition-delay: 0.1s;
}

.photo-square:nth-child(2) {
    transition-delay: 0.25s;
}

.photo-square:nth-child(3) {
    transition-delay: 0.4s;
}

.photo-square img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.photo-square:hover {
    transform: scale(1.05) translateY(-5px);
    box-shadow: 0 25px 60px rgba(212, 175, 55, 0.4);
    z-index: 10 !important;
}

/* VERTICAL SEQUENCE - More separation between photos */
.photo-1 {
    top: 0;
    z-index: 3;
}

.photo-2 {
    top: 290px;
    z-index: 2;
}

.photo-3 {
    top: 580px;
    z-index: 1;
}

.bio-right {
    padding-left: var(--spacing-md);
    opacity: 0;
    transform: translateX(150px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    transition-delay: 0.2s;
}

.bio-right.visible {
    opacity: 1;
    transform: translateX(0);
}

.bio-right.hidden {
    opacity: 0;
    transform: translateX(150px);
}

.bio-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 2.5rem;
    color: var(--accent-gold);
    margin-bottom: var(--spacing-md);
    font-weight: 500;
}

.bio-text {
    max-width: 600px;
}

.bio-opening {
    font-size: 1.25rem;
    margin-bottom: var(--spacing-md);
    color: var(--text-primary);
    line-height: 1.6;
}

.bio-text p {
    font-size: 1.05rem;
    line-height: 1.8;
    color: var(--text-secondary);
    margin-bottom: var(--spacing-md);
}

.bio-text a {
    color: var(--accent-gold);
    text-decoration: none;
    border-bottom: 1px solid var(--accent-gold);
    transition: var(--transition-smooth);
}

.bio-text a:hover {
    color: var(--accent-green);
    border-bottom-color: var(--accent-green);
}

/* ===================================
   HI! GLOSSY TEXT EFFECT
=================================== */

.hi-text {
  position: relative;
  display: inline-block;
  background: linear-gradient(145deg, #2D4A3E, #3C5A4D);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  overflow: hidden;
}

.hi-text::after {
  content: "";
  position: absolute;
  top: 0;
  left: -50%;
  width: 50%;
  height: 100%;
  background: linear-gradient(
    120deg,
    rgba(255, 255, 255, 0.6) 0%,
    rgba(255, 255, 255, 0) 60%
  );
  transform: skewX(-25deg);
  animation: shine 3s infinite;
}

@keyframes shine {
  0% { left: -50%; }
  50% { left: 100%; }
  100% { left: 100%; }
}


/* ===================================
   FOOTER
   =================================== */

.footer {
    background-color: transparent;
    padding: var(--spacing-lg) var(--spacing-md);
    border-top: 1px solid rgba(212, 175, 55, 0.2);
    position: relative;
}

.footer-icons {
    display: flex;
    justify-content: center;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-md);
}

.footer-icons a {
    color: var(--text-secondary);
    transition: var(--transition-smooth);
}

.footer-icons a:hover {
    color: var(--accent-gold);
    transform: translateY(-3px);
}

.footer-icons svg {
    width: 24px;
    height: 24px;
}

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

/* ===================================
   SCROLL-TRIGGERED ANIMATIONS
=================================== */

.hidden {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.visible {
  opacity: 1;
  transform: translateY(0);
}


/* ===================================
   RESPONSIVE DESIGN
   =================================== */

@media (max-width: 1024px) {
    .bio-container {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
    }

    .bio-left {
        height: 760px;
        margin: 0 auto;
        max-width: 380px;
    }

    .photo-square {
        width: 320px;
        height: 220px;
    }

    .photo-1 {
        top: 0;
    }

    .photo-2 {
        top: 270px;
    }

    .photo-3 {
        top: 540px;
    }

    .bio-right {
        padding-left: 0;
        text-align: left;
    }
}

@media (max-width: 968px) {
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: var(--spacing-lg);
    }

    .hero-left {
        padding-right: 0;
    }

    .hero-greeting {
        font-size: 6rem;
    }

    .hero-intro {
        justify-content: center;
    }

    .rotating-text {
        font-size: 1.8rem;
    }

    .portrait-circle {
        width: 320px;
        height: 320px;
    }
}

@media (max-width: 768px) {
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: rgba(26, 26, 26, 0.98);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.5);
        padding: 2rem 0;
        gap: 1.5rem;
        border-top: 1px solid rgba(212, 175, 55, 0.2);
    }

    .nav-menu.active {
        left: 0;
    }

    .hamburger {
        display: flex;
    }

    .portrait-circle {
        width: 280px;
        height: 280px;
    }

    .bio-section {
        padding: var(--spacing-lg) var(--spacing-md);
    }

    .bio-left {
        height: 650px;
        max-width: 320px;
    }

    .photo-square {
        width: 280px;
        height: 200px;
    }

    .photo-1 {
        top: 0;
    }

    .photo-2 {
        top: 250px;
    }

    .photo-3 {
        top: 500px;
    }

    .bio-title {
        font-size: 2rem;
    }

    .bio-text p {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .nav-container {
        padding: 1rem 1.5rem;
    }

    .hero {
        padding: var(--spacing-lg) var(--spacing-sm);
        padding-top: calc(var(--spacing-lg) + 70px);
    }

    .hero-greeting {
        font-size: 4rem;
    }

    .bouncing-icon {
        width: 35px;
        height: 35px;
    }

    .rotating-text {
        font-size: 1.3rem;
    }

    .rotating-text-container {
        height: 50px;
    }

    .portrait-circle {
        width: 240px;
        height: 240px;
    }

    .bio-left {
        height: 580px;
        max-width: 280px;
    }

    .photo-square {
        width: 240px;
        height: 180px;
    }

    .photo-1 {
        top: 0;
    }

    .photo-2 {
        top: 230px;
    }

    .photo-3 {
        top: 460px;
    }

    .bio-opening {
        font-size: 1.1rem;
    }

    .bio-text p {
        font-size: 0.95rem;
    }
}

/* ===================================
     EXPERIENCE & EDUCATION SECTION
     =================================== */

  .experience-education-section {
      padding: var(--spacing-xl) var(--spacing-md);
      padding-top: calc(var(--spacing-xl) + 80px);
      min-height: 100vh;
      background-color: transparent;
      position: relative;
  }

  /* Main Title Animation */
  .section-main-title {
      font-family: 'Playfair Display', Georgia, serif;
      font-size: clamp(2.5rem, 5vw, 4rem);
      color: var(--accent-gold);
      text-align: center;
      margin-bottom: var(--spacing-xl);
      font-weight: 500;
      letter-spacing: -0.5px;
      opacity: 0;
      transform: translateY(40px);
      transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1),
                  transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
  }

  .section-main-title.animate-in {
      opacity: 1;
      transform: translateY(0);
  }

  /* Two Column Layout */
  .two-column-layout {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: var(--spacing-xl);
      max-width: 1400px;
      margin: 0 auto;
      opacity: 0;
      transform: translateY(30px);
      transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1) 0.3s,
                  transform 0.8s cubic-bezier(0.4, 0, 0.2, 1) 0.3s;
  }

  .two-column-layout.animate-in {
      opacity: 1;
      transform: translateY(0);
  }

  .column-left,
  .column-right {
      position: relative;
  }

  .column-title {
      font-family: 'Playfair Display', Georgia, serif;
      font-size: 2rem;
      color: var(--text-primary);
      margin-bottom: var(--spacing-lg);
      font-weight: 500;
  }

  /* Timeline Styles */
  .timeline {
      position: relative;
      padding-left: 2.5rem;
  }

  .timeline::before {
      content: '';
      position: absolute;
      left: 0;
      top: 0;
      bottom: 0;
      width: 2px;
      background: linear-gradient(
          to bottom,
          var(--accent-gold),
          rgba(212, 175, 55, 0.3)
      );
  }

  .timeline-item {
      position: relative;
      margin-bottom: var(--spacing-lg);
      padding-left: 1.5rem;
  }

  .timeline-item::before {
      content: '';
      position: absolute;
      left: -2.5rem;
      top: 0.5rem;
      width: 12px;
      height: 12px;
      border-radius: 50%;
      background-color: var(--accent-gold);
      border: 3px solid var(--primary-bg);
      box-shadow: 0 0 0 2px var(--accent-gold);
  }

  .timeline-date {
      font-size: 0.9rem;
      color: #c8b896;
      margin-bottom: 0.5rem;
      font-weight: 400;
      letter-spacing: 0.5px;
  }

  .timeline-content {
      margin-top: 0.5rem;
  }

  .timeline-position {
      font-size: 1.1rem;
      color: #c8b896;
      font-weight: 400;
      margin-bottom: 0.25rem;
      line-height: 1.4;
  }

  .timeline-company {
      font-size: 1.3rem;
      color: var(--text-primary);
      font-weight: 500;
      margin-bottom: 0.5rem;
      line-height: 1.3;
  }

  .timeline-description {
      font-size: 1rem;
      color: var(--text-secondary);
      line-height: 1.6;
      margin-bottom: 0.5rem;
  }

  .timeline-description:last-child {
      margin-bottom: 0;
  }

  /* Responsive adjustments for Experience & Education */
  @media (max-width: 1024px) {
      .two-column-layout {
          grid-template-columns: 1fr;
          gap: var(--spacing-xl);
      }

      .column-left {
          margin-bottom: var(--spacing-lg);
      }
  }

  @media (max-width: 768px) {
      .experience-education-section {
          padding: var(--spacing-lg) var(--spacing-md);
          padding-top: calc(var(--spacing-lg) + 80px);
      }

      .section-main-title {
          font-size: 2.5rem;
          margin-bottom: var(--spacing-lg);
      }

      .timeline-item {
          padding-left: 1rem;
      }
  }

  @media (max-width: 480px) {
      .two-column-layout {
          grid-template-columns: 1fr;
          gap: var(--spacing-lg);
      }

      .timeline-item {
          padding-left: 2rem;
      }

      .timeline-item::before {
          left: 0;
      }
  }