/* ============================================
   Pipeworks — Custom Styles
   ============================================ */

/* Base & Typography */
body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ============================================
   Floating Background Blobs
   ============================================ */
.blob {
  position: fixed;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.08;
  pointer-events: none;
  z-index: 0;
}

.blob-1 {
  width: 600px;
  height: 600px;
  background: #0d9488;
  top: -200px;
  right: -200px;
  animation: blobFloat 20s ease-in-out infinite;
}

.blob-2 {
  width: 400px;
  height: 400px;
  background: #14b8a6;
  bottom: 20%;
  left: -100px;
  animation: blobFloat 15s ease-in-out infinite reverse;
}

.blob-3 {
  width: 300px;
  height: 300px;
  background: #2dd4bf;
  top: 50%;
  right: 10%;
  animation: blobFloat 18s ease-in-out infinite;
}

@keyframes blobFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(30px, -30px) scale(1.05); }
  66% { transform: translate(-20px, 20px) scale(0.95); }
}

/* ============================================
   Hero Geometric Shapes
   ============================================ */
.geo-shape {
  position: absolute;
  opacity: 0.12;
  pointer-events: none;
}

.geo-circle-1 {
  width: 400px;
  height: 400px;
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  top: -80px;
  right: -80px;
  animation: geoFloat 12s ease-in-out infinite;
}

.geo-circle-2 {
  width: 200px;
  height: 200px;
  background: rgba(45, 212, 191, 0.3);
  border-radius: 50%;
  bottom: 15%;
  left: 5%;
  animation: geoFloat 10s ease-in-out infinite reverse;
}

.geo-square-1 {
  width: 120px;
  height: 120px;
  background: rgba(255, 255, 255, 0.08);
  border: 2px solid rgba(255, 255, 255, 0.2);
  top: 25%;
  left: 8%;
  transform: rotate(45deg);
  animation: geoSpin 20s linear infinite;
}

.geo-square-2 {
  width: 80px;
  height: 80px;
  background: rgba(45, 212, 191, 0.2);
  border: 2px solid rgba(45, 212, 191, 0.4);
  bottom: 25%;
  right: 12%;
  transform: rotate(30deg);
  animation: geoSpin 15s linear infinite reverse;
}

.geo-triangle-1 {
  width: 0;
  height: 0;
  border-left: 60px solid transparent;
  border-right: 60px solid transparent;
  border-bottom: 104px solid rgba(255, 255, 255, 0.08);
  top: 40%;
  right: 20%;
  animation: geoFloat 14s ease-in-out infinite;
}

.geo-dots {
  width: 120px;
  height: 120px;
  background-image: radial-gradient(circle, rgba(255, 255, 255, 0.4) 2px, transparent 2px);
  background-size: 16px 16px;
  top: 60%;
  left: 15%;
  animation: geoFloat 16s ease-in-out infinite reverse;
}

@keyframes geoFloat {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-20px) rotate(5deg); }
}

@keyframes geoSpin {
  from { transform: rotate(45deg); }
  to { transform: rotate(405deg); }
}

/* ============================================
   Service Cards
   ============================================ */
.service-card {
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #0d9488, #2dd4bf);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s ease;
}

.service-card:hover::before {
  transform: scaleX(1);
}

/* ============================================
   Project Cards
   ============================================ */
.project-card {
  cursor: pointer;
}

.project-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 16px;
  border: 2px solid transparent;
  transition: border-color 0.3s ease;
  pointer-events: none;
}

.project-card:hover::after {
  border-color: rgba(45, 212, 191, 0.5);
}

/* ============================================
   Scroll Reveal Animations
   (progressive enhancement — content visible without JS)
   ============================================ */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s ease, transform 0.6s ease;
  }

  .reveal[data-reveal] {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
  }

  .reveal[data-reveal="left"] {
    transform: translateX(-30px);
  }

  .reveal[data-reveal="right"] {
    transform: translateX(30px);
  }

  .reveal[data-reveal="scale"] {
    transform: scale(0.95);
  }
}

/* ============================================
   Navbar Scroll State
   ============================================ */
#navbar.scrolled {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 20px rgba(0, 0, 0, 0.08);
}

/* ============================================
   Mobile Menu
   ============================================ */
.mobile-link {
  position: relative;
}

.mobile-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: #0d9488;
  transition: width 0.3s ease;
}

.mobile-link:hover::after {
  width: 100%;
}

/* ============================================
   Form Focus States
   ============================================ */
input:focus,
select:focus,
textarea:focus {
  outline: none;
}

/* ============================================
   Smooth Scroll Offset for Fixed Header
   ============================================ */
section[id] {
  scroll-margin-top: 80px;
}

/* ============================================
   Responsive Adjustments
   ============================================ */
@media (max-width: 640px) {
  .geo-circle-1 {
    width: 200px;
    height: 200px;
  }

  .geo-circle-2 {
    width: 100px;
    height: 100px;
  }

  .geo-square-1 {
    width: 60px;
    height: 60px;
  }

  .geo-square-2 {
    width: 40px;
    height: 40px;
  }

  .geo-triangle-1 {
    border-left-width: 30px;
    border-right-width: 30px;
    border-bottom-width: 52px;
  }
}
