/* =====================================================
   Florida Pipe Works — Modern One-Pager
   Blue & White · Parallax · 2025-era polish
   ===================================================== */

:root {
  --navy: #0A2E5C;
  --navy-deep: #051A37;
  --blue: #1257B5;
  --sky: #2B9DF4;
  --sky-soft: #D6EBFB;
  --cloud: #F4F8FD;
  --white: #ffffff;
  --ink: #0E1A2B;
  --ink-soft: #4A5A6E;
  --line: #DDE6F0;
  --gold: #FFC233;
  --shadow-sm: 0 4px 16px rgba(10, 46, 92, 0.07);
  --shadow-md: 0 12px 32px rgba(10, 46, 92, 0.10);
  --shadow-lg: 0 24px 60px rgba(10, 46, 92, 0.18);
  --radius: 14px;
  --radius-lg: 22px;
  --maxw: 1200px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* -------------- Base -------------- */
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  font-weight: 400;
  line-height: 1.6;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--blue); text-decoration: none; transition: color .2s ease; }
a:hover { color: var(--sky); }

h1, h2, h3, h4 { line-height: 1.1; font-weight: 800; color: var(--navy); letter-spacing: -0.02em; }
h1 { font-size: clamp(2.4rem, 6vw, 4.5rem); font-weight: 900; }
h2 { font-size: clamp(1.8rem, 4vw, 2.8rem); }
h3 { font-size: 1.25rem; font-weight: 700; }

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.section { padding: clamp(80px, 10vw, 140px) 0; }
.section-head { max-width: 760px; margin-bottom: 60px; }
.section-head h2 { margin-top: 12px; }
.section-sub { color: var(--ink-soft); font-size: 1.1rem; margin-top: 18px; max-width: 600px; }

.eyebrow {
  display: inline-block;
  color: var(--sky);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.78rem;
  letter-spacing: 0.18em;
}
.eyebrow.light { color: rgba(255, 255, 255, 0.85); }

.accent { color: var(--sky); }

/* -------------- Buttons -------------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 13px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all .25s var(--ease);
  white-space: nowrap;
}
.btn svg { width: 18px; height: 18px; }
.btn-lg { padding: 17px 32px; font-size: 1rem; }
.btn-block { width: 100%; justify-content: center; }
.btn-primary { background: var(--navy); color: var(--white); }
.btn-primary:hover { background: var(--blue); color: var(--white); transform: translateY(-2px); box-shadow: var(--shadow-md); }
.btn-outline { background: transparent; color: var(--white); border-color: rgba(255, 255, 255, 0.4); }
.btn-outline:hover { background: var(--white); color: var(--navy); }
.btn-light { background: var(--white); color: var(--navy); }
.btn-light:hover { background: var(--gold); color: var(--navy); transform: translateY(-2px); box-shadow: var(--shadow-md); }

/* -------------- Nav -------------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 14px 0;
  transition: all .3s var(--ease);
}
.nav.scrolled {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  box-shadow: 0 2px 24px rgba(10, 46, 92, 0.08);
  padding: 10px 0;
}
.nav-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.nav-links {
  display: flex;
  gap: 4px;
}
.nav-links a {
  padding: 8px 14px;
  border-radius: 8px;
  color: var(--navy);
  font-weight: 600;
  font-size: 0.95rem;
}
.nav-links a:hover { background: var(--sky-soft); color: var(--navy); }
.nav.scrolled .nav-links a { color: var(--navy); }
.nav.scrolled .nav-links a:hover { background: var(--sky-soft); color: var(--navy); }
.nav-cta { display: flex; align-items: center; gap: 12px; }
.nav-phone {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--navy);
  font-weight: 700;
  font-size: 0.95rem;
}
.nav-phone svg { width: 16px; height: 16px; }
.nav.scrolled .nav-phone { color: var(--navy); }
.nav-toggle {
  display: none;
  background: none;
  border: 0;
  padding: 8px;
  cursor: pointer;
  flex-direction: column;
  gap: 5px;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--navy);
  transition: all .25s var(--ease);
}
.nav.scrolled .nav-toggle span { background: var(--navy); }

@media (max-width: 900px) {
  .nav-links, .nav-phone span { display: none; }
  .nav-toggle { display: inline-flex; }
  .nav-cta .btn { padding: 10px 18px; }
}
.nav.menu-open .nav-links {
  display: flex;
  flex-direction: column;
  position: absolute;
  top: 100%;
  left: 16px;
  right: 16px;
  background: var(--white);
  padding: 16px;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  gap: 4px;
}
.nav.menu-open .nav-links a { color: var(--navy); padding: 12px 16px; }

/* -------------- Hero -------------- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  color: var(--navy);
  background: var(--white);
  padding: 140px 24px 100px;
  overflow: hidden;
  isolation: isolate;
}
/* Multi-layer parallax — each layer scrolls at its own depth */
.hero-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  will-change: transform;
}
.hero-bg {
  z-index: 1;
  background: var(--white);
}
.hero-blobs { z-index: 2; }
.hero-particles { z-index: 3; }
.hero-particles canvas { width: 100% !important; height: 100% !important; }
.hero-waves { z-index: 4; }
.hero-inner { z-index: 5; }
.hero-gradient {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(900px 500px at 80% 20%, rgba(43, 157, 244, 0.08), transparent 60%),
    radial-gradient(700px 400px at 20% 80%, rgba(43, 157, 244, 0.05), transparent 65%);
}
.hero-wave {
  position: absolute;
  bottom: -1px;
  left: 0;
  width: 100%;
  height: 260px;
  pointer-events: none;
}
.hero-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  opacity: 0.18;
  pointer-events: none;
  animation: float 18s ease-in-out infinite;
}
.hero-blob-1 {
  width: 480px; height: 480px;
  background: var(--sky);
  top: 10%; left: 8%;
}
.hero-blob-2 {
  width: 380px; height: 380px;
  background: #4fb4ff;
  bottom: 12%; right: 6%;
  animation-delay: -9s;
}
.hero-blob-3 {
  width: 260px; height: 260px;
  background: #7ec8ff;
  top: 42%; right: 28%;
  animation-delay: -4s;
  opacity: 0.12;
}
@keyframes float {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(40px, -30px); }
}

.hero-inner {
  position: relative;
  max-width: 920px;
  z-index: 2;
  will-change: transform;
}
.hero-logo {
  display: block;
  width: clamp(360px, 52vw, 680px);
  height: auto;
  margin: 0 auto 20px;
  will-change: transform, opacity;
}
.hero-inner .eyebrow { color: var(--ink-soft); margin-bottom: 18px; }
.hero h1 { color: var(--navy); margin-bottom: 24px; }
.hero-title .word {
  display: inline-block;
  will-change: transform, opacity;
  padding-right: 0.18em;
}
.hero-title .word.accent { color: var(--sky); padding-right: 0; }
.hero-eyebrow { will-change: opacity, transform; }
.hero-sub {
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  color: var(--ink-soft);
  max-width: 700px;
  margin: 0 auto 36px;
}
.hero-ctas {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 48px;
}
.hero-points {
  display: flex;
  gap: 24px;
  justify-content: center;
  flex-wrap: wrap;
  color: var(--ink-soft);
  font-weight: 500;
  font-size: 0.95rem;
}

.hero-scroll {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  width: 28px;
  height: 44px;
  border: 2px solid rgba(10, 46, 92, 0.35);
  border-radius: 14px;
  display: grid;
  place-items: start center;
  padding-top: 8px;
}
.hero-scroll span {
  display: block;
  width: 3px;
  height: 8px;
  background: var(--navy);
  border-radius: 2px;
  animation: scrollDot 1.6s ease-in-out infinite;
}
@keyframes scrollDot {
  0% { transform: translateY(0); opacity: 1; }
  100% { transform: translateY(16px); opacity: 0; }
}

/* -------------- Reveal animations -------------- */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity .8s var(--ease), transform .8s var(--ease);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* -------------- Pillars (About) -------------- */
.about { background: var(--white); }
.pillars {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.pillar {
  background: var(--cloud);
  border-radius: var(--radius-lg);
  padding: 32px 26px;
  transition: transform .3s var(--ease), box-shadow .3s var(--ease);
  border: 1px solid transparent;
}
.pillar:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  background: var(--white);
  border-color: var(--line);
}
.pillar-icon {
  width: 56px; height: 56px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--blue), var(--sky));
  display: grid;
  place-items: center;
  margin-bottom: 20px;
  color: var(--white);
}
.pillar-icon svg { width: 26px; height: 26px; }
.pillar h3 { margin-bottom: 8px; }
.pillar p { color: var(--ink-soft); font-size: 0.95rem; }
@media (max-width: 900px) { .pillars { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .pillars { grid-template-columns: 1fr; } }

/* -------------- Services / Cards with tilt -------------- */
.services { background: var(--cloud); }
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 36px 30px;
  border: 1px solid var(--line);
  transition: box-shadow .3s var(--ease);
  cursor: pointer;
  position: relative;
  overflow: hidden;
}
.card.tilt {
  transform-style: preserve-3d;
  transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
  transition: transform .12s ease, box-shadow .3s var(--ease);
}
.card:hover { box-shadow: var(--shadow-lg); }
.card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(400px circle at var(--mx, 50%) var(--my, 50%), rgba(43, 157, 244, 0.12), transparent 40%);
  opacity: 0;
  transition: opacity .3s var(--ease);
  pointer-events: none;
}
.card:hover::before { opacity: 1; }
.card-icon {
  width: 56px; height: 56px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--navy), var(--blue));
  display: grid;
  place-items: center;
  margin-bottom: 22px;
  color: var(--white);
}
.card-icon svg { width: 26px; height: 26px; }
.card h3 { margin-bottom: 10px; }
.card p { color: var(--ink-soft); font-size: 0.95rem; margin-bottom: 18px; }
.card-link { color: var(--blue); font-weight: 700; font-size: 0.92rem; }
@media (max-width: 900px) { .cards { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .cards { grid-template-columns: 1fr; } }

/* -------------- Parallax breaks -------------- */
.parallax-break {
  position: relative;
  padding: clamp(100px, 14vw, 180px) 24px;
  color: var(--white);
  text-align: center;
  overflow: hidden;
  background-attachment: fixed;
  background-size: cover;
  background-position: center;
}
.parallax-break::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(5, 26, 55, 0.55), rgba(18, 87, 181, 0.45));
  z-index: 1;
}
.break-1 {
  background-image: url('../images/parallax-1.jpg');
}
.break-2 {
  background-image: url('../images/parallax-2.jpg');
}
.break-content {
  position: relative;
  z-index: 2;
  max-width: 880px;
  margin: 0 auto;
}
.break-content h2 {
  color: var(--white);
  font-size: clamp(1.7rem, 3.8vw, 2.8rem);
  margin: 18px 0 32px;
}

/* On touch devices `background-attachment: fixed` is janky — disable */
@media (hover: none), (max-width: 700px) {
  .parallax-break { background-attachment: scroll; }
}

/* -------------- Testimonials -------------- */
.testimonials { background: var(--white); }
.quotes {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.quote {
  background: var(--cloud);
  border-radius: var(--radius-lg);
  padding: 34px 28px;
  border-left: 4px solid var(--sky);
  transition: transform .25s var(--ease), box-shadow .25s var(--ease);
}
.quote:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.stars { color: var(--gold); font-size: 1.1rem; letter-spacing: 2px; margin-bottom: 14px; }
.quote blockquote {
  font-size: 1rem;
  color: var(--ink);
  font-style: italic;
  margin-bottom: 16px;
}
.quote figcaption { color: var(--ink-soft); font-weight: 600; font-size: 0.9rem; }
@media (max-width: 900px) { .quotes { grid-template-columns: 1fr; } }

/* -------------- Service Area -------------- */
.service-area { background: var(--cloud); }
.pills {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  max-width: 900px;
}
.pills span {
  display: inline-block;
  background: var(--white);
  color: var(--navy);
  padding: 10px 18px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.92rem;
  border: 1px solid var(--line);
  transition: all .2s ease;
  cursor: default;
}
.pills span:hover {
  background: var(--blue);
  color: var(--white);
  border-color: var(--blue);
  transform: translateY(-2px);
}

/* -------------- Contact (parallax break #2) -------------- */
.contact-grid {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: center;
  text-align: center;
}
.contact-info {
  max-width: 640px;
  width: 100%;
}
.contact-info h2 { color: var(--white); margin: 14px 0 20px; }
.contact-lede { color: rgba(255, 255, 255, 0.9); margin: 0 auto 32px; max-width: 520px; }
.contact-list {
  list-style: none;
  display: grid;
  gap: 16px;
  text-align: left;
  max-width: 460px;
  margin: 0 auto 36px;
}
.contact-list li {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 14px;
  align-items: start;
  color: var(--white);
  font-size: 1.1rem;
  font-weight: 700;
  line-height: 1.45;
}
.contact-list strong { color: var(--white); font-weight: 700; }
.contact-list a { color: var(--white); font-weight: 700; }
.contact-list a:hover { color: var(--sky); }
.contact-cta { margin-top: 8px; }

.contact-form {
  background: rgba(255, 255, 255, 0.97);
  border-radius: var(--radius-lg);
  padding: 36px;
  color: var(--ink);
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(8px);
}
.contact-form h3 { color: var(--navy); font-size: 1.4rem; margin-bottom: 8px; }
.contact-form label {
  display: block;
  font-weight: 600;
  color: var(--navy);
  font-size: 0.88rem;
  margin-top: 14px;
}
.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  padding: 12px 14px;
  margin-top: 6px;
  border: 2px solid var(--line);
  border-radius: 10px;
  font-size: 1rem;
  font-family: inherit;
  color: var(--ink);
  background: var(--white);
  transition: border-color .2s ease;
}
.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--sky);
}
.contact-form .form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.contact-form textarea { resize: vertical; min-height: 100px; }
.contact-form button { margin-top: 22px; }
.contact-form .ok {
  background: #E8F7EE;
  color: #1FA971;
  padding: 14px;
  border-radius: 10px;
  margin-top: 16px;
  font-weight: 600;
  text-align: center;
}

/* -------------- Footer -------------- */
.footer { background: var(--navy-deep); color: rgba(255, 255, 255, 0.85); padding: 80px 0 0; }
.footer h4 {
  color: var(--white);
  text-transform: uppercase;
  font-size: 0.82rem;
  letter-spacing: 0.14em;
  margin-bottom: 16px;
  font-weight: 700;
}
.footer a { color: rgba(255, 255, 255, 0.75); }
.footer a:hover { color: var(--sky); }
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1.2fr;
  gap: 40px;
}
.footer-brand p { color: rgba(255, 255, 255, 0.65); font-size: 0.95rem; max-width: 360px; }
.footer ul { list-style: none; }
.footer ul li { padding: 5px 0; font-size: 0.95rem; }
.footer p { font-size: 0.95rem; margin-bottom: 6px; }
.copybar {
  margin-top: 56px;
  padding: 18px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
}
.copybar .container {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}
@media (max-width: 900px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .footer-grid { grid-template-columns: 1fr; }
}

/* -------------- Pinned Stats Section -------------- */
.stats-section { background: var(--white); position: relative; }
.stats-pin {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 100px 0;
}
.stats-head {
  text-align: center;
  max-width: 760px;
  margin: 0 auto 80px;
}
.stats-head h2 { margin-top: 14px; }
.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 80px;
  max-width: 820px;
  margin: 0 auto;
  width: 100%;
}
.stat { text-align: center; padding: 0 16px; }
.stat .num {
  font-size: clamp(3rem, 7vw, 5.5rem);
  font-weight: 900;
  color: var(--navy);
  line-height: 1;
  letter-spacing: -0.04em;
  display: inline-flex;
  align-items: baseline;
  margin-bottom: 18px;
  font-variant-numeric: tabular-nums;
}
.num-val { display: inline-block; }
.num-suffix {
  font-size: 0.42em;
  color: var(--sky);
  margin-left: 6px;
  font-weight: 800;
}
.stat .lbl {
  color: var(--ink-soft);
  font-size: 1rem;
  font-weight: 500;
  max-width: 240px;
  margin: 0 auto;
  line-height: 1.5;
}
@media (max-width: 800px) {
  .stats-grid { grid-template-columns: 1fr; gap: 50px; }
  .stats-pin { min-height: auto; padding: 80px 0; }
}

/* -------------- Magnetic button -------------- */
.magnetic { will-change: transform; }

/* -------------- Reduced motion -------------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .reveal { opacity: 1; transform: none; }
  .parallax-break { background-attachment: scroll; }
  .hero-blob { animation: none; }
}
