@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500;700&display=swap');

body {
  background-color: #F7F7F5;
  color: #1c1c1e;
  font-family: 'Inter', sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

.font-mono {
  font-family: 'JetBrains Mono', monospace;
}

.glass-panel {
  background-color: rgba(255, 255, 255, 0.45);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(255, 255, 255, 0.6);
  box-shadow: 0 4px 24px -4px rgba(0, 0, 0, 0.05), 0 2px 8px -2px rgba(0, 0, 0, 0.03);
}

.glass-panel-opaque {
  background-color: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(32px);
  -webkit-backdrop-filter: blur(32px);
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 8px 32px -4px rgba(0, 0, 0, 0.06), 0 4px 12px -2px rgba(0, 0, 0, 0.04);
}

.tilt-card {
  transform-style: preserve-3d;
}

details > summary {
  list-style: none;
}
details > summary::-webkit-details-marker {
  display: none;
}

/* Navbar shrink fix */
#navbar-inner {
  white-space: nowrap;
  transition: max-width 0.3s ease, padding 0.3s ease, background-color 0.3s ease !important;
}

#navbar-inner ul {
  transition: gap 0.3s ease !important;
}
#navbar-inner .text-xl {
  transition: font-size 0.3s ease !important;
}
#navbar-inner .bg-crimson {
  transition: padding 0.3s ease, font-size 0.3s ease !important;
}

#navbar-inner.nav-scrolled {
  max-width: 800px;
  padding-top: 0.5rem !important;
  padding-bottom: 0.5rem !important;
  background-color: rgba(255, 255, 255, 0.85) !important;
}
#navbar-inner.nav-scrolled ul {
  gap: 1.5rem !important;
}
#navbar-inner.nav-scrolled .text-xl {
  font-size: 1.125rem !important;
}
#navbar-inner.nav-scrolled .bg-crimson {
  padding-top: 0.5rem !important;
  padding-bottom: 0.5rem !important;
  padding-left: 1rem !important;
  padding-right: 1rem !important;
  font-size: 0.8rem !important;
}


/* Certifications Marquee */
.marquee-wrapper {
  overflow: hidden;
  position: relative;
  width: 100%;
}

.marquee-container {
  display: flex;
  width: max-content;
  animation: marquee-scroll 40s linear infinite;
}

.marquee-wrapper:hover .marquee-container {
  animation-play-state: paused;
}

@keyframes marquee-scroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}


/* Mobile nav safeguards */
@media (max-width: 1279px) {
  #navbar-inner ul {
    display: none !important;
  }
  
}
@media (min-width: 1280px) {
  
}






/* Marquee Edge Fade to prevent hard cutoff */
.marquee-wrapper {
  -webkit-mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
  mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
}


/* MOBILE RESPONSIVENESS OVERRIDES */
/* Scoped exactly to real phone widths (<= 639px) */
@media (max-width: 639px) {
  /* 1. Global Overflow Safety Net */
  html, body {
    overflow-x: hidden !important;
    width: 100vw !important;
    max-width: 100vw !important;
  }
  
  main {
    overflow-x: hidden !important;
    width: 100% !important;
    max-width: 100vw !important;
  }

  /* 2. Marquee Flexbox Constraint */
  /* Forces the wrapper to shrink instead of stretching the flex column */
  .marquee-wrapper {
    min-width: 0 !important;
    max-width: 100vw !important;
  }

  /* 3. Card Padding Overrides */
  /* Prevent massive paddings from pushing inner content off-screen */
  .glass-panel.p-16,
  .glass-panel.p-12,
  .glass-panel.p-10,
  .glass-panel.p-8 {
    padding: 1.5rem !important;
  }
  .px-12 {
    padding-left: 1.5rem !important;
    padding-right: 1.5rem !important;
  }

  /* Prevent massive grid gaps from causing horizontal overflow */
  .gap-16, .gap-12 {
    gap: 2rem !important;
  }

  /* 4. Font Sizing Scaling */
  /* Scale down desktop-sized fonts for mobile screens */
  .text-6xl {
    font-size: 2.25rem !important;
    line-height: 2.5rem !important;
  }
  .text-5xl {
    font-size: 1.875rem !important;
    line-height: 2.25rem !important;
  }
  .text-4xl {
    font-size: 1.5rem !important;
    line-height: 2rem !important;
  }
  .text-xl {
    font-size: 1.125rem !important;
    line-height: 1.75rem !important;
  }

  /* 5. Center/Constrain Overly Wide Buttons */
  a.bg-crimson.px-10,
  a.bg-crimson.px-8 {
    display: flex !important;
    width: 100% !important;
    justify-content: center !important;
    text-align: center !important;
    box-sizing: border-box !important;
  }

  /* 6. Enforce strict border-box and width constraints on sections */
  section {
    width: 100% !important;
    max-width: 100vw !important;
    box-sizing: border-box !important;
  }
}


/* Nav Logo */
.nav-logo-link {
  display: flex;
  align-items: center;
  text-decoration: none;
}
.nav-logo-img {
  height: 32px;
  width: auto;
  object-fit: contain;
  display: block;
}

@media (min-width: 481px) {
  .nav-logo-img {
    height: 52px;
    margin-top: -6px;
    margin-bottom: -6px;
    margin-right: -20px;
  }
}



/* Hamburger Spans Cleanup */

.hamburger {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  width: 28px;
  height: 22px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  z-index: 1001;
}
.hamburger .line {
  display: block;
  width: 100%;
  height: 2px;
  background-color: currentColor;
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}
.hamburger.is-open .line1 {
  transform: translateY(8px) rotate(45deg);
}
.hamburger.is-open .line2 {
  opacity: 0;
}
.hamburger.is-open .line3 {
  transform: translateY(-8px) rotate(-45deg);
}
/* Ensure it is hidden on desktop to match previous xl:hidden behavior */
@media (min-width: 1280px) {
  .hamburger { display: none !important; }
}
