/* Import fonts from Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Quokka:wght@300;400;500;600;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Skia:wght@400;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Tahoma:wght@400;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Cambria:wght@400;700&display=swap');
  
  /* Basic Reset */
  * {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
  }
  
  /* Global Styles */
.home, body {
  line-height: 1.6;
  text-align: center;
  background-image: url('assets/b1.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-attachment: fixed;
  color: #333333;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 80px;
}

/* Home page overrides: no scroll, stage for floating thumbs */
.home {
  overflow: hidden;
  padding-top: 0;
  position: relative;
}

.home #home-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none; /* clicks pass through */
}

.home .container {
  position: relative;
  z-index: 1; /* content above floating thumbs */
}

/* Floating background thumbnails */
.bg-thumb {
  position: absolute;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  border-radius: 10px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.20);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.94) rotate(var(--rot, 0deg));
  animation: bgEnter 900ms ease forwards;
  mix-blend-mode: normal; /* allow overlays but keep colors readable */
  pointer-events: none;
}

@keyframes bgEnter {
  from { opacity: 0; transform: translate(-50%, -50%) scale(0.94) rotate(var(--rot, 0deg)); }
  to   { opacity: 1; transform: translate(-50%, -50%) scale(1) rotate(var(--rot, 0deg)); }
}
  
  /* Container for the content on all pages */
  .container {
    padding: 20px;
    width: 100%;
    max-width: 1200px;
  }
  
  
  /* Landing Page Specific Styles */
  h1 {
    font-family: 'Skia', sans-serif;
    font-weight: 700;
    font-size: 4.8rem;
    margin-bottom: 20px;
  }

  /* Home page headline shadow for readability over thumbnails */
  .home h1 {
    text-shadow: 2px 2px 12px rgba(0, 0, 0, 0.55);
  }

  /* Make only the name white on the home headline */
  .home h1 .name-white {
    color: #ffffff;
  }

  /* Second type of title - h2 elements */
  h2 {
    font-family: 'Tahoma', sans-serif;
    font-weight: 700;
  }

  /* Subsection titles - h3 elements (used for section headers) */
  h3 {
    font-family: 'Skia', sans-serif;
    font-weight: 700;
    font-size: 1.75rem;
    margin-bottom: 15px;
    color: #333;
    text-align: left;
  }

  /* Description text - p elements */
  p {
    font-family: 'Cambria', serif;
  }

  /* Work Page Title Styles */
  .work-title {
    font-family: 'Skia', sans-serif;
    font-weight: 700;
    font-size: 3rem;
    margin-bottom: 30px;
    color: #333;
    text-align: center;
  }

  /* Prominent tagline under Work title */
  .tagline-highlight {
    display: inline-block;
    margin: 0 auto 18px;
    padding: 10px 16px;
    border-radius: 9999px;
    background: linear-gradient(90deg, rgba(255,246,173,0.85), rgba(255,210,224,0.85));
    box-shadow: 0 6px 20px rgba(0,0,0,0.08);
    color: #222;
    font-family: 'Tahoma', sans-serif;
    font-weight: 700;
    font-size: 1.05rem;
    text-align: center;
  }

  .tagline-highlight span {
    display: inline-block;
    transition: color 0.3s ease, transform 0.3s ease, letter-spacing 0.3s ease;
    transform-origin: center;
  }

  .tagline-highlight span:hover {
    color: #ff7a1f;
    letter-spacing: 0.04em;
    transform: scale(1.08);
  }

  .work-page-container .tagline-highlight { align-self: center; }

  /* Work Page Layout */
  .work-page-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
  }

  /* Section Headers for Work Pages */
  .section-header {
    font-family: 'Tahoma', sans-serif;
    font-size: 2.5rem;
    margin-bottom: 30px;
    font-weight: 700;
    color: #333;
    text-align: center;
  }

  /* Typewriter Effect */
  .typewriter {
    overflow: hidden;
    border-right: 0.15em solid #333;
    white-space: nowrap;
    margin: 0 auto;
    letter-spacing: 0.15em;
    animation: typing 5s steps(40, end) infinite, blink-caret 0.75s step-end infinite;
  }

  @keyframes typing {
    0% { width: 0 }
    100% { width: 100% }
  }

  @keyframes blink-caret {
    from, to { border-color: transparent }
    50% { border-color: #333; }
  }
  
  .buttons a {
    text-decoration: none;
    margin: 0 10px;
  }
  
  .buttons button {
    padding: 20px 40px;
    font-size: 1.5rem;
    font-family: 'Tahoma', bold;
    font-weight: 500;
    border: none;
    background-color: rgba(111, 109, 109, 0.45);
    color: #ffffff;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease, color 0.3s ease, letter-spacing 0.3s ease;
    border-radius: 8px;
  }
  
  .buttons button:hover {
    background-color: rgba(51, 51, 51, 0.9);
    color: #ff7a1f;
    letter-spacing: 0.08em;
    font-weight: 700;
    transform: translateY(-2px);
  }
  

  .work-sections {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem;
    margin: 0 auto;
    padding: 0;
    width: 100%;
    max-width: 890px;
  }

  .work-column {
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    aspect-ratio: 1.4;
    border-radius: 14px;
    min-height: 0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.35s ease, box-shadow 0.35s ease;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    color: #fff;
  }

  .work-column::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(170deg, rgba(0, 0, 0, 0.62), rgba(0, 0, 0, 0.42));
    z-index: 0;
    pointer-events: none;
    opacity: 0.82;
    transition: opacity 0.35s ease;
  }

  .work-column:hover {
    transform: translateY(-5px);
    box-shadow: 0 14px 32px rgba(0, 0, 0, 0.25);
  }

  .work-column:hover::before {
    opacity: 0.18;
  }

  .rounded-container {
    position: relative;
    z-index: 1;
    flex: 1;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 0.6rem;
    text-align: center;
    background: rgba(0, 0, 0, 0.28);
    border-radius: inherit;
    padding: 32px 26px;
    backdrop-filter: blur(1.2px);
    transition: background 0.35s ease, backdrop-filter 0.35s ease;
  }

  .work-column:hover .rounded-container {
    background: rgba(0, 0, 0, 0.18);
    backdrop-filter: blur(0.4px);
  }

  .rounded-container h2 {
    margin-bottom: 10px;
    text-shadow: 0 6px 20px rgba(0, 0, 0, 0.55);
  }

  .rounded-container h2 a {
    color: inherit;
    text-decoration: none;
    font-size: 1.5rem;
    font-weight: bold;
    transition: color 0.3s ease;
    text-shadow: inherit;
  }

  .rounded-container h2 a:hover {
    color: #ff7a1f;
  }

  .rounded-container p {
    text-shadow: 0 6px 18px rgba(0, 0, 0, 0.6);
  }

  /* Intro container styles */
  .intro-container {
    background: rgba(255, 255, 255, 0.517);
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    margin: 20px 0;
    text-align: left;
    max-width: 890px;
    margin-left: auto;
    margin-right: auto;
  }

  .intro-container p {
    margin-bottom: 15px;
    line-height: 1.6;
  }

  .intro-container p:last-child {
    margin-bottom: 0;
  }

  /* Project sections styling */
  .project-sections {
    margin-top: 60px;
  }

  .project-section {
    background: rgba(243, 239, 239, 0.9);
    border-radius: 12px;
    padding: 40px;
    margin-bottom: 40px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    scroll-margin-top: 100px; /* For smooth scrolling with fixed header */
    text-align: left;
  }

  .project-section h2 {
    font-family: 'Skia', sans-serif;
    font-weight: 700;
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: #333;
    border-bottom: 2px solid #333;
    padding-bottom: 10px;
  }

  .project-content {
    line-height: 1.6;
    text-align: left;
  }

  .project-content p {
    font-size: 1.1rem;
    margin-bottom: 20px;
    color: #444;
  }

  .project-intro {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    align-items: flex-start;
    margin-bottom: 24px;
  }

  .project-description {
    flex: 1 1 320px;
  }

  .project-skills {
    flex: 0 0 240px;
    background: #f3f3f3;
    border-radius: 12px;
    padding: 18px 20px;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
  }

  .project-skills h4 {
    font-size: 1rem;
    margin: 0 0 12px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #222;
  }

  .project-skills ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 8px;
  }

  .project-skills li {
    font-size: 0.95rem;
    color: #333;
  }

  @media (max-width: 768px) {
    .project-intro {
      flex-direction: column;
    }

    .project-skills {
      width: 100%;
      flex: 1 1 100%;
    }
  }

  .project-details {
    background: #ffffff;
    border-radius: 8px;
    padding: 20px;
    margin-top: 20px;
  }

  /* Inline image gallery before project info */
  .project-gallery {
    position: relative;
    margin: 16px 0 10px;
  }

  .gallery-track {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    padding-bottom: 6px; /* space for hidden scrollbar */
    -ms-overflow-style: none; /* IE/Edge */
    scrollbar-width: none; /* Firefox */
  }

  .gallery-track::-webkit-scrollbar { /* Chrome/Safari */
    display: none;
  }

  .gallery-track img,
  .gallery-image {
    flex: 0 0 auto;
    height: 320px;
    width: auto;
    border-radius: 8px;
    object-fit: cover;
    scroll-snap-align: start;
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
    cursor: pointer;
  }

  .gallery-image:focus {
    outline: 3px solid rgba(255,122,31,0.65);
    outline-offset: 4px;
  }

  .project-gallery .gallery-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    border: none;
    background: rgba(255,255,255,0.85);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    cursor: pointer;
    color: #333;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
    transition: background 0.2s ease, transform 0.2s ease;
    z-index: 2;
  }

  .project-gallery .gallery-arrow:hover {
    background: rgba(255,255,255,1);
    transform: translateY(-50%) scale(1.06);
  }

  .project-gallery .gallery-arrow.left { left: 8px; }
  .project-gallery .gallery-arrow.right { right: 8px; }

  /* Lightbox overlay for gallery images */
  .lightbox-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.78);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3000;
    opacity: 0;
    transition: opacity 0.25s ease;
    backdrop-filter: blur(3px);
  }

  .lightbox-overlay.open {
    opacity: 1;
  }

  .lightbox-overlay.closing {
    opacity: 0;
  }

  .lightbox-frame {
    position: relative;
    max-width: min(90vw, 1200px);
    max-height: min(90vh, 900px);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
  }

  .lightbox-media {
    width: auto;
    max-width: min(90vw, 1200px);
    max-height: 90vh;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 18px 50px rgba(0,0,0,0.45);
    background: rgba(10, 10, 10, 0.92);
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .lightbox-image {
    display: block;
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: calc(90vh - 48px);
    border-radius: 12px;
    object-fit: contain;
  }

  .lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: none;
    display: grid;
    place-items: center;
    background: rgba(10, 10, 10, 0.55);
    color: #fff;
    font-size: 1.8rem;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
    box-shadow: 0 6px 18px rgba(0,0,0,0.35);
    z-index: 5;
    backdrop-filter: blur(2px);
  }

  .lightbox-nav.prev { left: 16px; }
  .lightbox-nav.next { right: 16px; }

  .lightbox-nav:hover,
  .lightbox-nav:focus {
    background: rgba(10, 10, 10, 0.75);
    transform: translateY(-50%) scale(1.08);
    outline: none;
  }

  .lightbox-nav:disabled {
    opacity: 0.35;
    cursor: default;
    transform: translateY(-50%);
  }

  @media (max-width: 600px) {
    .lightbox-nav {
      width: 36px;
      height: 36px;
      font-size: 1.4rem;
    }

    .lightbox-nav.prev { left: 12px; }
    .lightbox-nav.next { right: 12px; }
  }

  .lightbox-hint {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.75);
    font-family: 'Lucida Sans', 'Lucida Grande', sans-serif;
    text-align: center;
  }

  .lightbox-close {
    position: absolute;
    top: -16px;
    right: -16px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.85);
    color: #222;
    font-size: 1.5rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(0,0,0,0.2);
    transition: transform 0.2s ease, background 0.2s ease;
  }

  .lightbox-close:hover,
  .lightbox-close:focus {
    background: rgba(255, 255, 255, 1);
    transform: scale(1.08);
    outline: none;
  }

  .project-details h3 {
    font-family: 'Tahoma', sans-serif;
    font-weight: 700;
    font-size: 1.3rem;
    margin-bottom: 15px;
    color: #5a5a5a;
  }

  .project-details ul {
    list-style: none;
    padding: 0;
  }

  .project-details li {
    padding: 8px 0 8px 1.25rem; /* add left padding before each item */
    border-bottom: 1px solid #eee;
    color: #555;
    position: relative;
  }

  .project-details li:last-child {
    border-bottom: none;
  }

  .project-details li:before {
    content: "•";
    color: #333;
    font-weight: bold;
    position: absolute;
    left: 0;
  }

  /* Resume container styles */
  .resume-container {
    margin-top: 40px;
    max-width: 1000px;
    margin-left: auto;
    margin-right: auto;
  }

  .resume-container h2 {
    font-size: 2rem;
    margin-bottom: 20px;
  }


  /* Resume Text Content Styles */
  .resume-content {
    background: white;
    opacity: 0.8;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    text-align: left;
    line-height: 1.6;
  }

  .resume-header {
    margin-bottom: 30px;
    border-bottom: 2px solid #333;
    padding-bottom: 20px;
  }

  .resume-header h3 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    color: #333;
    font-weight: bold;
  }

  .contact-info {
    font-size: 1rem;
    color: #666;
    line-height: 1.4;
    word-wrap: break-word;
  }

  .resume-section {
    margin-bottom: 30px;
  }

  .resume-section h4 {
    font-size: 1.4rem;
    font-weight: bold;
    color: #333;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-bottom: 1px solid #ddd;
    padding-bottom: 5px;
  }

  .resume-section p {
    font-size: 1rem;
    margin-bottom: 15px;
    color: #444;
  }

  .education-item, .experience-item {
    margin-bottom: 25px;
  }

  .education-item h5, .experience-item h5 {
    font-size: 1.2rem;
    font-weight: bold;
    color: #333;
    margin-bottom: 5px;
  }

  .degree, .position {
    font-size: 1.1rem;
    font-weight: 600;
    color: #555;
    margin-bottom: 5px;
  }

  .date, .location-date {
    font-size: 0.9rem;
    color: #777;
    font-style: italic;
    margin-bottom: 10px;
  }

  .resume-section ul {
    margin-left: 20px;
    margin-bottom: 15px;
  }

  .resume-section li {
    font-size: 0.95rem;
    color: #444;
    margin-bottom: 5px;
    line-height: 1.5;
  }

  .skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
  }

  .skill-category {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 6px;
    border-left: 4px solid #333;
  }

  .skill-category h5 {
    font-size: 1rem;
    font-weight: bold;
    color: #333;
    margin-bottom: 8px;
  }

  .skill-category p {
    font-size: 0.9rem;
    color: #555;
    margin-bottom: 0;
  }

  /* Responsive adjustments for resume */
  @media (max-width: 768px) {
    .resume-content {
      padding: 20px;
    }
    
    .resume-header h3 {
      font-size: 2rem;
    }
    
    .contact-info {
      font-size: 0.9rem;
    }
    
    .skills-grid {
      grid-template-columns: 1fr;
    }
    
    .resume-section h4 {
      font-size: 1.2rem;
    }
  }


  /* Projects Grid Styles */
  .projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    /* Match inner content width with .project-section padding (40px) */
    padding: 20px 40px;
  }

  .project-card {
    background: white;
    border-radius: 10px;
    padding: 10px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
    aspect-ratio: 1.4;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-decoration: none;
    color: inherit;
    position: relative;
    overflow: hidden;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
  }

  /* Thumbnail overlay for better text readability */
  .project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(200, 200, 200, 0.4);
    z-index: 1;
    transition: background 0.3s ease;
  }

  .project-card:hover::before {
    background: rgba(0, 0, 0, 0.2);
  }

  /* Ensure text stays above overlay */
  .project-card h2,
  .project-card p {
    position: relative;
    z-index: 2;
    color: white;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
  }

  .project-card:hover h2,
  .project-card:hover p {
    color: #d7eaffd4;
  }

  .project-card:hover {
    transform: translateY(-5px);
  }

  /* Pop-in animation for index thumbnails */
  .project-card.pop-in {
    opacity: 0;
    transform: scale(0.96);
    animation: popIn 520ms ease forwards;
  }

  @keyframes popIn {
    from { opacity: 0; transform: scale(0.96); }
    to { opacity: 1; transform: scale(1); }
  }

  /* Staggered appearance for index grid */
  .index-grid .project-card:nth-child(1)  { animation-delay: 0.00s; }
  .index-grid .project-card:nth-child(2)  { animation-delay: 0.05s; }
  .index-grid .project-card:nth-child(3)  { animation-delay: 0.10s; }
  .index-grid .project-card:nth-child(4)  { animation-delay: 0.15s; }
  .index-grid .project-card:nth-child(5)  { animation-delay: 0.20s; }
  .index-grid .project-card:nth-child(6)  { animation-delay: 0.25s; }
  .index-grid .project-card:nth-child(7)  { animation-delay: 0.30s; }
  .index-grid .project-card:nth-child(8)  { animation-delay: 0.35s; }
  .index-grid .project-card:nth-child(9)  { animation-delay: 0.40s; }
  .index-grid .project-card:nth-child(10) { animation-delay: 0.45s; }
  .index-grid .project-card:nth-child(11) { animation-delay: 0.50s; }
  .index-grid .project-card:nth-child(12) { animation-delay: 0.55s; }
  .index-grid .project-card:nth-child(13) { animation-delay: 0.60s; }
  .index-grid .project-card:nth-child(14) { animation-delay: 0.65s; }
  .index-grid .project-card:nth-child(15) { animation-delay: 0.70s; }
  .index-grid .project-card:nth-child(16) { animation-delay: 0.75s; }
  .index-grid .project-card:nth-child(17) { animation-delay: 0.80s; }
  .index-grid .project-card:nth-child(18) { animation-delay: 0.85s; }
  .index-grid .project-card:nth-child(19) { animation-delay: 0.90s; }
  .index-grid .project-card:nth-child(20) { animation-delay: 0.95s; }
  .index-grid .project-card:nth-child(21) { animation-delay: 1.00s; }

  .project-card h2 {
    margin-bottom: 15px;
    text-align: center;
  }

  .project-card p {
    text-align: center;
  }



.floating-header {
  position: fixed;
  top: 25px;
  left: 50%;
  transform: translateX(-50%);
  width: 90vw;
  max-width: 700px;
  background: #ffffff83;
  border-radius: 1.5rem;
  box-shadow: 0 4px 24px rgba(0,0,0,0.10);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.8rem 2rem;
  z-index: 1000;
}

.header-link {
  font-family: "Quokka", "Loos", Arial, sans-serif;
  font-size: 1rem;
  color: #222;
  text-decoration: none;
  font-weight: bold;
  letter-spacing: 0.05em;
  transition: color 0.2s;
}

.header-link:hover {
  color: #888;
}

.header-link.left {
  text-align: left;
}

.header-link.right {
  text-align: right;
}

/* Fixed Sidebar Navigation */
.sidebar-nav {
  position: fixed;
  top: 100px;
  left: 20px;
  width: 250px;
  height: calc(100vh - 120px);
  background: rgba(255, 255, 255, 0.764);
  border-radius: 1rem;
  box-shadow: 0 4px 24px rgba(0,0,0,0.10);
  backdrop-filter: blur(10px);
  z-index: 999;
  overflow-y: auto;
  padding: 1.5rem 0;
  scrollbar-width: thin;
  scrollbar-color: rgba(51, 51, 51, 0.25) transparent;
}

/* Round sidebar scrollbar to respect container radius */
.sidebar-nav::-webkit-scrollbar {
  width: 10px;
}

.sidebar-nav::-webkit-scrollbar-track {
  background: transparent;
  margin: 12px 0;
  border-radius: 1rem;
}

.sidebar-nav::-webkit-scrollbar-thumb {
  background-color: rgba(51, 51, 51, 0.25);
  border-radius: 999px;
  border: 3px solid rgba(255, 255, 255, 0.6);
}

.sidebar-content h3 {
  font-family: "Quokka", "Loos", Arial, sans-serif;
  font-size: 1.1rem;
  color: #333;
  margin: 0 0 1rem 1.5rem;
  font-weight: bold;
  letter-spacing: 0.05em;
}

.sidebar-content ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.sidebar-content li {
  margin: 0;
}

.sidebar-content a {
  display: block;
  padding: 0.6rem 1.5rem;
  font-family: "Quokka", "Loos", Arial, sans-serif;
  font-size: 0.95rem;
  color: #666;
  text-decoration: none;
  transition: all 0.2s ease;
  border-left: 3px solid transparent;
}

/* Main category links - left justified */
.sidebar-content .main-category {
  font-weight: bold;
  color: #333;
  border-left: 3px solid #333;
  cursor: pointer;
  position: relative;
}

/* Expandable indicator */
.sidebar-content .main-category::after {
  content: '+';
  position: absolute;
  right: 1rem;
  font-size: 1.2rem;
  transition: transform 0.3s ease;
}

.sidebar-content .main-category.expanded::after {
  content: '−';
  transform: rotate(0deg);
}

/* Project group container */
.sidebar-content .project-group {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.sidebar-content .project-group.expanded {
  max-height: 1000px; /* Adjust based on content */
}

/* Individual project links - right justified */
.sidebar-content .project-link {
  padding-left: 2.5rem;
  font-size: 0.85rem;
  color: #888;
  text-align: right;
  padding-right: 1rem;
  display: block;
}

.sidebar-content a:hover {
  color: #333;
  background: rgba(0, 0, 0, 0.05);
  border-left-color: #333;
}

.sidebar-content .sub-nav a:hover {
  background: rgba(0, 0, 0, 0.03);
}

/* Layout adjustment for sidebar */
.container.with-sidebar {
  margin-left: 290px;
  max-width: calc(100vw - 330px);
}

/* Smooth scrolling for anchor links */
html {
  scroll-behavior: smooth;
}


/* Mobile responsiveness for sidebar */
@media (max-width: 1024px) {
  .sidebar-nav {
    display: none;
  }
  
  .container.with-sidebar {
    margin-left: 0;
    max-width: none;
  }
}

/* Footer Styles */
footer {
  position: fixed;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 30px;
  z-index: 1000;
}

footer a {
  color: #333333; /* default dark grey for non-home/work pages */
  text-decoration: none;
  transition: color 0.3s ease, transform 0.3s ease;
}

/* Keep hover color same as base; still allow scale */
footer a:hover {
  color: #ff7a1f;
  transform: scale(1.1);
}

.home footer a:hover,
.work-page footer a:hover {
  color: #2200ff;
}

footer i {
  font-size: 2rem;
}


.project-page footer {
  position: fixed;
  top: 28px;
  left: 45px;
  bottom: auto;
  transform: none;
  flex-direction: row;
  align-items: center;
  gap: 18px;
  background: transparent;
  box-shadow: none;
}

.project-page footer a {
  color: #333333;
}

.project-page footer a:hover {
  color: #ff7a1f;
}

.project-page footer i {
  font-size: 2.2rem;
}

/* Index (home) page: larger social icons fixed at bottom with slide-in */
.home footer {
  position: fixed;
  left: 50%;
  bottom: 15%;
  transform: translate(-50%, 40px);
  background: transparent;
  box-shadow: none;
  z-index: 1100;
  opacity: 0;
  animation: footerSlideUp 700ms ease 700ms forwards;
}

@keyframes footerSlideUp {
  from { opacity: 0.2; transform: translate(-50%, 40px); }
  to   { opacity: 1; transform: translate(-50%, 0); }
}

.home footer a { margin: 0 14px; }
.home footer i { font-size: 3rem; }

/* About page: stick footer icons vertically on right side */
.about-page footer {
  position: fixed;
  right: 24px;
  top: 50%;
  bottom: auto;
  left: auto;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  background: transparent;
  box-shadow: none;
  z-index: 1100;
}

.about-page footer a { margin: 0; }

/* White footer icons on home and work pages only */
.home footer a,
.work-page footer a {
  color: #e2e2e2;
}
.about-page .resume-container {
  display: grid;
  grid-template-columns: 1fr auto;
  column-gap: 24px;
  align-items: start;
}

.about-page .vertical-name-fixed {
  position: sticky;
  top: 120px; /* sticks as page scrolls */
  writing-mode: vertical-rl;
  text-orientation: mixed;
  font-family: 'Skia', sans-serif;
  font-weight: 700;
  font-size: 2rem;
  letter-spacing: 0.09em;
  color: #222;
  text-shadow: 1px 1px 6px rgba(0,0,0,0.25);
  height: max-content;
  align-self: start;
}

/* Hide duplicated horizontal H1 on about page (since name is vertical) */
.about-page .container > h1 {
  display: none;
}

@media (max-width: 768px) {
  .about-page .resume-container {
    grid-template-columns: 1fr auto;
    column-gap: 16px;
  }
  .about-page .vertical-name-fixed {
    top: 96px;
    font-size: 1.25rem;
  }
}

/* Responsive layout refinements */
@media (max-width: 900px) {
  .floating-header {
    width: calc(100% - 48px);
    max-width: none;
  }
}

@media (max-width: 768px) {
  body {
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    padding-top: 100px;
  }

  .container {
    padding: 16px;
  }

  .floating-header {
    top: 12px;
    padding: 0.65rem 1.25rem;
    border-radius: 1rem;
    gap: 12px;
  }

  .header-link {
    font-size: 0.95rem;
  }

  h1 {
    font-size: 2.4rem;
  }

  .home {
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding: 32px 16px 72px;
  }

  .home h1 {
    font-size: 2.8rem;
    margin-bottom: 24px;
  }

  .home h2 {
    font-size: 1.4rem;
  }

  .tagline-highlight {
    padding: 10px 14px;
    font-size: 0.95rem;
    gap: 6px;
    flex-wrap: wrap;
    line-height: 1.5;
  }

  .buttons {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: stretch;
    margin-top: 16px;
  }

  .buttons button {
    width: 100%;
    padding: 14px 18px;
    font-size: 1.05rem;
  }

  .work-title {
    font-size: 2.4rem;
  }

  .intro-container {
    padding: 24px;
    margin: 16px 0;
  }

  .work-sections {
    grid-template-columns: 1fr;
    width: 100%;
    gap: 18px;
  }

  .work-column {
    padding: 0;
    aspect-ratio: 1.4;
    min-height: 0;
  }

  .projects-grid {
    grid-template-columns: 1fr;
    gap: 20px;
    padding: 0;
  }

  .project-card {
    aspect-ratio: 1.4;
    min-height: 220px;
  }

  .project-section {
    padding: 24px 20px;
  }

  .project-content p {
    font-size: 1rem;
  }

  .project-gallery .gallery-track {
    gap: 10px;
  }

  .project-gallery .gallery-track img,
  .project-gallery .gallery-image {
    width: min(100%, 280px);
    height: auto;
    max-height: 220px;
  }

  .project-gallery .gallery-arrow {
    width: 32px;
    height: 32px;
  }

  footer {
    position: static;
    margin: 32px auto 16px;
    transform: none;
    gap: 18px;
  }

  footer i {
    font-size: 1.6rem;
  }

  .project-page footer {
    position: static;
    margin-top: 32px;
  }

  .project-page footer i {
    font-size: 1.8rem;
  }

  .home footer {
    position: static;
    bottom: auto;
    animation: none;
    opacity: 1;
    transform: none;
    margin-top: 32px;
  }

  .home footer i {
    font-size: 2rem;
  }

  .about-page footer {
    flex-direction: row;
    justify-content: center;
    align-items: center;
  }

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

  .about-page .vertical-name-fixed {
    display: none;
  }

  .about-page .container > h1 {
    display: block;
    margin-bottom: 24px;
    text-align: center;
  }
}

@media (max-width: 480px) {
  body {
    padding-top: 88px;
  }

  .floating-header {
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
    text-align: center;
  }

  .header-link {
    width: 100%;
    font-size: 0.9rem;
  }

  h1 {
    font-size: 2.1rem;
  }

  .home h1 {
    font-size: 2.4rem;
  }

  .home h2 {
    font-size: 1.2rem;
  }

  .tagline-highlight {
    font-size: 0.9rem;
  }

  .buttons button {
    font-size: 1rem;
    padding: 12px 16px;
  }

  .intro-container {
    padding: 20px;
  }

  .project-section {
    padding: 20px 16px;
  }
}
