/* GLOBAL TYPOGRAPHY UPDATE */
body, p, a, input, textarea, label, button, .hello-subline, #success-screen p {
  font-family: 'IBM Plex Sans', sans-serif;
}

/* NAVIGATION MUST STAY POPPINS */
nav a {
  font-family: 'Poppins', sans-serif !important;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Poppins', sans-serif;
}

html, body { height: 100%; margin: 0; padding: 0; }

html {
  scrollbar-gutter: stable; /* FIXES CHROME HORIZONTAL JUMP */
}

body {
  margin: 0;
  overflow-x: hidden;
  overflow-y: scroll;
  background: linear-gradient(180deg, #ffffff 0%, #f9fbff 100%);
  font-family: 'Poppins', sans-serif;
  color: #1a1a1a;
  cursor: none;
  min-height: 100vh;
}



/* NAVIGATION */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 9999; /* nav above canvas */
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding: 2rem 3rem;
  transition: background 0.4s ease, box-shadow 0.4s ease;
  height: 88px;
  box-sizing: border-box;
  gap: 0;
}

.menu-links {
  display: flex;
  flex: 0 0 auto;
  width: max-content;
  gap: 0;
}

nav.scrolled {
  background: rgba(255, 255, 255, 0.97);
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
  backdrop-filter: blur(8px);
}

nav a {
  position: relative;
  color: #1a1a1a;
  text-decoration: none;
  font-size: 0.9rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 500;
  margin: 0 1.25rem;
  line-height: 1.2;
  white-space: nowrap;
}

nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 100%;
  height: 1.5px;
  background-color: #1a1a1a;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s cubic-bezier(0.25,0.9,0.25,1);
}

nav a:hover::after,
nav a.active::after {
  transform: scaleX(1) !important;
  background-color: #3355cc;
}

/* Hamburger for mobile */
.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 26px;
  height: 18px;
  cursor: pointer;
}
.menu-toggle span {
  height: 2px;
  background: #1a1a1a;
  border-radius: 2px;
  width: 100%;
}

@media (max-width: 700px) {
  nav {
    padding: 1.5rem;
    justify-content: flex-end;
  }
  .menu-links {
    display: none;
    flex-direction: column;
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(6px);
    border-radius: 0.8rem;
    padding: 1rem 1.5rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    position: absolute;
    top: 4rem;
    right: 1.5rem;
  }
  .menu-links.open { display: flex; }
  .menu-toggle { display: flex; }
  nav a { margin: 0.6rem 0; }
}

/* LOGO */
.identity {
  position: absolute;
  top: 2rem;
  left: 3rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  z-index: 9999; /* logo above animation */
}

.identity img {
  height: 63px; /* 50% size */
  width: auto;
  object-fit: contain;
}

/* OVERLAY */
.overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  pointer-events: auto;
  z-index: 5000; /* above canvas, below nav */
  transition: transform .4s ease-out;
}

/* HERO TITLE */
.overlay h1 {
  margin: 0;
  color: #1a1a1a;
  font-weight: 400;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  text-align: center;
  white-space: pre-line;
  font-size: clamp(4.2rem, 9vw, 9.5rem);
  line-height: 1.05;
  opacity: 1;
}

/* TAGLINE */
.tagline {
  margin-top: 1.2em;
  font-family: 'Poppins', sans-serif;
  font-size: 0.9rem;
  letter-spacing: 0.126em;
  text-transform: uppercase;
  font-weight: 300;
  color: #1a1a1a;
  text-align: center;
  background: rgba(255, 255, 255, 0.65);
  padding: 0.45em 1.1em;
  border-radius: 1.5em;
  backdrop-filter: blur(6px);
  display: inline-block;
}

/* SCROLL PROMPT TEXT */
.scroll-prompt {
  position: absolute;
  bottom: 4.8rem;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  text-align: center;
  pointer-events: none;
  /* Style from .tagline */
  font-family: 'Poppins', sans-serif;
  font-size: 0.9rem;
  letter-spacing: 0.126em;
  text-transform: uppercase;
  font-weight: 300;
  color: #1a1a1a;
  transition: opacity 0.2s ease-out;
}

/* Arrow bobbing animation */
@keyframes bobbing {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-12px);
  }
}

/* Arrow button */
.scroll-arrow {
  position: absolute;
  bottom: 2rem;
  width: 56px;
  height: 56px;
  border: none;
  background: none;
  cursor: pointer;
  z-index: 3;
  pointer-events: auto;
  transition: opacity 0.2s ease-out;
}
.scroll-arrow svg {
  width: 100%;
  height: 100%;
  stroke: #3355cc;
  stroke-width: 1.5px;
  fill: none;
  transition: transform 0.3s ease;
}
.scroll-arrow:hover svg {
  transform: translateY(4px);
}

/* ABOUT SECTION */
.about-section {
  background: #f9fbff;
  width: 100vw;
  padding: 8rem 2rem;
  box-sizing: border-box;
}
.portfolio-photo {
  width: 100%;
  max-width: 800px;
  display: block;
  margin: 3rem auto;
  box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}
.about-section h2 {
  font-size: 1rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 500;
  margin-bottom: 2rem;
  text-align: center;
}
.about-section p {
  max-width: 720px;
  margin: 0 auto;
  font-family: 'IBM Plex Sans', sans-serif;
  font-weight: 300;
  line-height: 1.7;
  font-size: 1rem;
  color: #333;
  text-align: center;
  padding: 0 3rem;
  word-wrap: break-word;
}

/* CORE CAPABILITIES */
.core-section {
  background: #f9fbff;
  padding: 8rem 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
.core-section h2 {
  font-size: 1rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 500;
  margin-bottom: 4rem;
}
.core-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2rem;
  max-width: 1000px;
  width: 100%;
}
.core-card {
  background: transparent;
  border-radius: 1.6rem;
  padding: 2.2rem;
  border: 1px solid #999;
  transition: border-color 0.3s ease;
}
.core-card:hover {
  border-color: #3355cc;
}
.core-card h3 {
  font-weight: 500;
  font-size: 1.1rem;
  margin-bottom: 0.8rem;
  letter-spacing: 0.02em;
}
.core-card p {
  font-family: 'IBM Plex Sans', sans-serif;
  font-weight: 300;
  line-height: 1.6;
  font-size: 0.95rem;
  color: #333;
}

@media (max-width: 480px) {
  .overlay h1 { font-size: clamp(2.8rem, 10vw, 5.5rem); }
  .core-section, .about-section { padding: 5rem 1.4rem; }
  .about-section p { font-size: 0.95rem; padding: 0 0.8rem; }
}

/* HERO LAYERING FIX */
.hero-section {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
  z-index: 0;
}

/* The ONLY canvas rule now — stays inside hero */
.hero-section canvas {
  position: absolute !important;
  top: 0;
  left: 0;
  width: 100% !important;
  height: 100% !important;
  z-index: 1;
  pointer-events: none; /* canvas won't intercept clicks */
}

/* --------------------------------
   TEXT FADE-IN ANIMATION RESTORE
---------------------------------- */
.overlay h1,
.tagline,
.hello-subline {
  opacity: 0;
  animation: fadeInUp 0.9s ease forwards;
}

.overlay h1 { animation-delay: 0.2s; }
.tagline { animation-delay: 0.5s; }
.hello-subline { animation-delay: 0.8s; }

@keyframes fadeInUp {
  0% {
    opacity: 0;
    transform: translateY(12px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* LOGO resizing like index page */
.identity img {
  height: 63px;       /* same size across all pages */
  width: auto;
  object-fit: contain;
  transition: height 0.35s ease;
}

nav.scrolled ~ .identity img {
  height: 63px;       /* shrinks when navbar is scrolled */
}

/* CONTACT FORM CENTERING */
.wrap {
  margin: 160px auto 80px auto; /* centers horizontally */
  max-width: 540px;
  padding: 0 40px;
  position: relative;
  z-index: 5;
  text-align: center; /* centers children inline-block elements */
}

form {
  display: inline-block; /* shrink-wrap the form */
  text-align: left;      /* keep labels and inputs left-aligned */
}

/* Custom Cursor - No Animation */
.custom-cursor {
  position: fixed;
  pointer-events: none;
  width: 16px;
  height: 16px;
  border: 2px solid #3355cc;
  border-radius: 50%;
  left: 0;
  top: 0;
  z-index: 10000;
  mix-blend-mode: multiply;
  opacity: 0;
  transition: opacity 0.1s ease;
}

.cta-button {
  padding: 1rem 2rem;
  background-color: #fff;
  color: #1a1a1a;
  border: 1px solid #3355cc;
  border-radius: 3rem;
  text-decoration: none;
  font-family: 'Poppins', sans-serif;
  font-weight: 300;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  transition: background-color 0.3s ease, color 0.3s ease;
  margin-bottom: 4rem;
}

.cta-button:hover {
  background-color: rgba(0, 0, 0, 0.05);
  color: #1a1a1a;
}

.cta-button .arrow {
  display: inline-block;
  transition: transform 0.3s ease;
}

.cta-button:hover .arrow {
  transform: translateX(5px);
}
