/* Adam's Pool Service — ultra-premium single pager
   Deep water navy · aqua accent · warm sand · paper white
   Display: Fraunces · Body: Inter
   v1 */

:root {
  --ink: #071e29;
  --deep: #0b2d3d;
  --deeper: #06171f;
  --aqua: #6fd4cf;
  --aqua-deep: #2ba8a0;
  --sand: #efe7d7;
  --paper: #f7fafa;
  --body-text: #33454d;
  --muted: #6b8089;
  --max: 1100px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  font-weight: 400;
  font-size: 16px;
  color: var(--body-text);
  background: var(--paper);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection { background: rgba(111, 212, 207, 0.4); color: var(--ink); }
:focus-visible { outline: 2px solid var(--aqua-deep); outline-offset: 3px; border-radius: 2px; }

/* fine grain over everything */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
  opacity: 0.03;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------- Type ---------- */
.eyebrow {
  font-size: 0.76rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--aqua-deep);
  font-weight: 600;
  margin-bottom: 1.1rem;
}
.eyebrow.light { color: var(--aqua); }
.eyebrow::before {
  content: '';
  display: inline-block;
  width: 2.2rem;
  height: 1px;
  background: linear-gradient(90deg, var(--aqua-deep), var(--aqua));
  vertical-align: middle;
  margin-right: 0.75rem;
}

h2 {
  font-family: 'Fraunces', serif;
  font-weight: 400;
  font-size: clamp(2.1rem, 4.6vw, 3.3rem);
  letter-spacing: -0.01em;
  line-height: 1.12;
  color: var(--ink);
}
h2.light { color: #f2fbfa; }

h3 {
  font-family: 'Fraunces', serif;
  font-weight: 500;
  font-size: 1.22rem;
  letter-spacing: 0;
  margin-bottom: 0.5rem;
  color: var(--ink);
}

/* ---------- Reveals (JS-gated, motion-safe) ---------- */
html.js .reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 1s var(--ease), transform 1s var(--ease);
  transition-delay: var(--rd, 0s);
  will-change: opacity, transform;
}
html.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html.js .reveal { opacity: 1; transform: none; transition: none; }
}

/* ---------- Header (dark glass, always) ---------- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.05rem clamp(1.25rem, 5vw, 3.5rem);
  background: rgba(7, 30, 41, 0.55);
  backdrop-filter: blur(16px) saturate(1.2);
  -webkit-backdrop-filter: blur(16px) saturate(1.2);
  border-bottom: 1px solid rgba(111, 212, 207, 0.12);
  transition: padding 0.35s var(--ease), background 0.35s var(--ease), box-shadow 0.35s var(--ease);
}
.site-header.scrolled {
  padding-top: 0.65rem;
  padding-bottom: 0.65rem;
  background: rgba(7, 30, 41, 0.92);
  box-shadow: 0 12px 36px rgba(4, 16, 22, 0.35);
}
.brand { display: flex; align-items: center; gap: 0.6rem; text-decoration: none; }
.brand-ripple { width: 26px; height: 26px; }
.brand-ripple circle { fill: none; stroke: var(--aqua); stroke-width: 1.4; opacity: 0.9; }
.brand-ripple circle:nth-child(2) { opacity: 0.5; }
.brand-ripple circle:nth-child(3) { opacity: 0.25; }
.brand-mark {
  font-family: 'Inter', sans-serif; font-weight: 300;
  font-size: 0.95rem; letter-spacing: 0.22em; color: #f2fbfa;
}
.brand-mark b { font-weight: 600; }
.site-nav { display: flex; gap: clamp(0.9rem, 2.6vw, 2rem); align-items: center; }
.site-nav a {
  text-decoration: none; color: rgba(242, 251, 250, 0.85);
  font-size: 0.88rem; letter-spacing: 0.03em;
  transition: color 0.2s ease;
}
.site-nav a:not(.nav-cta) { position: relative; padding-bottom: 0.2rem; }
.site-nav a:not(.nav-cta)::after {
  content: '';
  position: absolute; left: 0; right: 0; bottom: 0;
  height: 1px; background: var(--aqua);
  transform: scaleX(0); transform-origin: left center;
  transition: transform 0.35s var(--ease);
}
.site-nav a:not(.nav-cta):hover::after { transform: scaleX(1); }
.site-nav a:hover { color: #fff; }
.nav-cta {
  background: var(--aqua); color: var(--ink) !important; border-radius: 999px;
  padding: 0.5rem 1.15rem; font-weight: 600;
  transition: box-shadow 0.25s ease, transform 0.25s ease;
}
.nav-cta:hover { box-shadow: 0 6px 20px rgba(111, 212, 207, 0.4); transform: translateY(-1px); }

/* ---------- Buttons ---------- */
.btn {
  position: relative;
  display: inline-block; text-decoration: none;
  font-size: 0.86rem; letter-spacing: 0.12em; text-transform: uppercase;
  font-weight: 600;
  padding: 0.95rem 2.3rem; border-radius: 999px;
  overflow: hidden;
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), background 0.3s ease, color 0.3s ease;
  cursor: pointer;
}
.btn-primary { background: linear-gradient(135deg, var(--aqua), #8fe3de); color: var(--ink); box-shadow: 0 6px 20px rgba(111, 212, 207, 0.3); }
.btn-primary::after {
  content: '';
  position: absolute; top: 0; bottom: 0; left: -60%;
  width: 40%;
  background: linear-gradient(100deg, transparent, rgba(255,255,255,0.55), transparent);
  transform: skewX(-18deg);
  transition: left 0.6s var(--ease);
  pointer-events: none;
}
.btn-primary:hover::after { left: 120%; }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 14px 34px rgba(111, 212, 207, 0.45); }
.btn-ghost { border: 1px solid rgba(242, 251, 250, 0.4); color: #f2fbfa; }
.btn-ghost:hover { border-color: var(--aqua); color: var(--aqua); transform: translateY(-2px); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  min-height: 92vh;
  display: flex;
  align-items: center;
  padding: 7rem clamp(1.5rem, 8vw, 7rem) 5rem;
  background:
    radial-gradient(ellipse at 80% 10%, rgba(43, 168, 160, 0.25), transparent 55%),
    radial-gradient(ellipse at 15% 90%, rgba(111, 212, 207, 0.12), transparent 50%),
    linear-gradient(170deg, var(--deeper) 0%, var(--ink) 45%, var(--deep) 100%);
}
/* slow caustic shimmer */
.hero-water {
  position: absolute; inset: 0; z-index: 0;
  background:
    radial-gradient(ellipse 60% 40% at 30% 20%, rgba(111,212,207,0.08), transparent),
    radial-gradient(ellipse 50% 35% at 75% 65%, rgba(111,212,207,0.07), transparent);
  pointer-events: none;
}
@media (prefers-reduced-motion: no-preference) {
  .hero-water { animation: caustics 18s ease-in-out infinite alternate; }
  @keyframes caustics {
    from { transform: translate(0, 0) scale(1); opacity: 0.9; }
    to   { transform: translate(-3%, 2%) scale(1.08); opacity: 1; }
  }
}
.hero-ripples {
  position: absolute;
  right: -8%; bottom: -22%;
  width: min(52vw, 640px); height: auto;
  z-index: 0;
  pointer-events: none;
}
.ripple-set circle { fill: none; stroke: var(--aqua); stroke-width: 1; opacity: 0.18; }
@media (prefers-reduced-motion: no-preference) {
  .ripple-set circle {
    transform-box: fill-box; transform-origin: center;
    animation: ripple 7s ease-out infinite;
  }
  .ripple-set circle:nth-child(2) { animation-delay: 1.4s; }
  .ripple-set circle:nth-child(3) { animation-delay: 2.8s; }
  .ripple-set circle:nth-child(4) { animation-delay: 4.2s; }
  @keyframes ripple {
    0%   { transform: scale(0.82); opacity: 0.32; }
    70%  { opacity: 0.12; }
    100% { transform: scale(1.12); opacity: 0; }
  }
}
.hero-inner { position: relative; z-index: 1; max-width: 720px; }
.hero-eyebrow {
  font-size: 0.78rem; letter-spacing: 0.3em; text-transform: uppercase;
  color: var(--aqua); font-weight: 600; margin-bottom: 1.6rem;
}
.hero-eyebrow::before {
  content: '';
  display: inline-block;
  width: 2.6rem; height: 1px;
  background: linear-gradient(90deg, var(--aqua-deep), var(--aqua));
  vertical-align: middle; margin-right: 0.9rem;
}
.hero-title {
  font-family: 'Fraunces', serif; font-weight: 300;
  font-size: clamp(2.7rem, 6.4vw, 5rem);
  letter-spacing: -0.015em; line-height: 1.06;
  color: #f2fbfa; margin: 0 0 1.7rem;
}
.hero-title em { font-style: italic; font-weight: 400; color: var(--aqua); }
.hero-tagline {
  font-size: clamp(1.02rem, 1.7vw, 1.16rem); font-weight: 300;
  color: rgba(242, 251, 250, 0.78);
  max-width: 46ch; line-height: 1.75; margin-bottom: 2.6rem;
}
.hero-ctas { display: flex; gap: 1rem; flex-wrap: wrap; }

/* hero entrance */
@media (prefers-reduced-motion: no-preference) {
  html.js .hero-inner > * {
    opacity: 0;
    transform: translateY(22px);
    animation: hero-rise 1.1s var(--ease) forwards;
  }
  html.js .hero-inner > :nth-child(1) { animation-delay: 0.1s; }
  html.js .hero-inner > :nth-child(2) { animation-delay: 0.25s; }
  html.js .hero-inner > :nth-child(3) { animation-delay: 0.45s; }
  html.js .hero-inner > :nth-child(4) { animation-delay: 0.62s; }
  @keyframes hero-rise { to { opacity: 1; transform: none; } }
}

/* ---------- Sections ---------- */
.section { max-width: var(--max); margin: 0 auto; padding: clamp(4.5rem, 10vw, 7.5rem) clamp(1.25rem, 5vw, 2rem); }
.section-head { text-align: center; margin-bottom: 3.2rem; }
.section-head h2::after {
  content: ''; display: block;
  width: 52px; height: 2px;
  background: linear-gradient(90deg, var(--aqua-deep), var(--aqua));
  margin: 1rem auto 0;
}
.section-sub { color: var(--muted); margin-top: 1rem; max-width: 44ch; margin-left: auto; margin-right: auto; }

/* ---------- Every visit ---------- */
.visit-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.6rem;
}
.visit-item {
  background: #fff;
  border: 1px solid rgba(7, 30, 41, 0.08);
  border-radius: 16px;
  padding: 2.1rem 1.9rem;
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease), border-color 0.35s ease;
}
.visit-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 48px rgba(7, 30, 41, 0.1);
  border-color: rgba(111, 212, 207, 0.5);
}
.v-icon { width: 38px; height: 38px; margin-bottom: 1rem; display: block; }
.v-icon path, .v-icon circle, .v-icon rect { fill: none; stroke: var(--aqua-deep); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.v-icon circle[r='2.5'], .v-icon circle[r='1.6'] { fill: var(--aqua-deep); stroke: none; }
.visit-item p { font-size: 0.94rem; line-height: 1.65; color: var(--body-text); }

/* ---------- Chemistry (dark band) ---------- */
.band-dark {
  background:
    radial-gradient(ellipse at 85% 15%, rgba(43, 168, 160, 0.18), transparent 50%),
    linear-gradient(165deg, var(--ink), var(--deep));
  color: rgba(242, 251, 250, 0.82);
}
.band-dark p { color: rgba(242, 251, 250, 0.78); }
.chem-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: clamp(2rem, 6vw, 5rem);
  align-items: center;
}
.chem-text h2 { margin-bottom: 1.4rem; }
.chem-text p { font-size: 1.02rem; line-height: 1.8; margin-bottom: 1rem; max-width: 50ch; font-weight: 300; }
.chem-card {
  background: rgba(242, 251, 250, 0.06);
  border: 1px solid rgba(111, 212, 207, 0.25);
  border-radius: 18px;
  padding: 2rem 1.9rem;
  backdrop-filter: blur(8px);
  box-shadow: 0 24px 60px rgba(4, 16, 22, 0.35);
}
.chem-card-label {
  font-size: 0.74rem; letter-spacing: 0.26em; text-transform: uppercase;
  color: var(--aqua) !important; font-weight: 600; margin-bottom: 1.3rem;
}
.chem-list { list-style: none; display: grid; gap: 0.95rem; }
.chem-list li {
  display: flex; justify-content: space-between; align-items: baseline;
  padding-bottom: 0.9rem;
  border-bottom: 1px solid rgba(111, 212, 207, 0.14);
}
.chem-list li:last-child { border-bottom: none; padding-bottom: 0; }
.chem-list span { color: #f2fbfa; font-weight: 500; font-size: 0.98rem; }
.chem-list i {
  font-style: normal; font-size: 0.78rem; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--aqua);
}

/* ---------- Swim-ready texts ---------- */
.texts-wrap {
  max-width: 620px;
  margin: 0 auto;
  display: grid;
  gap: 1.3rem;
}
.text-bubble {
  position: relative;
  background: linear-gradient(135deg, #e9f7f6, #f2fbfa);
  border: 1px solid rgba(43, 168, 160, 0.25);
  border-radius: 20px 20px 20px 6px;
  padding: 1.3rem 1.6rem 1.05rem;
  box-shadow: 0 12px 34px rgba(7, 30, 41, 0.07);
  max-width: 88%;
}
.text-bubble:nth-child(2) { margin-left: auto; border-radius: 20px 20px 6px 20px; }
.text-bubble p {
  font-size: 1.02rem; line-height: 1.6; color: var(--ink);
  font-family: 'Inter', sans-serif;
}
.bubble-meta {
  display: block; margin-top: 0.5rem;
  font-size: 0.72rem; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--aqua-deep); font-weight: 600;
}
.texts-note {
  text-align: center;
  margin: 2.8rem auto 0;
  max-width: 42ch;
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-size: clamp(1.25rem, 2.4vw, 1.6rem);
  line-height: 1.45;
  color: var(--aqua-deep);
}

/* ---------- About (sand band) ---------- */
.band-sand { background: linear-gradient(180deg, var(--paper), var(--sand)); }
.about-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: clamp(2rem, 6vw, 5rem);
  align-items: start;
}
.about-lead h2 { margin-bottom: 0; }
.about-text p { font-size: 1.02rem; line-height: 1.8; margin-bottom: 1rem; max-width: 54ch; }

/* ---------- Contact ---------- */
.contact-band { position: relative; overflow: hidden; }
.contact-ripples {
  position: absolute;
  left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  width: min(90vw, 900px); height: auto;
  pointer-events: none;
  opacity: 0.5;
}
.contact-inner { position: relative; text-align: center; }
.contact-inner .eyebrow::before { margin-right: 0.75rem; }
.contact-sub {
  max-width: 46ch;
  margin: 1.1rem auto 2.4rem;
  font-weight: 300;
  font-size: 1.05rem;
}
.contact-ctas { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* ---------- Footer ---------- */
.site-footer {
  text-align: center;
  padding: 3.5rem 1.5rem 2.6rem;
  background: var(--deeper);
  color: rgba(242, 251, 250, 0.6);
}
.footer-ripple { width: 30px; height: 30px; margin-bottom: 0.9rem; }
.footer-ripple circle { fill: none; stroke: var(--aqua); stroke-width: 1.2; opacity: 0.7; }
.footer-ripple circle:nth-child(2) { opacity: 0.4; }
.footer-ripple circle:nth-child(3) { opacity: 0.2; }
.footer-brand { font-size: 0.86rem; letter-spacing: 0.26em; color: #f2fbfa; font-weight: 500; margin-bottom: 0.4rem; }
.footer-tagline { font-family: 'Fraunces', serif; font-style: italic; font-size: 1rem; color: var(--aqua); margin-bottom: 1.2rem; }
.footer-legal { font-size: 0.76rem; letter-spacing: 0.04em; color: rgba(242, 251, 250, 0.45); }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .chem-grid { grid-template-columns: 1fr; }
  .about-grid { grid-template-columns: 1fr; gap: 1.5rem; }
}
@media (max-width: 640px) {
  .site-nav a:not(.nav-cta) { display: none; }
  .brand-mark { font-size: 0.82rem; letter-spacing: 0.16em; }
  .hero { padding-top: 6rem; }
  .hero-ctas .btn { width: 100%; text-align: center; }
  .text-bubble { max-width: 100%; }
}
