:root {
  --bg: #F5FAFB;
  --bg-alt: #E6F3F6;
  --ink: #0B2733;
  --ink-soft: #4C6975;
  --deep: #0A3A54;
  --deep-2: #0E4E70;
  --blue: #1C8FC4;
  --blue-soft: #CDE9F3;
  --teal: #17B18F;
  --teal-dark: #0F8F72;
  --amber: #F2A65A;
  --white: #FFFFFF;
  --shadow: 0 20px 60px -20px rgba(10, 58, 84, 0.35);
  --ease: cubic-bezier(0.22, 0.9, 0.32, 1);
  --radius: 14px;
  --font-display: 'Fraunces', Georgia, serif;
  --font-body: 'Plus Jakarta Sans', sans-serif;
  --font-mono: 'Space Mono', monospace;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

ul {
  list-style: none;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.1;
  color: var(--deep);
}

p {
  margin: 0;
}

::selection {
  background: var(--teal);
  color: var(--white);
}

:focus-visible {
  outline: 3px solid var(--amber);
  outline-offset: 3px;
  border-radius: 4px;
}

.container,
.wrap {
  width: min(1180px, 92%);
  margin-inline: auto;
  padding-inline: clamp(0px, 0vw, 0px);
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal-dark);
  display: inline-flex;
  align-items: center;
  gap: 0.55em;
}

.eyebrow::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 0 4px rgba(23, 177, 143, 0.18);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: 100px;
  font-weight: 700;
  font-size: 0.95rem;
  border: none;
  cursor: pointer;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), background 0.25s var(--ease);
  font-family: var(--font-body);
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  background: var(--teal);
  color: var(--white);
  box-shadow: 0 10px 24px -10px rgba(23, 177, 143, 0.55);
}

.btn-primary:hover {
  background: var(--teal-dark);
  box-shadow: 0 16px 30px -10px rgba(23, 177, 143, 0.6);
}

.btn-ghost {
  background: transparent;
  color: var(--deep);
  border: 1.5px solid rgba(10, 58, 84, 0.25);
}

.btn-ghost:hover {
  border-color: var(--deep);
  background: rgba(10, 58, 84, 0.05);
}

.btn-whatsapp {
  background: var(--teal);
  color: var(--white);
  box-shadow: 0 10px 24px -10px rgba(23, 177, 143, 0.55);
}

.btn-whatsapp:hover {
  background: var(--teal-dark);
}

.btn-sm {
  padding: 10px 20px;
  font-size: 0.88rem;
}

.btn-block {
  width: 100%;
}

/* ---------- ambient ripples ---------- */
.ripple-field {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}

.ripple {
  position: absolute;
  border-radius: 50%;
  border: 1.5px solid rgba(28, 143, 196, 0.18);
}

@keyframes ripple-grow {
  0% { transform: scale(0.7); opacity: 0.55; }
  100% { transform: scale(1.35); opacity: 0; }
}

/* ---------- header ---------- */
.site-header,
.lp-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(245, 250, 251, 0.82);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(10, 58, 84, 0.08);
}

.site-header .container,
.lp-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
  gap: 20px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.25rem;
  color: var(--deep);
}

.brand img {
  height: 34px;
  width: auto;
  filter: brightness(0) saturate(100%) invert(14%) sepia(30%) saturate(1200%) hue-rotate(160deg) brightness(95%);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-links a {
  font-size: 0.94rem;
  font-weight: 500;
  color: var(--ink-soft);
  transition: color 0.2s var(--ease);
}

.nav-links a:hover {
  color: var(--deep);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-actions .btn-sm,
.site-header .btn-primary {
  padding: 11px 22px;
  font-size: 0.88rem;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  width: 30px;
  height: 22px;
  position: relative;
}

.nav-toggle span,
.nav-toggle span::before,
.nav-toggle span::after {
  content: '';
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--deep);
  transition: transform 0.2s ease;
}

.nav-toggle span { top: 10px; }
.nav-toggle span::before { top: -8px; }
.nav-toggle span::after { top: 8px; }

.back-link {
  color: var(--ink-soft);
  font-size: 0.88rem;
  font-weight: 500;
  transition: color 0.2s;
}

.back-link:hover {
  color: var(--deep);
}

/* ---------- hero ---------- */
.hero {
  position: relative;
  padding: clamp(50px, 9vw, 110px) 0 clamp(40px, 7vw, 70px);
  overflow: hidden;
  background: var(--bg);
  color: var(--ink);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(30px, 6vw, 60px);
  align-items: center;
  position: relative;
  z-index: 1;
}

.hero .eyebrow {
  margin-bottom: 0;
}

.hero h1 {
  font-size: clamp(2.3rem, 4.6vw, 3.6rem);
  margin: 18px 0 22px;
  letter-spacing: -0.01em;
  color: var(--deep);
}

.hero h1 em {
  font-style: italic;
  color: var(--blue);
}

.hero-sub,
.hero p {
  font-size: clamp(1.02rem, 1.6vw, 1.18rem);
  color: var(--ink-soft);
  max-width: 46ch;
  line-height: 1.55;
}

.hero-actions,
.hero-cta {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 34px;
  flex-wrap: wrap;
}

.hero-visual {
  position: relative;
  aspect-ratio: 1 / 1;
}

.loop-svg {
  width: 100%;
  height: 100%;
}

.loop-ring {
  transform-origin: center;
}

@keyframes spin-slow {
  to { transform: rotate(360deg); }
}

@keyframes spin-slow-rev {
  to { transform: rotate(-360deg); }
}

.loop-ring-outer {
  animation: spin-slow 60s linear infinite;
}

.loop-ring-inner {
  animation: spin-slow-rev 46s linear infinite;
}

.loop-drop {
  animation: bob 5s ease-in-out infinite;
}

@keyframes bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

/* ---------- wave ---------- */
.wave {
  display: block;
  width: 100%;
  line-height: 0;
  position: relative;
  z-index: 1;
}

.wave svg {
  width: 100%;
  height: auto;
  display: block;
}

/* ---------- sections ---------- */
section {
  position: relative;
  padding: clamp(60px, 9vw, 96px) 0;
}

.section-alt,
.benefits {
  background: var(--bg-alt);
}

.section-head {
  max-width: 640px;
  margin-bottom: clamp(40px, 6vw, 64px);
}

.section-head h2 {
  font-size: clamp(1.9rem, 3.6vw, 2.7rem);
  margin-top: 14px;
}

.section-head p {
  color: var(--ink-soft);
  margin-top: 16px;
  font-size: 1.05rem;
  line-height: 1.6;
}

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(40px, 6vw, 64px);
  align-items: center;
}

.split-media {
  border-radius: 32px 32px 32px 8px;
  box-shadow: var(--shadow);
  width: 100%;
  object-fit: cover;
  aspect-ratio: 4 / 3;
}

.split.reverse .split-media {
  order: 2;
}

.split h2 {
  font-size: clamp(1.7rem, 3vw, 2.3rem);
  margin-top: 14px;
}

.split p {
  color: var(--ink-soft);
  margin-top: 16px;
  line-height: 1.6;
}

/* ---------- benefit cards ---------- */
.benefit-grid,
.cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
}

.benefit-card,
.card {
  background: var(--white);
  border-radius: 32px 32px 32px 8px;
  padding: 34px 28px;
  box-shadow: 0 14px 40px -22px rgba(10, 58, 84, 0.28);
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
  border-top: none;
}

.benefit-card:nth-child(2n),
.card:nth-child(2n) {
  border-radius: 32px 32px 8px 32px;
}

.benefit-card:hover,
.card:hover {
  transform: translateY(-6px);
  box-shadow: 0 22px 50px -20px rgba(10, 58, 84, 0.35);
}

.benefit-icon {
  width: 54px;
  height: 54px;
  border-radius: 63% 37% 54% 46% / 43% 47% 53% 57%;
  background: var(--blue-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  animation: blob-morph 9s ease-in-out infinite;
}

.benefit-card:nth-child(3n) .benefit-icon,
.card:nth-child(3n) .benefit-icon {
  background: rgba(23, 177, 143, 0.16);
  animation-delay: 1.5s;
}

.benefit-card:nth-child(4n) .benefit-icon,
.card:nth-child(4n) .benefit-icon {
  background: rgba(242, 166, 90, 0.22);
  animation-delay: 3s;
}

@keyframes blob-morph {
  0%, 100% { border-radius: 63% 37% 54% 46% / 43% 47% 53% 57%; }
  50% { border-radius: 40% 60% 62% 38% / 55% 40% 60% 45%; }
}

.benefit-icon svg {
  width: 26px;
  height: 26px;
  color: var(--deep);
}

.benefit-card h3,
.card h3 {
  font-size: 1.18rem;
  margin-bottom: 10px;
}

.benefit-card p,
.card p {
  color: var(--ink-soft);
  font-size: 0.95rem;
  line-height: 1.55;
}

/* ---------- CTA cards ---------- */
.split-cta {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 22px;
}

.cta-card {
  background: linear-gradient(160deg, var(--blue) 0%, var(--deep) 100%);
  color: var(--white);
  border-radius: 32px 32px 32px 8px;
  padding: clamp(36px, 4vw, 48px);
  position: relative;
  overflow: hidden;
}

.cta-card.alt {
  background: linear-gradient(160deg, var(--teal) 0%, var(--teal-dark) 100%);
  border-radius: 32px 32px 8px 32px;
}

.cta-card .eyebrow {
  color: var(--amber);
}

.cta-card .eyebrow::before {
  background: var(--amber);
  box-shadow: 0 0 0 4px rgba(242, 166, 90, 0.2);
}

.cta-card h3 {
  color: var(--white);
  font-size: clamp(1.3rem, 2vw, 1.6rem);
  margin: 14px 0;
}

.cta-card p {
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 26px;
  line-height: 1.6;
}

/* ---------- contact ---------- */
.contact-section {
  background: var(--deep);
  color: var(--white);
  text-align: center;
}

.contact-section .container {
  max-width: 620px;
  display: grid;
  gap: 20px;
  justify-items: center;
}

.contact-section .eyebrow {
  color: var(--amber);
}

.contact-section .eyebrow::before {
  background: var(--amber);
  box-shadow: 0 0 0 4px rgba(242, 166, 90, 0.2);
}

.contact-section h2 {
  color: var(--white);
  font-size: clamp(1.8rem, 3vw, 2.4rem);
}

.contact-section p {
  color: rgba(255, 255, 255, 0.75);
  line-height: 1.6;
}

/* ---------- signup panel (LP) ---------- */
.signup {
  padding: clamp(50px, 8vw, 90px) 0 clamp(70px, 10vw, 120px);
}

.signup-panel {
  background: var(--white);
  border-radius: 40px 40px 40px 10px;
  box-shadow: var(--shadow);
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  overflow: hidden;
  position: relative;
  z-index: 1;
}

.signup-aside {
  background: linear-gradient(160deg, var(--blue) 0%, var(--deep) 100%);
  color: var(--white);
  padding: clamp(36px, 4vw, 54px);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
}

.signup-aside .ripple-field .ripple {
  border-color: rgba(255, 255, 255, 0.22);
}

.signup-aside h1,
.signup-aside h2 {
  color: var(--white);
  font-size: clamp(1.5rem, 2.4vw, 1.9rem);
  position: relative;
  z-index: 1;
}

.signup-aside p {
  color: rgba(255, 255, 255, 0.82);
  margin-top: 14px;
  font-size: 0.98rem;
  line-height: 1.6;
  position: relative;
  z-index: 1;
  max-width: 38ch;
}

.aside-list {
  list-style: none;
  padding: 0;
  margin: 30px 0 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: relative;
  z-index: 1;
}

.aside-list li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 0.92rem;
  color: rgba(255, 255, 255, 0.9);
}

.aside-list svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  margin-top: 2px;
  color: var(--amber);
}

.signup-form-wrap {
  position: relative;
}

.signup-form,
.form-card {
  padding: clamp(32px, 4vw, 54px);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.field {
  margin-bottom: 18px;
}

.field label {
  display: block;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--deep);
  margin-bottom: 7px;
}

.field input,
.field select,
.field textarea,
.search-bar input {
  width: 100%;
  padding: 13px 16px;
  border-radius: 14px;
  border: 1.5px solid rgba(10, 58, 84, 0.15);
  background: var(--bg);
  font-family: var(--font-body);
  font-size: 0.96rem;
  color: var(--ink);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.field input:focus,
.field select:focus,
.field textarea:focus,
.search-bar input:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(28, 143, 196, 0.14);
}

.consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 6px 0 24px;
}

.consent input {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  accent-color: var(--teal);
  flex-shrink: 0;
}

.consent label {
  font-size: 0.85rem;
  color: var(--ink-soft);
  line-height: 1.5;
}

.form-foot {
  font-size: 0.78rem;
  color: var(--ink-soft);
  text-align: center;
  margin-top: 14px;
}

.form-status {
  margin-top: 18px;
  font-size: 0.9rem;
  padding: 14px 16px;
  border-radius: 14px;
  display: none;
}

.form-status.show {
  display: block;
}

.form-status.success {
  background: rgba(23, 177, 143, 0.14);
  color: var(--teal-dark);
}

.form-status.error {
  background: rgba(214, 69, 69, 0.12);
  color: #b03434;
}

.success-state {
  display: none;
  text-align: center;
  padding: 40px 10px;
}

.success-state.active {
  display: block;
}

.signup-form.hidden {
  display: none;
}

.success-icon {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: rgba(23, 177, 143, 0.14);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 22px;
}

.success-icon svg {
  width: 32px;
  height: 32px;
  color: var(--teal-dark);
}

.success-state h3 {
  font-size: 1.4rem;
  margin-bottom: 10px;
}

.success-state p {
  color: var(--ink-soft);
  max-width: 36ch;
  margin: 0 auto;
  line-height: 1.6;
}

/* ---------- LP pages ---------- */
.lp-hero {
  padding: clamp(40px, 6vw, 72px) 0 clamp(30px, 5vw, 48px);
  text-align: center;
  background: var(--bg);
  position: relative;
  overflow: hidden;
}

.lp-hero .container {
  max-width: 640px;
  position: relative;
  z-index: 1;
}

.lp-hero h1 {
  font-size: clamp(2rem, 4vw, 2.8rem);
  margin: 16px 0;
}

.lp-hero p {
  color: var(--ink-soft);
  font-size: 1.05rem;
  line-height: 1.6;
}

.lp-body {
  padding: 0 0 clamp(70px, 10vw, 100px);
  background: var(--bg);
}

.form-card {
  background: var(--white);
  border-radius: 32px;
  box-shadow: var(--shadow);
  max-width: 520px;
  margin-inline: auto;
}

/* ---------- search / map ---------- */
.search-bar {
  display: flex;
  gap: 12px;
  max-width: 560px;
  margin: 0 auto 48px;
}

.search-bar input {
  flex: 1;
  border-radius: 100px;
}

.results-layout {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 32px;
  align-items: start;
}

#map {
  height: 520px;
  border-radius: 32px 32px 32px 8px;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.results-list {
  display: grid;
  gap: 16px;
  max-height: 520px;
  overflow-y: auto;
  padding-right: 4px;
}

.piscineiro-card {
  background: var(--white);
  border-radius: 20px;
  padding: 22px 24px;
  box-shadow: 0 14px 40px -22px rgba(10, 58, 84, 0.28);
  border-left: 4px solid var(--teal);
  cursor: pointer;
  transition: border-color 0.15s ease, transform 0.2s var(--ease);
}

.piscineiro-card:hover,
.piscineiro-card.active {
  border-left-color: var(--blue);
  transform: translateX(4px);
}

.piscineiro-card h3 {
  font-size: 1.05rem;
  margin-bottom: 4px;
}

.piscineiro-card .empresa {
  color: var(--blue);
  font-size: 0.88rem;
  font-weight: 600;
  margin-bottom: 10px;
}

.piscineiro-card dl {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 10px;
  font-size: 0.85rem;
  color: var(--ink-soft);
}

.piscineiro-card dt {
  font-weight: 600;
  color: var(--deep);
}

.results-empty {
  text-align: center;
  color: var(--ink-soft);
  padding: 40px 0;
}

/* ---------- footer ---------- */
.site-footer {
  background: var(--deep);
  color: rgba(255, 255, 255, 0.65);
  padding: 50px 0 30px;
}

.footer-grid {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 30px;
  padding-bottom: 34px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.footer-brand {
  max-width: 320px;
}

.footer-brand img {
  height: 34px;
  margin-bottom: 14px;
  filter: brightness(0) invert(1);
}

.footer-brand p {
  font-size: 0.88rem;
  line-height: 1.6;
}

.footer-cols {
  display: flex;
  gap: 60px;
  flex-wrap: wrap;
}

.footer-col h4 {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.45);
  margin-bottom: 14px;
  font-family: var(--font-mono);
  font-weight: 400;
}

.footer-col a,
.footer-col li {
  display: block;
  font-size: 0.92rem;
  margin-bottom: 10px;
  color: rgba(255, 255, 255, 0.75);
  transition: color 0.2s;
}

.footer-col a:hover {
  color: var(--amber);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 22px;
  font-size: 0.8rem;
  flex-wrap: wrap;
  gap: 10px;
}

.footer-bottom a {
  color: rgba(255, 255, 255, 0.65);
}

.footer-bottom a:hover {
  color: var(--amber);
}

/* ---------- reveal animation ---------- */
.reveal {
  opacity: 1;
  transform: none;
}

.js .reveal:not(.is-visible) {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.js .reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  *, .reveal, .loop-ring-outer, .loop-ring-inner, .loop-drop, .benefit-icon, .ripple {
    animation: none !important;
    transition: none !important;
  }

  .js .reveal:not(.is-visible) {
    opacity: 1;
    transform: none;
  }
}

/* ---------- responsive ---------- */
@media (max-width: 980px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }

  .hero-visual {
    max-width: 340px;
    margin: 0 auto;
    order: -1;
  }

  .benefit-grid,
  .cards {
    grid-template-columns: repeat(2, 1fr);
  }

  .split,
  .split-cta,
  .results-layout,
  .signup-panel {
    grid-template-columns: 1fr;
  }

  .split.reverse .split-media {
    order: 0;
  }

  .signup-panel {
    border-radius: 28px;
  }

  .signup-aside {
    padding: 34px;
  }
}

@media (max-width: 860px) {
  .nav-links,
  .nav-actions .btn-ghost {
    display: none;
  }

  .nav-toggle {
    display: block;
  }

  .nav-links.is-open {
    display: flex;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--bg);
    padding: 20px 24px;
    gap: 16px;
    border-bottom: 1px solid rgba(10, 58, 84, 0.08);
    box-shadow: 0 12px 30px rgba(10, 58, 84, 0.1);
  }

  #map {
    height: 340px;
  }

  .results-list {
    max-height: none;
  }
}

@media (max-width: 640px) {
  .benefit-grid,
  .cards,
  .split-cta {
    grid-template-columns: 1fr;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    flex-direction: column;
  }
}
