/* ===========================================================================
   The Texas Water cat.

   A character a twelve-year-old designed, and a site that follows her from the
   rain down to somebody's kitchen tap. The whole page is one descent: it starts
   in a dark abyss and surfaces into a bright kitchen, so the palette does the
   narrating and the copy can stay short.

   Everything here is honest about the water. The facts are the utilities' own
   published ones; nothing is rated, scored or graded by us.
   ========================================================================= */

:root {
  --abyss:   #04141f;
  --deep:    #072438;
  --mid:     #0c3d5c;
  --shallow: #16628c;
  --surface: #eaf6fb;
  --ink:     #0d2230;

  --aqua:    #5fd0f5;   /* her eyes */
  --cobalt:  #1a55d6;   /* her collar, her ribbon, her Texas */
  --rose:    #e4707f;   /* her nose */

  --bone:    #ffffff;
  --sans: "Nunito", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --display: "Baloo 2", var(--sans);
  --mono: ui-monospace, SFMono-Regular, Menlo, monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--abyss); color: var(--surface);
  font: 400 17px/1.6 var(--sans); -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; }
a { color: inherit; }
.wrap { width: min(1180px, 100% - 3rem); margin-inline: auto; }

h1, h2, h3 { font-family: var(--display); font-weight: 700; line-height: 1.06;
  letter-spacing: -.02em; text-wrap: balance; margin: 0; }

/* --- the bar ------------------------------------------------------------ */
.bar { position: fixed; inset: 0 0 auto 0; z-index: 40; display: flex;
  align-items: center; justify-content: space-between; gap: 1rem;
  padding: .85rem clamp(1rem, 3vw, 2rem);
  background: linear-gradient(180deg, rgba(4,20,31,.82), rgba(4,20,31,0));
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  transition: background .5s ease, color .5s ease; }
.bar.lit { background: linear-gradient(180deg, rgba(234,246,251,.92), rgba(234,246,251,0)); color: var(--ink); }
.mark { display: flex; align-items: center; gap: .6rem; font-family: var(--display);
  font-weight: 800; font-size: 1.06rem; letter-spacing: -.01em; text-decoration: none; }
.mark .tex { width: 22px; height: 22px; flex: none; }
.mark .tex path { fill: var(--cobalt); }
.bar .btn { font-size: .92rem; padding: .55rem 1.05rem; }

.btn { display: inline-block; font: 700 1rem/1 var(--sans); text-decoration: none;
  padding: .85rem 1.5rem; border-radius: 999px; border: 0; cursor: pointer;
  background: var(--cobalt); color: #fff;
  box-shadow: 0 6px 22px -8px rgba(26,85,214,.9);
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease; }
.btn:hover { transform: translateY(-2px); box-shadow: 0 12px 28px -10px rgba(26,85,214,1); }
.btn-ghost { background: transparent; color: inherit;
  box-shadow: inset 0 0 0 2px currentColor; }
.btn-ghost:hover { box-shadow: inset 0 0 0 2px currentColor; }

/* --- hero --------------------------------------------------------------- */
.hero { position: relative; z-index: 2; min-height: 100svh; display: grid; align-items: center;
  overflow: hidden; }
.hero-art { position: absolute; inset: 0; }
.hero-art img { width: 100%; height: 100%; object-fit: cover; object-position: 30% 50%;
  /* the cat is the point of the page, so she never sits under the headline:
     scaling from an anchor near the right edge walks a centred subject left,
     into the half of the frame the copy does not use */
  scale: var(--zoom, 1); translate: var(--shift, 0) 0; }
.hero-art:after { content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(4,20,31,.55) 0%, rgba(4,20,31,.1) 35%, rgba(4,20,31,.72) 78%, rgba(4,20,31,.92) 100%); }
.hero .wrap { position: relative; z-index: 2; display: grid; grid-template-columns: 1.18fr .82fr; }
.hero-copy { grid-column: 2; }
.hero h1 { font-size: clamp(2.4rem, 5.4vw, 4.2rem); }
.hero-copy { text-shadow: 0 1px 16px rgba(4,20,31,.6); }
.hero .lede { font-size: clamp(1.05rem, 1.5vw, 1.22rem); max-width: 30rem;
  color: rgba(234,246,251,.9); margin: 1.1rem 0 1.7rem; }
.eyebrow { font: 800 .72rem/1.4 var(--mono); letter-spacing: .24em; text-transform: uppercase;
  color: var(--aqua); margin: 0 0 .7rem; }
.scroll-cue { position: absolute; left: 50%; bottom: 1.6rem; z-index: 3; transform: translateX(-50%);
  font: 700 .7rem/1 var(--mono); letter-spacing: .2em; text-transform: uppercase;
  color: rgba(234,246,251,.6); display: grid; gap: .5rem; justify-items: center; }
.scroll-cue i { display: block; width: 1px; height: 30px;
  background: linear-gradient(180deg, rgba(234,246,251,.7), transparent);
  animation: sink 2.4s ease-in-out infinite; }
@keyframes sink { 0%,100% { opacity: .25; transform: translateY(-5px); } 50% { opacity: 1; transform: translateY(5px); } }

/* --- the descent -------------------------------------------------------- */
.dive { position: relative; }
.stage { position: fixed; inset: 0; z-index: 0; }
.stage figure { position: absolute; inset: 0; margin: 0; opacity: 0; transition: opacity 1s ease; }
.stage figure.on { opacity: 1; }
.stage img { width: 100%; height: 100%; object-fit: cover;
  transform: scale(1.09) translateY(var(--drift, 0px)); transition: transform .25s linear; }
.stage:after, .stage:before { content: ""; position: absolute; inset: 0; transition: background 1s ease, opacity 1s ease; }
.stage:after {
  background: linear-gradient(180deg, rgba(4,20,31,.55), rgba(4,20,31,.12) 32%, rgba(4,20,31,.72)); }
.stage.warm:after { background: linear-gradient(180deg, rgba(4,20,31,.3), rgba(4,20,31,.04) 30%, rgba(4,20,31,.55)); }
/* the copy side gets its own wash, so text never has to fight the cat */
.stage:before { z-index: 1; opacity: 1;
  background: linear-gradient(90deg, rgba(4,20,31,.95) 0%, rgba(4,20,31,.82) 26%, rgba(4,20,31,.45) 48%, rgba(4,20,31,0) 68%); }
.stage.sright:before {
  background: linear-gradient(270deg, rgba(4,20,31,.95) 0%, rgba(4,20,31,.82) 26%, rgba(4,20,31,.45) 48%, rgba(4,20,31,0) 68%); }

.scenes { position: relative; z-index: 2; }
.scene { min-height: 100svh; display: flex; align-items: center;
  padding: 0 clamp(1.25rem, 6vw, 5rem); }
.scene[data-side="right"] { justify-content: flex-end; }
.card { max-width: 33rem; opacity: 0; transform: translateY(30px);
  transition: opacity .8s ease, transform .8s cubic-bezier(.2,.7,.2,1);
  /* the daylight scenes are bright behind the copy; this keeps it legible
     without having to black the picture out */
  text-shadow: 0 1px 16px rgba(4,20,31,.6), 0 0 2px rgba(4,20,31,.45); }
.scene.on .card { opacity: 1; transform: none; }
.card .step { font: 800 .7rem/1.4 var(--mono); letter-spacing: .24em; text-transform: uppercase;
  color: var(--aqua); margin: 0 0 .75rem; }
.card h2 { font-size: clamp(1.9rem, 4.2vw, 3rem); margin: 0 0 .85rem; color: #fff; }
.card p { font-size: clamp(1rem, 1.6vw, 1.15rem); line-height: 1.6; margin: 0 0 1rem;
  color: rgba(234,246,251,.88); }
.card p:last-child { margin-bottom: 0; }
.card .aside { font-size: .95rem; color: rgba(234,246,251,.68);
  border-left: 2px solid var(--aqua); padding-left: .9rem; }
.card .aside a { color: var(--aqua); }

/* the depth gauge */
.gauge { position: fixed; right: clamp(.9rem, 2.6vw, 2rem); top: 50%; z-index: 6;
  transform: translateY(-50%); display: grid; gap: .5rem; justify-items: end;
  opacity: 0; transition: opacity .6s ease; }
.gauge b { font: 800 .62rem/1 var(--mono); letter-spacing: .16em; text-transform: uppercase;
  color: rgba(234,246,251,.45); margin-bottom: .2rem; transition: color .5s ease; }
.gauge i { display: block; width: 3px; height: 26px; border-radius: 2px;
  background: rgba(234,246,251,.22); transition: background .4s ease, height .4s ease; }
.gauge i.on { background: var(--aqua); height: 34px; }
.gauge.lit b { color: rgba(13,34,48,.5); }
.gauge.lit i { background: rgba(13,34,48,.2); }
.gauge.lit i.on { background: var(--cobalt); }

/* bubbles drifting up over the whole descent */
.bubbles { position: fixed; inset: 0; z-index: 1; pointer-events: none; }
.bubbles span { position: absolute; bottom: -8vh; border-radius: 50%;
  background: radial-gradient(circle at 32% 30%, rgba(255,255,255,.85), rgba(255,255,255,.22) 45%, rgba(255,255,255,.05) 70%);
  box-shadow: inset 0 0 6px rgba(255,255,255,.35);
  animation: rise linear infinite; }
@keyframes rise {
  0%   { transform: translate3d(0,0,0) scale(.7); opacity: 0; }
  12%  { opacity: .75; }
  88%  { opacity: .55; }
  100% { transform: translate3d(var(--sway, 14px), -118vh, 0) scale(1); opacity: 0; }
}

/* --- surfacing: the light half of the page ------------------------------ */
.surface { position: relative; z-index: 3; background: var(--surface); color: var(--ink); }
.surface:before { content: ""; position: absolute; inset: auto 0 100% 0; height: 22vh;
  background: linear-gradient(180deg, rgba(234,246,251,0), var(--surface)); pointer-events: none; }
.surface h2 { font-size: clamp(1.8rem, 3.6vw, 2.8rem); }
.sec { padding: clamp(3.5rem, 9vh, 6.5rem) 0; }

/* meet her */
.meet { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(1.5rem, 4vw, 3.5rem);
  align-items: center; }
.meet .sheet { border-radius: 20px; overflow: hidden; box-shadow: 0 24px 60px -30px rgba(13,34,48,.6); }
.traits { list-style: none; margin: 1.4rem 0 0; padding: 0; display: grid; gap: .55rem; }
.traits li { display: grid; grid-template-columns: 1.6rem 1fr; gap: .7rem; align-items: baseline;
  font-size: 1rem; }
.traits li:before { content: ""; width: 11px; height: 11px; border-radius: 3px;
  background: var(--cobalt); justify-self: center; transform: translateY(1px); }
.traits li:nth-child(2):before { background: var(--aqua); }
.traits li:nth-child(3):before { background: var(--rose); }
.traits li:nth-child(4):before { background: var(--ink); }
.traits li:nth-child(5):before { background: #fff; box-shadow: inset 0 0 0 2px rgba(13,34,48,.3); }
.traits li:nth-child(6):before { background: var(--cobalt); border-radius: 50%; }

.origin { display: grid; grid-template-columns: 320px 1fr; gap: clamp(1.25rem, 3vw, 2.5rem);
  align-items: center; margin-top: clamp(2rem, 5vh, 3.5rem);
  background: #fff; border-radius: 22px; padding: clamp(1.25rem, 3vw, 2rem);
  box-shadow: 0 20px 50px -34px rgba(13,34,48,.55); }
.origin img { border-radius: 14px; }
.origin .cap { font-size: .9rem; color: rgba(13,34,48,.62); margin-top: .75rem; }

/* name her */
.name-card { margin-top: clamp(2rem, 5vh, 3.5rem); background: var(--deep); color: var(--surface);
  border-radius: 22px; padding: clamp(1.5rem, 4vw, 2.6rem); display: grid;
  grid-template-columns: 1fr 1fr; gap: clamp(1.5rem, 4vw, 3rem); align-items: center; }
.name-card h2 { color: #fff; }
.name-card p { color: rgba(234,246,251,.82); margin: .8rem 0 0; }
.namebox { display: grid; gap: .7rem; }
.namebox .row { display: flex; gap: .6rem; }
.namebox input { flex: 1; font: 400 1rem/1 var(--sans); padding: .85rem 1rem;
  border-radius: 12px; border: 2px solid rgba(234,246,251,.25); background: rgba(255,255,255,.06);
  color: var(--surface); }
.namebox input::placeholder { color: rgba(234,246,251,.45); }
.namebox input:focus { outline: 0; border-color: var(--aqua); }
.namebox .said { font-size: .92rem; color: var(--aqua); min-height: 1.3em; }

/* the ask */
.ask { display: grid; grid-template-columns: .95fr 1.05fr; gap: clamp(1.5rem, 4vw, 3.5rem);
  align-items: center; }
.ask img { border-radius: 20px; }
form.lead { display: grid; gap: .8rem; background: #fff; border-radius: 22px;
  padding: clamp(1.25rem, 3vw, 2rem); box-shadow: 0 20px 50px -34px rgba(13,34,48,.55); }
form.lead .two { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; }
form.lead label { display: grid; gap: .3rem; font: 700 .82rem/1.3 var(--sans);
  color: rgba(13,34,48,.72); }
form.lead input, form.lead select, form.lead textarea {
  font: 400 1rem/1.35 var(--sans); padding: .75rem .9rem; border-radius: 12px;
  border: 2px solid rgba(13,34,48,.14); background: #fff; color: var(--ink); width: 100%; }
form.lead input:focus, form.lead select:focus, form.lead textarea:focus {
  outline: 0; border-color: var(--cobalt); }
form.lead textarea { min-height: 88px; resize: vertical; }
form.lead .note { font-size: .86rem; color: rgba(13,34,48,.6); margin: 0; }
form.lead .said { font-size: .95rem; font-weight: 700; min-height: 1.4em; }
form.lead .said.bad { color: #b3261e; }
form.lead .said.good { color: #0f7b4f; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* footer */
.foot { background: var(--abyss); color: rgba(234,246,251,.7); position: relative; z-index: 3;
  padding: clamp(2.5rem, 6vh, 4rem) 0; font-size: .95rem; }
.foot .wrap { display: flex; flex-wrap: wrap; gap: 1rem 2rem; justify-content: space-between; align-items: center; }
.foot a { color: var(--aqua); }
.foot .credit { font-size: .9rem; color: rgba(234,246,251,.55); max-width: 34rem; }

@media (max-width: 900px) {
  .hero .wrap { grid-template-columns: 1fr; }
  .hero-copy { grid-column: 1; }
  .hero-art img { object-position: 42% 40%; }
  .hero-art:after { background: linear-gradient(180deg, rgba(4,20,31,.35) 0%, rgba(4,20,31,.55) 45%, rgba(4,20,31,.95) 100%); }
  .hero .wrap { align-content: end; padding-bottom: 5rem; min-height: 100svh; }
  /* on a narrow screen there is no room beside the cat, so the copy sits
     underneath her and the wash comes up from the bottom instead of the side */
  .scene, .scene[data-side="right"] { justify-content: flex-start; align-items: flex-end;
    padding-bottom: clamp(2rem, 9vh, 5rem); }
  .card { max-width: none; }
  .stage:before, .stage.sright:before {
    background: linear-gradient(180deg, rgba(4,20,31,0) 26%, rgba(4,20,31,.72) 58%, rgba(4,20,31,.95) 100%); }
  .meet, .origin, .name-card, .ask { grid-template-columns: 1fr; }
  .gauge b { display: none; }
  .gauge { display: none; }
  form.lead .two { grid-template-columns: 1fr; }
}
@media (max-width: 520px) { .wrap { width: calc(100% - 2rem); } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .stage { position: static; }
  .stage figure { position: static; opacity: 1; height: 52vh; }
  .stage img { transform: none; }
  .stage:after, .bubbles, .scroll-cue i { display: none; }
  .scene { min-height: 0; padding: 2rem clamp(1.25rem, 6vw, 5rem); }
  .card { opacity: 1; transform: none; }
  .gauge { display: none; }
}

/* --- the customer half --------------------------------------------------
   What you get, how it runs, and the questions people actually ask before
   they fill a form in. Plain blocks on the light background; the artwork has
   done its job by the time anyone reaches these.
   --------------------------------------------------------------------- */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1rem, 2.4vw, 1.6rem);
  margin-top: clamp(1.8rem, 4vh, 2.8rem); }
.cards.four { grid-template-columns: repeat(4, 1fr); }
.cards article { background: #fff; border-radius: 18px; padding: clamp(1.1rem, 2.4vw, 1.6rem);
  box-shadow: 0 18px 44px -34px rgba(13,34,48,.5); }
.cards h3 { font-size: 1.16rem; margin: 0 0 .5rem; }
.cards p { margin: 0; font-size: .99rem; line-height: 1.55; color: rgba(13,34,48,.78); }
.cards .tex-chip { display: block; width: 20px; height: 20px; margin-bottom: .7rem; }
.cards .tex-chip path { fill: var(--cobalt); }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1rem, 2.4vw, 2rem);
  margin-top: clamp(1.8rem, 4vh, 2.8rem); counter-reset: step; }
.steps li { list-style: none; counter-increment: step; }
.steps li:before { content: counter(step); display: grid; place-items: center;
  width: 2.1rem; height: 2.1rem; border-radius: 50%; background: var(--cobalt); color: #fff;
  font: 800 1rem/1 var(--sans); margin-bottom: .8rem; }
.steps h3 { font-size: 1.1rem; margin: 0 0 .4rem; }
.steps p { margin: 0; font-size: .98rem; line-height: 1.55; color: rgba(13,34,48,.78); }

.qa { margin-top: clamp(1.6rem, 4vh, 2.6rem); display: grid; gap: 0; }
.qa details { border-top: 1px solid rgba(13,34,48,.14); }
.qa details:last-child { border-bottom: 1px solid rgba(13,34,48,.14); }
.qa summary { cursor: pointer; list-style: none; padding: 1.05rem 2.2rem 1.05rem 0;
  font: 700 1.06rem/1.35 var(--display); position: relative; }
.qa summary::-webkit-details-marker { display: none; }
.qa summary:after { content: ""; position: absolute; right: .5rem; top: 1.5rem;
  width: 9px; height: 9px; border-right: 2px solid var(--cobalt); border-bottom: 2px solid var(--cobalt);
  transform: rotate(45deg); transition: transform .2s ease; }
.qa details[open] summary:after { transform: rotate(-135deg); }
.qa .a { padding: 0 2.2rem 1.15rem 0; margin: 0; font-size: 1rem; line-height: 1.6;
  color: rgba(13,34,48,.78); max-width: 58ch; }

/* the character page, which customers only reach if they go looking */
.char-hero { padding: clamp(5rem, 12vh, 7rem) 0 clamp(2rem, 5vh, 3rem); background: var(--surface); color: var(--ink); position: relative; z-index: 3; }
.char-hero h1 { font-size: clamp(2.1rem, 4.6vw, 3.2rem); }
.char-hero p { font-size: 1.1rem; line-height: 1.6; max-width: 44rem; margin: 1rem 0 0; }
.back-link { font: 700 .88rem/1 var(--sans); text-decoration: none; color: var(--cobalt);
  display: inline-block; margin-bottom: 1.2rem; }

@media (max-width: 900px) {
  .cards, .cards.four, .steps { grid-template-columns: 1fr; }
}

/* the bar's own small nav, which only appears where there is room for it */
.barnav { display: flex; align-items: center; gap: clamp(.8rem, 2vw, 1.6rem); }
.barnav a:not(.btn) { text-decoration: none; font: 700 .9rem/1 var(--sans); opacity: .82; }
.barnav a:not(.btn):hover { opacity: 1; }
@media (max-width: 720px) { .barnav a:not(.btn) { display: none; } }
