#nb-loader {
  position: fixed;
  inset: 0;
  z-index: 99999;
  background: #1A1A1A;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

#nb-loader.ldr-fast .ldr-shapes,
#nb-loader.ldr-fast .ldr-grid,
#nb-loader.ldr-fast .ldr-logo,
#nb-loader.ldr-fast .ldr-tagline,
#nb-loader.ldr-fast .ldr-progress-wrap { display: none; }

#nb-loader.ldr-fast::before {
  content: 'BYTMATRIX';
  font-family: 'Space Grotesk', sans-serif;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.2em;
  color: rgba(255,107,26,0.4);
  text-transform: uppercase;
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
}

.ldr-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,107,26,0.12) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,107,26,0.12) 1px, transparent 1px);
  background-size: 64px 64px;
  opacity: 0;
  animation: ldr-grid-in 0.6s ease 0.1s forwards;
  pointer-events: none;
}
@keyframes ldr-grid-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.ldr-shapes { position: absolute; inset: 0; pointer-events: none; }

.ldr-circle-y {
  position: absolute;
  width: clamp(200px, 28vw, 400px);
  height: clamp(200px, 28vw, 400px);
  border-radius: 50%;
  background: #FF6B1A;
  top: -100px; left: -80px;
  transform: scale(0);
  opacity: 0.9;
  animation: ldr-pop 0.7s cubic-bezier(0.34,1.56,0.64,1) 0.2s forwards;
}
.ldr-circle-o {
  position: absolute;
  width: clamp(120px, 18vw, 240px);
  height: clamp(120px, 18vw, 240px);
  border-radius: 50%;
  background: transparent;
  border: 5px solid #FF6B1A;
  bottom: 60px; right: 80px;
  transform: scale(0);
  animation: ldr-pop 0.6s cubic-bezier(0.34,1.56,0.64,1) 0.5s forwards;
}
.ldr-rect-r {
  position: absolute;
  width: clamp(40px, 5vw, 72px);
  height: clamp(120px, 18vw, 220px);
  background: #E8002D;
  top: 80px; right: clamp(80px, 12vw, 160px);
  transform: scaleY(0);
  transform-origin: bottom;
  animation: ldr-scale-y 0.5s ease 0.7s forwards;
}
.ldr-rect-b {
  position: absolute;
  width: clamp(50px, 7vw, 96px);
  height: clamp(50px, 7vw, 96px);
  background: #1A3A6B;
  bottom: clamp(80px, 14vw, 160px);
  left: clamp(100px, 16vw, 240px);
  transform: scale(0) rotate(0deg);
  animation: ldr-pop-rotate 0.5s cubic-bezier(0.34,1.56,0.64,1) 0.9s forwards;
}
.ldr-tri {
  position: absolute;
  width: 0; height: 0;
  border-left: clamp(40px, 6vw, 80px) solid transparent;
  border-right: clamp(40px, 6vw, 80px) solid transparent;
  border-bottom: clamp(70px, 10vw, 140px) solid #F5F0E8;
  bottom: 100px; left: clamp(60px, 10vw, 140px);
  transform: scale(0);
  opacity: 0.25;
  animation: ldr-pop 0.5s ease 1.1s forwards;
}
.ldr-line-h {
  position: absolute;
  left: 0; right: 0;
  top: 50%;
  height: 3px;
  background: #FF6B1A;
  transform: scaleX(0);
  transform-origin: left;
  opacity: 0.15;
  animation: ldr-scale-x 0.8s ease 0.15s forwards;
}
.ldr-line-v {
  position: absolute;
  top: 0; bottom: 0;
  left: 50%;
  width: 3px;
  background: #FF6B1A;
  transform: scaleY(0);
  transform-origin: top;
  opacity: 0.15;
  animation: ldr-scale-y 0.8s ease 0.3s forwards;
}

@keyframes ldr-pop {
  from { transform: scale(0); }
  to   { transform: scale(1); }
}
@keyframes ldr-pop-rotate {
  from { transform: scale(0) rotate(-45deg); }
  to   { transform: scale(1) rotate(45deg); }
}
@keyframes ldr-scale-y {
  from { transform: scaleY(0); }
  to   { transform: scaleY(1); }
}
@keyframes ldr-scale-x {
  from { transform: scaleX(0); }
  to   { transform: scaleX(1); }
}

.ldr-center {
  position: relative;
  z-index: 5;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
}

.ldr-logo {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(52px, 9vw, 108px);
  font-weight: 800;
  letter-spacing: -4px;
  line-height: 1;
  overflow: hidden;
  margin-bottom: 0;
}
.ldr-logo-byt   { color: #FFFFFF; display: inline-block; }
.ldr-logo-matrix { color: #FF6B1A; display: inline-block; }

.ldr-char {
  display: inline-block;
  opacity: 0;
  transform: translateY(100%);
  animation: ldr-char-in 0.4s cubic-bezier(0.4,0,0.2,1) forwards;
}
@keyframes ldr-char-in {
  from { opacity: 0; transform: translateY(100%); }
  to   { opacity: 1; transform: translateY(0); }
}

.ldr-tagline {
  font-family: 'IBM Plex Mono', monospace;
  font-size: clamp(10px, 1.4vw, 13px);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.25em;
  color: #8A8480;
  margin-top: 10px;
  opacity: 0;
  animation: ldr-fade-up 0.5s ease 1.5s forwards;
}
@keyframes ldr-fade-up {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

.ldr-progress-wrap {
  margin-top: 28px;
  display: flex;
  align-items: center;
  gap: 14px;
  justify-content: center;
  opacity: 0;
  animation: ldr-fade-up 0.4s ease 1.7s forwards;
}
.ldr-progress-bar {
  width: clamp(180px, 28vw, 280px);
  height: 3px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,107,26,0.25);
  overflow: visible;
  position: relative;
}
.ldr-progress-fill {
  height: 100%;
  width: 0%;
  background: #FF6B1A;
  transition: width 0.08s linear;
  position: relative;
}
.ldr-progress-fill::after {
  content: '';
  position: absolute;
  right: -2px;
  top: 50%;
  transform: translateY(-50%);
  width: 6px;
  height: 6px;
  background: #FFFFFF;
  box-shadow: 0 0 8px rgba(255,107,26,0.8);
  border-radius: 50%;
}
.ldr-pct {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 13px;
  font-weight: 700;
  color: #FF6B1A;
  min-width: 44px;
  text-align: left;
}

.ldr-puzzle-grid {
  position: absolute;
  inset: -2px; 
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  grid-template-rows: repeat(6, 1fr);
  z-index: 999;
  pointer-events: none;
  visibility: hidden;
}

#nb-loader.ldr-exiting .ldr-puzzle-grid {
  visibility: visible;
}

#nb-loader.ldr-exiting .ldr-center,
#nb-loader.ldr-exiting .ldr-shapes,
#nb-loader.ldr-exiting .ldr-grid {
  opacity: 0;
  transition: opacity 0.22s ease-out;
}

.ldr-puzzle-tile {
  background: #1A1A1A;
  transform: scale(1.05) rotate(0deg) translate(0px, 0px);
  opacity: 1;
  transition: transform 0.85s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.75s cubic-bezier(0.25, 1, 0.5, 1);
  will-change: transform, opacity;
  border: 0.5px solid #1A1A1A;
}

.ldr-puzzle-tile.accent-y { background: #FF6B1A; border-color: #FF6B1A; }
.ldr-puzzle-tile.accent-r { background: #E8002D; border-color: #E8002D; }
.ldr-puzzle-tile.accent-b { background: #1A3A6B; border-color: #1A3A6B; }
.ldr-puzzle-tile.accent-c { background: #F5F0E8; border-color: #F5F0E8; }

#nb-loader.ldr-exiting .ldr-puzzle-tile {
  transform: scale(0) rotate(var(--rot)) translate(var(--tx), var(--ty));
  opacity: 0;
  transition-delay: var(--delay);
}

body:not(.ldr-done) nav,
body:not(.ldr-done) main,
body:not(.ldr-done) footer,
body:not(.ldr-done) .hero-left,
body:not(.ldr-done) .hero-right,
body:not(.ldr-done) .recent-projects-section,
body:not(.ldr-done) .gallery-hero-inner,
body:not(.ldr-done) .product-hero-inner,
body:not(.ldr-done) .services-page-hero,
body:not(.ldr-done) .svc-hero-h1 {
  opacity: 0;
}

body:not(.ldr-done) .hero-left {
  transform: translateY(20px);
}
body:not(.ldr-done) .hero-right {
  transform: translateY(20px);
}
body:not(.ldr-done) nav {
  transform: translateY(-15px);
}
body:not(.ldr-done) .recent-projects-section {
  transform: translateY(20px);
}
body:not(.ldr-done) .gallery-hero-inner,
body:not(.ldr-done) .product-hero-inner,
body:not(.ldr-done) .services-page-hero,
body:not(.ldr-done) .svc-hero-h1 {
  transform: translateY(25px);
}

body.ldr-done nav,
body.ldr-done main,
body.ldr-done footer {
  opacity: 1;
}

body.ldr-done nav {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  transition-delay: 0.25s;
}

body.ldr-done .hero-left {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.9s cubic-bezier(0.16, 1, 0.3, 1), transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
  transition-delay: 0.35s;
}

body.ldr-done .hero-right {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.9s cubic-bezier(0.16, 1, 0.3, 1), transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
  transition-delay: 0.42s;
}

body.ldr-done .recent-projects-section {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 1s cubic-bezier(0.2, 0.8, 0.2, 1), transform 1s cubic-bezier(0.2, 0.8, 0.2, 1);
  transition-delay: 0.6s;
}

body.ldr-done .gallery-hero-inner,
body.ldr-done .product-hero-inner,
body.ldr-done .services-page-hero,
body.ldr-done .svc-hero-h1 {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.9s cubic-bezier(0.2, 0.8, 0.2, 1), transform 0.9s cubic-bezier(0.2, 0.8, 0.2, 1);
  transition-delay: 0.2s;
}

.nb-search-overlay {
  position: fixed;
  inset: 0;
  z-index: 9990;
  background: rgba(26,26,26,0.85);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: clamp(60px, 12vh, 140px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}
.nb-search-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.nb-search-box {
  width: min(680px, 94vw);
  background: #F5F0E8;
  border: 3px solid #1A1A1A;
  box-shadow: 10px 10px 0 #1A1A1A;
  transform: translateY(-20px) scale(0.97);
  transition: transform 0.3s cubic-bezier(0.34,1.36,0.64,1);
  overflow: hidden;
}
.nb-search-overlay.open .nb-search-box {
  transform: translateY(0) scale(1);
}

.nb-search-top {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 3px solid #1A1A1A;
  background: #1A1A1A;
}
.nb-search-icon { color: #FF6B1A; font-size: 18px; flex-shrink: 0; }

.nb-search-input {
  flex: 1;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 16px;
  font-weight: 500;
  color: #FFFFFF;
  background: transparent;
  border: none;
  outline: none;
  caret-color: #FF6B1A;
}
.nb-search-input::placeholder { color: #8A8480; }

.nb-search-close {
  background: none;
  border: 2px solid rgba(255,107,26,0.4);
  color: #8A8480;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 8px;
  cursor: pointer;
  transition: all 0.15s;
  flex-shrink: 0;
}
.nb-search-close:hover { background: rgba(255,107,26,0.2); color: #FF6B1A; }

.nb-search-shortcut-hint {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  font-weight: 700;
  color: #8A8480;
  border: 1px solid #8A8480;
  padding: 2px 6px;
  letter-spacing: 0.06em;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 4px;
}

.nb-search-results {
  max-height: 380px;
  overflow-y: auto;
}
.nb-search-results::-webkit-scrollbar { width: 4px; }
.nb-search-results::-webkit-scrollbar-track { background: #F5F0E8; }
.nb-search-results::-webkit-scrollbar-thumb { background: #FF6B1A; }

.nb-search-result {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 20px;
  border-bottom: 2px solid #1A1A1A;
  cursor: pointer;
  text-decoration: none;
  background: #F5F0E8;
  transition: background 0.12s, transform 0.12s;
  opacity: 0;
  animation: ldr-fade-up 0.25s ease forwards;
}
.nb-search-result:last-child { border-bottom: none; }
.nb-search-result:hover {
  background: #FFFFFF;
  transform: translateX(4px);
}
.nb-search-result.focused { background: #FFFFFF; outline: 2px solid #FF6B1A; }

.nb-search-result-icon {
  width: 40px;
  height: 40px;
  background: #1A1A1A;
  border: 2px solid #1A1A1A;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #FF6B1A;
  font-size: 15px;
  flex-shrink: 0;
  box-shadow: 3px 3px 0 #FF6B1A;
}
.nb-search-result-body { flex: 1; min-width: 0; }
.nb-search-result-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 15px;
  font-weight: 700;
  color: #1A1A1A;
  line-height: 1.2;
}
.nb-search-result-title mark {
  background: #FF6B1A;
  color: #1A1A1A;
  border-radius: 0;
  padding: 0 2px;
}
.nb-search-result-desc {
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  color: #8A8480;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.nb-search-result-tag {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border: 2px solid #1A1A1A;
  padding: 3px 8px;
  background: #F5F0E8;
  flex-shrink: 0;
  color: #1A1A1A;
}
.nb-search-result-tag.tag-service  { background: #FF6B1A; color: #1A1A1A; }
.nb-search-result-tag.tag-product  { background: #1A3A6B; color: #FFFFFF; }
.nb-search-result-tag.tag-page     { background: #F5F0E8; color: #1A1A1A; }
.nb-search-result-tag.tag-action   { background: #E8002D; color: #FFFFFF; }

.nb-search-empty {
  padding: 32px 20px;
  text-align: center;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 13px;
  font-weight: 700;
  color: #8A8480;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.nb-search-footer {
  padding: 12px 20px;
  border-top: 2px solid #1A1A1A;
  background: #1A1A1A;
  display: flex;
  align-items: center;
  gap: 20px;
}
.nb-search-hint-item {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  font-weight: 700;
  color: #8A8480;
  display: flex;
  align-items: center;
  gap: 6px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.nb-search-key {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  padding: 2px 6px;
  font-size: 10px;
  color: #FFFFFF;
}

.nb-search-btn {
  background: none;
  border: 2px solid rgba(255,107,26,0.35);
  color: #8A8480;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 6px 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.15s;
  white-space: nowrap;
}
.nb-search-btn:hover { border-color: #FF6B1A; color: #FF6B1A; }
.nb-search-btn kbd {
  font-size: 10px;
  border: 1px solid rgba(255,255,255,0.2);
  padding: 1px 5px;
  background: rgba(255,255,255,0.05);
  color: #8A8480;
}

@media (pointer: fine) {
  /* Cursor hidden only when JS confirms it's active */
  body.nb-custom-cursor-active { cursor: none !important; }
  body.nb-custom-cursor-active *, 
  body.nb-custom-cursor-active *::before, 
  body.nb-custom-cursor-active *::after { cursor: none !important; }

  #nb-cursor {
    position: fixed;
    pointer-events: none;
    z-index: 99998;
    mix-blend-mode: normal;
    top: 0; left: 0;
    /* Start fully hidden until first mouse move */
    opacity: 0;
    transition: opacity 0.2s ease;
  }

  #nb-cursor.nb-cursor-visible {
    opacity: 1;
  }

  .nb-cursor-dot {
    width: 8px;
    height: 8px;
    background: #FF6B1A;
    border-radius: 50%;
    position: absolute;
    transform: translate(-50%, -50%);
    transition: transform 0.05s, width 0.2s, height 0.2s, background 0.2s;
    will-change: left, top;
  }

  .nb-cursor-ring {
    width: 36px;
    height: 36px;
    border: 2px solid rgba(255,107,26,0.5);
    border-radius: 50%;
    position: absolute;
    transform: translate(-50%, -50%);
    transition: width 0.2s, height 0.2s, opacity 0.2s;
    will-change: left, top;
  }

  body.cursor-hover .nb-cursor-dot  { transform: translate(-50%,-50%) scale(2); background: #FF6B1A; }
  body.cursor-hover .nb-cursor-ring { width: 56px; height: 56px; opacity: 0.3; }

  body.cursor-click .nb-cursor-dot  { transform: translate(-50%,-50%) scale(0.5); }
  body.cursor-click .nb-cursor-ring { transform: translate(-50%,-50%) scale(0.8); }
}

.st-parallax {
  
  transform: translateY(calc((var(--st-progress, 0.5) - 0.5) * var(--st-speed, 100px)));
  will-change: transform;
}

.st-assemble-left {
  transform: translateX(calc((1 - var(--st-progress, 1)) * -35px));
  opacity: var(--st-progress, 0);
  will-change: transform, opacity;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease-out;
}

.st-assemble-right {
  transform: translateX(calc((1 - var(--st-progress, 1)) * 35px));
  opacity: var(--st-progress, 0);
  will-change: transform, opacity;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease-out;
}

.st-scale-up {
  transform: scale(calc(0.97 + (var(--st-progress, 0) * 0.03)));
  opacity: var(--st-progress, 0);
  will-change: transform, opacity;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.4s ease-out;
}

.st-reveal-swipe {
  clip-path: inset(0 calc((1 - var(--st-progress, 1)) * 100%) 0 0);
  transition: clip-path 0.2s cubic-bezier(0.2, 0.8, 0.2, 1);
  will-change: clip-path;
}

.st-rotate-scroll {
  transform: rotate(calc(var(--st-progress, 0.5) * 360deg));
  will-change: transform;
}

.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 4px;
  background: var(--yellow, #FF6B1A);
  z-index: 10001;
  width: 0% !important;
  transition: width 0.1s ease-out;
}

