/* DFW Pool Keepers — v2 visual identity
   Signature: sunlight-through-water (animated caustics) in the hero.
   Palette: deep pool water + clean tile white + one Texas-sun accent. */

:root {
  --ink: #0C2A36;
  --deep: #0C4257;
  --deep-2: #07303F;
  --deep-3: #052430;
  --aqua: #1391A8;
  --aqua-bright: #34C6DA;
  --aqua-glow: #6FE6F2;
  --tile: #EEF6F7;
  --tile-2: #E2F0F1;
  --paper: #FFFFFF;
  --sun: #FBB03B;
  --sun-deep: #ED9A12;
  --muted: #59757F;
  --line: rgba(12, 42, 54, 0.10);
  --line-2: rgba(12, 42, 54, 0.06);
  --shadow-sm: 0 2px 10px rgba(12, 42, 54, .06);
  --shadow: 0 18px 50px rgba(12, 42, 54, .14);
  --shadow-lg: 0 30px 70px rgba(7, 48, 63, .30);
  --radius: 18px;
  --maxw: 1140px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--ink); background: var(--paper); line-height: 1.62;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, .brand-name {
  font-family: "Bricolage Grotesque", -apple-system, "Segoe UI", sans-serif;
  font-weight: 700; line-height: 1.05; letter-spacing: -0.025em;
}
a { color: var(--aqua); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  font: inherit; font-weight: 700; cursor: pointer; border: 0; white-space: nowrap;
  padding: 14px 28px; border-radius: 999px;
  transition: transform .14s ease, box-shadow .14s ease, background .14s ease, color .14s ease;
}
.btn:hover { text-decoration: none; transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn:focus-visible { outline: 3px solid var(--aqua-glow); outline-offset: 2px; }
.btn-sun { background: linear-gradient(180deg, #FFC257, var(--sun)); color: #3A2600; box-shadow: 0 10px 24px rgba(251,176,59,.42); }
.btn-sun:hover { background: linear-gradient(180deg, var(--sun), var(--sun-deep)); box-shadow: 0 14px 30px rgba(251,176,59,.5); }
.btn-ghost { background: rgba(255,255,255,.06); color: var(--paper); border: 1.5px solid rgba(255,255,255,.45); }
.btn-ghost:hover { background: rgba(255,255,255,.16); }
.btn-deep { background: var(--deep); color: var(--paper); }
.btn-deep:hover { background: var(--deep-2); }
.btn-lg { padding: 17px 36px; font-size: 1.05rem; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 60;
  background: rgba(255,255,255,.86); backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--line-2);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.brand { display: flex; align-items: center; gap: 11px; }
.brand:hover { text-decoration: none; }
.brand-mark {
  width: 38px; height: 38px; border-radius: 11px; flex: none; position: relative; overflow: hidden;
  background: linear-gradient(155deg, var(--aqua-bright), var(--deep));
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.25), 0 4px 10px rgba(12,42,54,.2);
}
.brand-mark::before { /* water surface */
  content: ""; position: absolute; left: -20%; right: -20%; top: 52%; height: 60%;
  background: rgba(255,255,255,.9);
  border-radius: 45% 55% 0 0 / 100% 100% 0 0;
}
.brand-mark::after { /* sun dot */
  content: ""; position: absolute; top: 7px; right: 8px; width: 9px; height: 9px; border-radius: 50%;
  background: var(--sun); box-shadow: 0 0 8px rgba(251,176,59,.9);
}
.brand-name { font-size: 1.22rem; color: var(--deep); }
.brand-name span { color: var(--aqua); }
.nav { display: flex; align-items: center; gap: 24px; }
.nav a { color: var(--ink); font-weight: 600; font-size: .95rem; }
.nav a:not(.btn):hover { color: var(--aqua); text-decoration: none; }
.nav .tel { color: var(--deep); font-weight: 700; }
@media (max-width: 780px) { .nav a:not(.btn):not(.tel) { display: none; } .nav { gap: 14px; } }

/* ---------- Caustics (the signature) ---------- */
.water {
  background-color: var(--deep-2);
  background-image:
    radial-gradient(60% 50% at 20% 0%, rgba(52,198,218,.40), transparent 60%),
    radial-gradient(50% 60% at 95% 10%, rgba(111,230,242,.22), transparent 55%),
    linear-gradient(165deg, var(--deep) 0%, var(--deep-2) 55%, var(--deep-3) 100%);
  position: relative; overflow: hidden; color: var(--paper);
}
.water::before { /* moving light ripples */
  content: ""; position: absolute; inset: -40% -20%; pointer-events: none; opacity: .5;
  background:
    radial-gradient(40% 22% at 30% 30%, rgba(111,230,242,.35), transparent 60%),
    radial-gradient(34% 18% at 70% 55%, rgba(255,255,255,.18), transparent 60%),
    radial-gradient(28% 16% at 50% 80%, rgba(52,198,218,.3), transparent 60%);
  filter: blur(8px);
  animation: drift 16s ease-in-out infinite alternate;
}
@keyframes drift {
  0%   { transform: translate3d(-2%, -1%, 0) scale(1.02); }
  50%  { transform: translate3d(2%, 2%, 0) scale(1.06); }
  100% { transform: translate3d(-1%, 1%, 0) scale(1.03); }
}
/* smooth wave divider at the bottom of any .water section */
.water::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 90px; pointer-events: none;
  background: var(--paper);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 90' preserveAspectRatio='none'%3E%3Cpath d='M0,90 L0,46 C220,4 480,86 720,52 C960,18 1180,72 1440,40 L1440,90 Z' fill='%23000'/%3E%3C/svg%3E") bottom/100% 90px no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 90' preserveAspectRatio='none'%3E%3Cpath d='M0,90 L0,46 C220,4 480,86 720,52 C960,18 1180,72 1440,40 L1440,90 Z' fill='%23000'/%3E%3C/svg%3E") bottom/100% 90px no-repeat;
}
@media (prefers-reduced-motion: reduce) { .water::before { animation: none; } }

/* ---------- Hero ---------- */
.hero { /* extends .water in markup */ }
.hero .wrap { padding-top: 74px; padding-bottom: 124px; position: relative; z-index: 3; }
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 52px; align-items: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-weight: 700; letter-spacing: .16em; text-transform: uppercase;
  font-size: .72rem; color: var(--aqua-glow); margin-bottom: 18px;
}
.eyebrow::before { content: ""; width: 22px; height: 2px; background: var(--sun); border-radius: 2px; }
.hero h1 { font-size: clamp(2.4rem, 5.4vw, 3.85rem); margin-bottom: 20px; text-wrap: balance; }
.hero p.lead { font-size: 1.18rem; color: rgba(233,247,248,.86); max-width: 47ch; margin-bottom: 30px; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }
.hero-trust { margin-top: 30px; display: flex; gap: 14px 26px; flex-wrap: wrap; color: rgba(233,247,248,.72); font-size: .9rem; }
.hero-trust span { display: inline-flex; align-items: center; gap: 8px; }
.hero-trust span::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--aqua-bright); box-shadow: 0 0 8px var(--aqua-glow); }
.hero-trust b { color: var(--paper); font-weight: 700; }

/* frosted glass panel */
.hero-card {
  background: linear-gradient(180deg, rgba(255,255,255,.16), rgba(255,255,255,.05));
  border: 1px solid rgba(255,255,255,.22); border-radius: 22px; padding: 26px;
  box-shadow: var(--shadow-lg), inset 0 1px 0 rgba(255,255,255,.3);
  backdrop-filter: blur(8px);
}
.hero-card h3 { font-size: 1.1rem; margin-bottom: 16px; display: flex; align-items: center; gap: 9px; }
.hero-card h3 svg { width: 20px; height: 20px; color: var(--aqua-glow); }
.hero-card ul { list-style: none; }
.hero-card li { display: flex; gap: 11px; padding: 9px 0; color: rgba(245,252,253,.94); font-size: .98rem; align-items: flex-start; border-top: 1px solid rgba(255,255,255,.1); }
.hero-card li:first-of-type { border-top: 0; }
.hero-card li svg { width: 18px; height: 18px; flex: none; margin-top: 3px; color: var(--aqua-bright); }
@media (max-width: 880px) { .hero-grid { grid-template-columns: 1fr; gap: 34px; } .hero .wrap { padding-bottom: 110px; } }

/* ---------- Sections ---------- */
.section { padding: 84px 0; }
.section.tint { background: linear-gradient(180deg, var(--tile), var(--tile-2)); }
.section-head { max-width: 660px; margin-bottom: 46px; }
.section-head .eyebrow { color: var(--aqua); }
.section-head .eyebrow::before { background: var(--sun); }
.section-head h2 { font-size: clamp(1.8rem, 3.6vw, 2.6rem); margin-bottom: 14px; text-wrap: balance; }
.section-head p { color: var(--muted); font-size: 1.08rem; }

/* ---------- Service cards ---------- */
.cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.card {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px 24px; position: relative; overflow: hidden;
  transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease;
}
.card::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: linear-gradient(90deg, var(--aqua-bright), var(--aqua)); transform: scaleX(0); transform-origin: left; transition: transform .25s ease; }
.card:hover { transform: translateY(-5px); box-shadow: var(--shadow); border-color: transparent; }
.card:hover::before { transform: scaleX(1); }
.card .ic {
  width: 50px; height: 50px; border-radius: 14px; display: grid; place-items: center; margin-bottom: 18px;
  background: linear-gradient(160deg, var(--tile), var(--tile-2)); color: var(--aqua);
  box-shadow: inset 0 0 0 1px var(--line-2);
}
.card .ic svg { width: 26px; height: 26px; }
.card h3 { font-size: 1.16rem; margin-bottom: 9px; }
.card p { color: var(--muted); font-size: .95rem; margin-bottom: 16px; }
.card .price { font-weight: 700; color: var(--deep); font-size: 1.02rem; }
@media (max-width: 920px) { .cards { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 540px) { .cards { grid-template-columns: 1fr; } }

/* ---------- Why ---------- */
.why { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.why .item { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px 26px; }
.why .item .n { font-family: "Bricolage Grotesque"; font-size: .85rem; font-weight: 800; color: var(--aqua); letter-spacing: .08em; margin-bottom: 12px; }
.why .item h3 { font-size: 1.2rem; margin-bottom: 9px; color: var(--deep); }
.why .item p { color: var(--muted); }
@media (max-width: 800px) { .why { grid-template-columns: 1fr; } }

/* ---------- Areas ---------- */
.areas { display: flex; flex-wrap: wrap; gap: 12px; }
.areas a {
  background: var(--paper); border: 1px solid var(--line); border-radius: 999px;
  padding: 12px 22px; font-weight: 600; color: var(--deep);
  display: inline-flex; align-items: center; gap: 9px; transition: all .14s ease;
}
.areas a svg { width: 16px; height: 16px; color: var(--aqua); }
.areas a:hover { background: var(--deep); color: var(--paper); border-color: var(--deep); text-decoration: none; transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.areas a:hover svg { color: var(--aqua-glow); }

/* ---------- Booking funnel ---------- */
.booking { background: linear-gradient(180deg, var(--tile-2), #fff); }
.funnel {
  max-width: 740px; margin: 0 auto; background: var(--paper);
  border: 1px solid var(--line); border-radius: 24px; box-shadow: var(--shadow); overflow: hidden;
}
.funnel-top { padding: 26px 28px 0; }
.funnel-top .step-label { font-size: .8rem; color: var(--muted); font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.waterbar { height: 14px; border-radius: 999px; background: var(--tile-2); overflow: hidden; margin-top: 11px; box-shadow: inset 0 1px 3px rgba(12,42,54,.1); }
.waterfill {
  height: 100%; width: 20%; border-radius: 999px; position: relative;
  background: linear-gradient(90deg, var(--aqua), var(--aqua-bright));
  transition: width .5s cubic-bezier(.4,0,.2,1);
}
.waterfill::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, rgba(255,255,255,.5), transparent); background-size: 60px 100%; animation: shimmer 1.6s linear infinite; }
@keyframes shimmer { to { background-position: 120px 0; } }
.waterfill::after { content: ""; position: absolute; top: -2px; right: -5px; width: 12px; height: 18px; background: var(--aqua-bright); border-radius: 50%; filter: blur(1px); opacity: .8; animation: bob 1.8s ease-in-out infinite; }
@keyframes bob { 0%,100% { transform: translateY(0);} 50% { transform: translateY(-2px);} }
@media (prefers-reduced-motion: reduce) { .waterfill, .waterfill::before, .waterfill::after { animation: none; transition: none; } }

.funnel-body { padding: 26px 28px 8px; }
.fstep { display: none; }
.fstep.active { display: block; animation: fade .32s ease; }
@keyframes fade { from { opacity: 0; transform: translateY(8px);} to { opacity: 1; transform: none;} }
.fstep h3 { font-size: 1.4rem; margin-bottom: 6px; }
.fstep .hint { color: var(--muted); font-size: .96rem; margin-bottom: 20px; }

.choices { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.choice {
  border: 1.5px solid var(--line); border-radius: 14px; padding: 16px 18px; cursor: pointer; background: var(--paper);
  transition: border-color .12s ease, background .12s ease, transform .12s ease; display: flex; flex-direction: column; gap: 3px;
}
.choice:hover { border-color: var(--aqua); transform: translateY(-2px); }
.choice.sel { border-color: var(--aqua); background: rgba(52,198,218,.10); box-shadow: inset 0 0 0 1px var(--aqua); }
.choice .t { font-weight: 700; }
.choice .s { font-size: .85rem; color: var(--muted); }
.choice.sel .s { color: var(--aqua); }
@media (max-width: 540px) { .choices { grid-template-columns: 1fr; } }

.field { margin-bottom: 15px; }
.field label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: 7px; }
.field input, .field select {
  width: 100%; font: inherit; padding: 13px 15px; border: 1.5px solid var(--line); border-radius: 12px;
  background: var(--paper); color: var(--ink); transition: border-color .12s ease, box-shadow .12s ease;
}
.field input:focus, .field select:focus { outline: none; border-color: var(--aqua); box-shadow: 0 0 0 3px rgba(52,198,218,.22); }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 540px) { .row2 { grid-template-columns: 1fr; } }

.funnel-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 28px 28px; }
.link-back { background: none; border: 0; color: var(--muted); font: inherit; font-weight: 600; cursor: pointer; padding: 8px 4px; }
.link-back:hover { color: var(--ink); }
.link-back[hidden] { visibility: hidden; }
.err { color: #C0392B; font-size: .86rem; margin-top: 6px; min-height: 1em; }

.funnel-done { padding: 52px 30px; text-align: center; display: none; }
.funnel-done.active { display: block; animation: fade .4s ease; }
.funnel-done .big { width: 64px; height: 64px; margin: 0 auto 14px; border-radius: 50%; display: grid; place-items: center; background: linear-gradient(160deg, var(--aqua-bright), var(--aqua)); color: #fff; box-shadow: 0 10px 26px rgba(52,198,218,.4); }
.funnel-done .big svg { width: 32px; height: 32px; }
.funnel-done h3 { font-size: 1.55rem; margin: 4px 0 8px; }
.funnel-done p { color: var(--muted); max-width: 40ch; margin: 0 auto; }

/* ---------- FAQ ---------- */
.faq { max-width: 820px; }
.faq details { border: 1px solid var(--line); border-radius: 14px; padding: 4px 20px; margin-bottom: 12px; background: var(--paper); transition: box-shadow .14s ease; }
.faq details[open] { box-shadow: var(--shadow-sm); }
.faq summary { font-weight: 700; cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: 12px; padding: 16px 0; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--aqua); font-weight: 800; font-size: 1.3rem; line-height: 1; }
.faq details[open] summary::after { content: "\2013"; }
.faq p { color: var(--muted); padding-bottom: 18px; margin-top: -4px; }

/* ---------- City hero (extends .water) ---------- */
.cityhero { padding: 60px 0 104px; }
.cityhero .wrap { position: relative; z-index: 3; }
.breadcrumb { font-size: .85rem; color: rgba(233,247,248,.72); margin-bottom: 16px; }
.breadcrumb a { color: rgba(233,247,248,.9); }
.cityhero h1 { font-size: clamp(2.1rem, 4.6vw, 3.1rem); margin-bottom: 16px; text-wrap: balance; }
.cityhero p { color: rgba(233,247,248,.86); max-width: 62ch; font-size: 1.1rem; }

/* ---------- Prose ---------- */
.prose { max-width: 740px; }
.prose p { margin-bottom: 17px; color: #2C4753; font-size: 1.04rem; }
.prose h2 { font-size: 1.55rem; margin: 34px 0 12px; color: var(--deep); }
.prose a { font-weight: 600; }

/* ---------- Photo slots (drop in real pool photos) ---------- */
.shot {
  border-radius: var(--radius); overflow: hidden; position: relative; background: linear-gradient(160deg, var(--tile), var(--tile-2));
  aspect-ratio: 4 / 3; box-shadow: var(--shadow-sm); border: 1px solid var(--line);
}
.shot img { width: 100%; height: 100%; object-fit: cover; }
.shot.empty::after { content: "Your pool photo"; position: absolute; inset: 0; display: grid; place-items: center; color: var(--muted); font-size: .85rem; font-weight: 600; letter-spacing: .02em; }
.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
@media (max-width: 720px) { .gallery { grid-template-columns: 1fr 1fr; } }

/* ---------- Footer ---------- */
.site-footer { background: var(--deep-3); color: rgba(233,247,248,.78); padding: 60px 0 30px; }
.foot-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 34px; margin-bottom: 38px; }
.site-footer h4 { color: #fff; font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; margin-bottom: 15px; }
.site-footer a { color: rgba(233,247,248,.78); display: block; padding: 5px 0; }
.site-footer a:hover { color: var(--aqua-glow); }
.foot-brand .brand-name { color: #fff; }
.foot-brand p { margin-top: 12px; max-width: 38ch; font-size: .95rem; }
.foot-bottom { border-top: 1px solid rgba(255,255,255,.12); padding-top: 22px; font-size: .85rem; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

/* ---------- Cookie consent ---------- */
.cookie-bar {
  position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 90; max-width: 540px; margin: 0 auto;
  background: var(--deep); color: #fff; border-radius: 16px; padding: 16px 18px; box-shadow: var(--shadow-lg);
  display: flex; gap: 14px; align-items: center; justify-content: space-between; flex-wrap: wrap;
  border: 1px solid rgba(255,255,255,.12);
}
.cookie-bar p { font-size: .9rem; color: rgba(233,247,248,.9); margin: 0; flex: 1 1 230px; }
.cookie-actions { display: flex; gap: 8px; }
.cookie-bar .btn { padding: 9px 18px; font-size: .9rem; }
.cookie-decline { background: transparent; color: #fff; border: 1.5px solid rgba(255,255,255,.4); }
.cookie-decline:hover { background: rgba(255,255,255,.14); }
