/* ===========================================================
   TOVILA — BOLD WATER LAYER (homepage)
   Plain CSS. No framework, no build step.
   Loaded after style.css; only adds new classes.
   =========================================================== */

:root {
  --glass: rgba(255, 255, 255, 0.08);
}

/* ------------------------- typography punch ------------------------- */
.mega {
  font-family: var(--display);
  font-weight: 700;
  line-height: 0.92;
  letter-spacing: -0.03em;
  font-size: clamp(2.9rem, 8.2vw, 7.2rem);
  margin: 0 0 0.5em;
  text-wrap: balance;
}
.mega em {
  font-style: normal;
  position: relative;
  display: inline-block;
}
.mega .liquid {
  background: linear-gradient(
    100deg,
    color-mix(in srgb, var(--home-tint) 50%, white) 0%,
    var(--home-tint) 30%,
    var(--paper) 55%,
    var(--home-tint) 80%,
    color-mix(in srgb, var(--home-tint) 50%, white) 100%
  );
  background-size: 280% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: liquid-flow 9s linear infinite;
}
@keyframes liquid-flow {
  to {
    background-position: 280% 0;
  }
}
.kicker {
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.24em;
  font-size: 0.7rem;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
}
.kicker::before {
  content: "";
  width: 34px;
  height: 1px;
  background: var(--home-tint);
  display: block;
  animation: kick 2.6s ease-in-out infinite;
}
@keyframes kick {
  0%,
  100% {
    transform: scaleX(1);
    opacity: 1;
  }
  50% {
    transform: scaleX(0.35);
    opacity: 0.5;
  }
}

/* ------------------------------ hero ------------------------------- */
.hero-x {
  position: relative;
  min-height: min(94vh, 900px);
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  background: var(--ink-2);
  color: var(--paper);
  isolation: isolate;
  padding: clamp(6rem, 12vw, 9rem) 0 clamp(3rem, 6vw, 5rem);
}
.hero-x .hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero-x .hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 60% 45%;
  transform: scale(1.08);
  will-change: transform;
  filter: saturate(1.05) contrast(1.05);
}
.hero-x .hero-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(
      120% 90% at 12% 100%,
      rgba(5, 9, 15, 0.95) 0%,
      rgba(5, 9, 15, 0.55) 45%,
      rgba(5, 9, 15, 0.1) 75%
    ),
    linear-gradient(
      180deg,
      rgba(5, 9, 15, 0.85) 0%,
      rgba(5, 9, 15, 0.15) 35%,
      rgba(5, 9, 15, 0.9) 100%
    );
}
#ripple-canvas {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  mix-blend-mode: screen;
  opacity: 0.85;
}
.hero-x .wrap {
  position: relative;
  z-index: 2;
}
.hero-x .lead {
  color: color-mix(in srgb, var(--home-tint) 25%, white);
  font-size: clamp(1.05rem, 1.5vw, 1.3rem);
  max-width: 52ch;
}
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.65fr);
  gap: clamp(1.5rem, 4vw, 3.5rem);
  align-items: end;
}
.hero-facts {
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
  border-left: 1px solid rgba(255, 255, 255, 0.18);
  padding-left: 1.4rem;
}
.hero-facts .fact .n {
  font-family: var(--display);
  font-size: clamp(1.9rem, 3.2vw, 2.9rem);
  line-height: 1;
  display: block;
  color: var(--paper);
}
.hero-facts .fact span.l {
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--home-tint) 50%, white);
}

/* liquid buttons */
.btn-liquid {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--body);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 1.05rem 1.9rem;
  border-radius: 999px;
  border: 0;
  cursor: pointer;
  background: var(--brand-red);
  color: var(--paper);
  text-decoration: none;
  box-shadow: 0 14px 34px -14px rgba(156, 34, 54, 0.8);
  transition:
    transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1),
    box-shadow 0.35s;
}
.btn-liquid::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(
    circle at var(--mx, 50%) var(--my, 50%),
    var(--red-bright) 0%,
    var(--brand-red) 60%
  );
  opacity: 0;
  transition: opacity 0.4s;
}
.btn-liquid:hover {
  transform: translateY(-3px);
  box-shadow: 0 22px 46px -16px rgba(199, 58, 76, 0.85);
}
.btn-liquid:hover::after {
  opacity: 1;
}
.btn-liquid .arw {
  transition: transform 0.35s;
}
.btn-liquid:hover .arw {
  transform: translateX(5px);
}
.btn-liquid.ghost-x {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.4);
  box-shadow: none;
  color: var(--paper);
}
.btn-liquid.ghost-x::after {
  background: radial-gradient(
    circle at var(--mx, 50%) var(--my, 50%),
    rgba(79, 159, 201, 0.9) 0%,
    rgba(14, 58, 95, 0.65) 70%
  );
}
.btn-liquid.ghost-x:hover {
  border-color: transparent;
  box-shadow: 0 18px 40px -18px rgba(79, 159, 201, 0.7);
}
.btn-row-x {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin: 1.8rem 0 2.4rem;
}

/* scroll cue */
.scroll-cue {
  position: absolute;
  left: 50%;
  bottom: 1.3rem;
  transform: translateX(-50%);
  z-index: 3;
  font-family: var(--mono);
  font-size: 0.58rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--home-tint) 50%, white);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}
.scroll-cue i {
  display: block;
  width: 1px;
  height: 44px;
  background: linear-gradient(color-mix(in srgb, var(--home-tint) 50%, white), transparent);
  position: relative;
  overflow: hidden;
}
.scroll-cue i::after {
  content: "";
  position: absolute;
  top: -44px;
  left: 0;
  width: 1px;
  height: 44px;
  background: var(--home-tint);
  animation: dropfall 2.2s cubic-bezier(0.5, 0, 0.5, 1) infinite;
}
@keyframes dropfall {
  to {
    top: 44px;
  }
}

/* --------------------------- ticker/marquee ------------------------ */
.ticker {
  background: var(--ink);
  color: color-mix(in srgb, var(--home-tint) 25%, white);
  overflow: hidden;
  border-block: 1px solid rgba(255, 255, 255, 0.08);
}
.ticker .track {
  display: flex;
  gap: 3rem;
  padding: 0.9rem 0;
  width: max-content;
  animation: marq 34s linear infinite;
}
.ticker span {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 0.9rem;
}
.ticker span::after {
  content: "◈";
  color: var(--home-tint);
}
.ticker:hover .track {
  animation-play-state: paused;
}
@keyframes marq {
  to {
    transform: translateX(-50%);
  }
}

/* ------------------------- interactive cards ----------------------- */
.deck {
  display: grid;
  gap: 1.1rem;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  margin-top: 2.4rem;
}
.wcard {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 0.4rem;
  min-height: 290px;
  padding: 1.5rem;
  border-radius: 20px;
  text-decoration: none;
  background: var(--ink);
  color: var(--paper);
  border: 1px solid rgba(255, 255, 255, 0.09);
  transition:
    transform 0.5s cubic-bezier(0.2, 0.8, 0.2, 1),
    box-shadow 0.5s;
}
.wcard:hover {
  transform: translateY(-8px);
  box-shadow: 0 30px 60px -28px rgba(8, 18, 38, 0.7);
}
.wcard .fill {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 0;
  z-index: -1;
  background: linear-gradient(180deg, rgba(79, 159, 201, 0.42), rgba(14, 58, 95, 0.85));
  transition: height 0.6s cubic-bezier(0.3, 0.9, 0.2, 1);
}
.wcard:hover .fill,
.wcard:focus-visible .fill {
  height: 100%;
}
.wcard .fill::before {
  content: "";
  position: absolute;
  top: -14px;
  left: 0;
  width: 200%;
  height: 28px;
  background:
    radial-gradient(50% 100% at 25% 100%, rgba(79, 159, 201, 0.9), transparent 70%),
    radial-gradient(50% 100% at 75% 100%, rgba(79, 159, 201, 0.9), transparent 70%);
  animation: surface 3.2s linear infinite;
}
@keyframes surface {
  to {
    transform: translateX(-50%);
  }
}
.wcard .num {
  font-family: var(--mono);
  font-size: 0.6rem;
  letter-spacing: 0.2em;
  color: var(--home-tint);
}
.wcard h3 {
  font-size: 1.28rem;
  margin: 0.2rem 0 0.3rem;
  color: var(--paper);
}
.wcard p {
  color: color-mix(in srgb, var(--home-tint) 40%, white);
  font-size: 0.92rem;
  margin: 0;
}
.wcard .go {
  margin-top: 0.9rem;
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--paper);
  opacity: 0.6;
  transition: opacity 0.3s;
}
.wcard:hover .go {
  opacity: 1;
}

/* ---------------------------- split media -------------------------- */
.duo {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: clamp(1.6rem, 4vw, 3.4rem);
  align-items: center;
}
.duo.flip > .media {
  order: -1;
}
.media {
  position: relative;
  border-radius: 22px;
  overflow: hidden;
  background: var(--ink-2);
}
.media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  aspect-ratio: 4/3;
  transition:
    transform 1.1s cubic-bezier(0.2, 0.8, 0.2, 1),
    filter 0.6s;
}
.media:hover img {
  transform: scale(1.06);
}
.media.tall img {
  aspect-ratio: 4/5;
}
.media .cap {
  position: absolute;
  left: 1rem;
  bottom: 1rem;
  right: 1rem;
  color: var(--paper);
  z-index: 2;
  font-family: var(--mono);
  font-size: 0.6rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  background: rgba(5, 9, 15, 0.55);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  padding: 0.5rem 0.9rem;
  width: max-content;
  max-width: 100%;
}
.media .caustic {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.45;
  mix-blend-mode: soft-light;
  background: repeating-linear-gradient(
    115deg,
    rgba(255, 255, 255, 0.5) 0 2px,
    transparent 2px 14px
  );
  animation: caustic 12s linear infinite;
}
@keyframes caustic {
  to {
    transform: translate3d(-14%, 6%, 0) rotate(2deg);
  }
}

/* --------------------------- stat counters ------------------------- */
.stats-x {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 1px;
  background: rgba(255, 255, 255, 0.14);
  border-radius: 18px;
  overflow: hidden;
}
.stats-x .s {
  background: var(--ink);
  padding: 1.6rem 1.4rem;
}
.stats-x .s .n {
  font-family: var(--display);
  font-size: clamp(2rem, 3.4vw, 3rem);
  line-height: 1;
  color: var(--paper);
  display: block;
}
.stats-x .s .n small {
  font-size: 0.5em;
  color: var(--home-tint);
}
.stats-x .s .l {
  font-family: var(--mono);
  font-size: 0.6rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--home-tint) 50%, white);
  display: block;
  margin-top: 0.5rem;
}

/* --------------------------- process rail -------------------------- */
.rail {
  position: relative;
  margin-top: 2.6rem;
  display: grid;
  gap: 1.4rem;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}
.rail::before {
  content: "";
  position: absolute;
  top: 22px;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--home-tint), rgba(79, 159, 201, 0.12));
}
.rail .step {
  position: relative;
  padding-top: 3.4rem;
}
.rail .step b {
  position: absolute;
  top: 0;
  left: 0;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--paper);
  border: 2px solid var(--home-tint);
  font-family: var(--mono);
  font-size: 0.8rem;
  color: var(--deep-blue);
  box-shadow: 0 0 0 0 rgba(79, 159, 201, 0.5);
}
.rail .step:hover b {
  animation: pulse-ring 1.4s ease-out infinite;
  background: var(--home-tint);
  color: var(--paper);
}
@keyframes pulse-ring {
  to {
    box-shadow: 0 0 0 16px rgba(79, 159, 201, 0);
  }
}
.rail .step h3 {
  font-size: 1.1rem;
  margin-bottom: 0.3rem;
}
.rail .step p {
  font-size: 0.92rem;
  color: var(--mist);
  margin: 0;
}

/* ----------------------------- reveals ----------------------------- */
.up {
  opacity: 0;
  transform: translateY(34px);
  transition:
    opacity 0.9s ease,
    transform 0.9s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.up.in {
  opacity: 1;
  transform: none;
}
.up.d1 {
  transition-delay: 0.09s;
}
.up.d2 {
  transition-delay: 0.18s;
}
.up.d3 {
  transition-delay: 0.27s;
}
.up.d4 {
  transition-delay: 0.36s;
}

/* --------------------- pointer ripple rings ------------------------ */
.wripple {
  position: fixed;
  z-index: 190;
  pointer-events: none;
  border-radius: 50%;
  border: 1.5px solid rgba(199, 58, 76, 0.65);
  box-shadow: 0 0 18px rgba(199, 58, 76, 0.25) inset;
  transform: translate(-50%, -50%) scale(0.2);
  opacity: 0.9;
  animation: wripple 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
}
.wripple.cool {
  border-color: rgba(79, 159, 201, 0.7);
  box-shadow: 0 0 18px rgba(79, 159, 201, 0.3) inset;
}
@keyframes wripple {
  to {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0;
  }
}

/* --------------------------- error / 404 --------------------------- */
.err {
  position: relative;
  min-height: 80vh;
  display: grid;
  place-items: center;
  background: var(--ink-2);
  color: var(--paper);
  overflow: hidden;
}
#err-canvas {
  position: absolute;
  inset: 0;
}
.err .wrap {
  position: relative;
  z-index: 2;
  text-align: center;
}

/* ----------------------------- responsive -------------------------- */
@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }
  .hero-facts {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 1.4rem;
    border-left: 0;
    padding-left: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.18);
    padding-top: 1.2rem;
  }
  .duo.flip > .media {
    order: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .mega .liquid {
    animation: none;
    background: none;
    -webkit-text-fill-color: color-mix(in srgb, var(--home-tint) 50%, white);
    color: color-mix(in srgb, var(--home-tint) 50%, white);
  }
  .up {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .ticker .track,
  .media .caustic,
  .scroll-cue i::after,
  .kicker::before {
    animation: none;
  }
  #ripple-canvas {
    display: none;
  }
  .wripple {
    display: none;
  }
  .wcard .fill {
    transition: none;
  }
}

/* --------- reconciling shared .step / anchor styles in new layout --------- */
.rail .step {
  border-top: 0;
}
.dark .rail .step p {
  color: color-mix(in srgb, var(--home-tint) 40%, white);
}
.dark .rail .step b {
  background: rgba(255, 255, 255, 0.06);
  color: color-mix(in srgb, var(--home-tint) 60%, white);
}
.dark .rail::before {
  background: linear-gradient(90deg, var(--home-tint), rgba(79, 159, 201, 0.1));
}
.anchor-big .n,
.anchor-small .n {
  display: block;
}
.dark .anchor-block {
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 20px;
  padding: 1.6rem;
}
.dark .anchor-small .n {
  color: var(--paper);
}
.section.pale {
  background: var(--pale);
}

.stats-x.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
@media (max-width: 640px) {
  .stats-x.three {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   ROUND 2 — hero slider, red/white carousel, water process
   ========================================================= */

/* ---------------------- hero image slider ---------------------- */
.hero-x .hero-media img {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition:
    opacity 1.6s ease,
    transform 9s linear;
}
.hero-x .hero-media img.on {
  opacity: 1;
  transform: scale(1.14);
}
.hero-dots {
  position: absolute;
  right: clamp(1rem, 4vw, 3rem);
  bottom: 1.6rem;
  z-index: 4;
  display: flex;
  gap: 0.55rem;
}
.hero-dots button {
  width: 34px;
  height: 3px;
  border: 0;
  padding: 0;
  cursor: pointer;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.3);
  position: relative;
  overflow: hidden;
}
.hero-dots button[aria-current="true"] {
  background: rgba(255, 255, 255, 0.35);
}
.hero-dots button[aria-current="true"]::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--red-bright);
  transform-origin: left;
  animation: dotfill 6s linear forwards;
}
@keyframes dotfill {
  from {
    transform: scaleX(0);
  }
  to {
    transform: scaleX(1);
  }
}

/* ------------------- start-here carousel (white/red) ------------------- */
.carousel {
  position: relative;
  margin-top: 2.2rem;
}
.carousel .rail-wrap {
  overflow: hidden;
  border-radius: 22px;
}
.carousel .track2 {
  display: flex;
  gap: 1.1rem;
  padding: 0.4rem;
  scroll-snap-type: x mandatory;
  overflow-x: auto;
  scroll-behavior: smooth;
  scrollbar-width: none;
}
.carousel .track2::-webkit-scrollbar {
  display: none;
}
.ccard {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  flex: 0 0 clamp(250px, 30%, 340px);
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 280px;
  padding: 1.5rem;
  border-radius: 20px;
  text-decoration: none;
  background: var(--paper);
  color: var(--ink);
  border: 1px solid var(--line-light);
  box-shadow: 0 18px 40px -30px rgba(8, 18, 38, 0.5);
  transition:
    transform 0.5s cubic-bezier(0.2, 0.8, 0.2, 1),
    box-shadow 0.5s,
    border-color 0.4s;
}
.ccard:hover,
.ccard:focus-visible {
  transform: translateY(-8px);
  border-color: rgba(156, 34, 54, 0.35);
  box-shadow: 0 30px 60px -32px rgba(156, 34, 54, 0.45);
}
.ccard .num {
  font-family: var(--mono);
  font-size: 0.6rem;
  letter-spacing: 0.2em;
  color: var(--brand-red);
}
.ccard h3 {
  font-size: 1.24rem;
  margin: 0.5rem 0 0.5rem;
  color: var(--ink);
}
.ccard .body {
  margin-top: auto;
}
.ccard p {
  font-size: 0.92rem;
  color: var(--mist);
  margin: 0;
}
.ccard .go {
  margin-top: 1rem;
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--brand-red);
}
/* waves flowing through the cards */
.ccard .waveset {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 120px;
  z-index: -1;
  overflow: hidden;
  opacity: 0.9;
}
.ccard .waveset span {
  position: absolute;
  bottom: -30px;
  left: 0;
  width: 280%;
  height: 120px;
  background: radial-gradient(60% 100% at 50% 100%, rgba(156, 34, 54, 0.16), transparent 70%);
  border-radius: 44% 56% 0 0/60% 60% 0 0;
  animation: wroll 9s linear infinite;
}
.ccard .waveset span:nth-child(2) {
  background: radial-gradient(60% 100% at 50% 100%, rgba(199, 58, 76, 0.14), transparent 70%);
  animation-duration: 13s;
  animation-direction: reverse;
  bottom: -46px;
}
.ccard .waveset span:nth-child(3) {
  background: radial-gradient(60% 100% at 50% 100%, rgba(8, 18, 38, 0.07), transparent 70%);
  animation-duration: 17s;
  bottom: -62px;
}
@keyframes wroll {
  to {
    transform: translateX(-64%);
  }
}
.ccard:hover .waveset span {
  animation-duration: 4.5s;
}
.ccard:hover .waveset {
  opacity: 1;
  height: 100%;
}
.ccard .waveset {
  transition:
    height 0.7s cubic-bezier(0.3, 0.9, 0.2, 1),
    opacity 0.5s;
}

.cnav {
  display: flex;
  gap: 0.6rem;
  margin-top: 1.3rem;
  align-items: center;
}
.cnav button {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid var(--line-light);
  background: var(--paper);
  cursor: pointer;
  color: var(--brand-red);
  font-size: 1.05rem;
  display: grid;
  place-items: center;
  transition:
    background 0.3s,
    color 0.3s,
    transform 0.3s,
    border-color 0.3s;
}
.cnav button:hover {
  background: var(--brand-red);
  color: var(--paper);
  border-color: var(--brand-red);
  transform: translateY(-2px);
}
.cnav .cbar {
  flex: 1;
  height: 2px;
  background: var(--line-light);
  position: relative;
  border-radius: 2px;
  overflow: hidden;
}
.cnav .cbar i {
  position: absolute;
  inset: 0 auto 0 0;
  width: 30%;
  background: var(--brand-red);
  border-radius: 2px;
  transition:
    transform 0.35s ease,
    width 0.35s ease;
}

/* ---------------- industrial section on white ---------------- */
.section.light-x {
  background: var(--paper);
}
.section.light-x .kicker {
  color: var(--brand-red);
}
.section.light-x .stats-x {
  background: var(--line-light);
}
.section.light-x .stats-x .s {
  background: var(--paper);
}
.section.light-x .stats-x .s .n {
  color: var(--ink);
}
.section.light-x .stats-x .s .l {
  color: var(--mist);
}
.section.light-x .btn-liquid.ghost-x {
  border-color: rgba(8, 18, 38, 0.25);
  color: var(--ink);
}
.section.light-x .btn-liquid.ghost-x:hover {
  color: var(--paper);
}

/* ------------------- water-themed process flow ------------------- */
.flow {
  position: relative;
  margin-top: 2.8rem;
  border-radius: 24px;
  overflow: hidden;
  background: linear-gradient(180deg, var(--pale), var(--paper));
  border: 1px solid var(--line-light);
}
.flow .pipe {
  position: absolute;
  left: 0;
  right: 0;
  top: 74px;
  height: 8px;
  background: rgba(8, 18, 38, 0.07);
  border-radius: 99px;
  overflow: hidden;
}
.flow .pipe i {
  position: absolute;
  inset: 0;
  width: 0;
  background: linear-gradient(
    90deg,
    var(--deep-blue),
    var(--home-tint) 60%,
    color-mix(in srgb, var(--home-tint) 50%, white)
  );
  transition: width 1.6s cubic-bezier(0.3, 0.9, 0.2, 1);
}
.flow.in .pipe i {
  width: 100%;
}
.flow .pipe::after {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    90deg,
    rgba(255, 255, 255, 0.55) 0 8px,
    transparent 8px 26px
  );
  animation: pipeflow 1.6s linear infinite;
}
@keyframes pipeflow {
  to {
    transform: translateX(-26px);
  }
}
.flow .steps {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
}
.flow .fstep {
  padding: 2.6rem 1.5rem 2.2rem;
  border-right: 1px solid var(--line-light);
  position: relative;
  background: transparent;
  transition: background 0.5s;
}
.flow .fstep:last-child {
  border-right: 0;
}
.flow .fstep:hover {
  background: rgba(79, 159, 201, 0.06);
}
.flow .drop {
  position: relative;
  width: 52px;
  height: 52px;
  margin-bottom: 1.1rem;
  display: grid;
  place-items: center;
  border-radius: 50% 50% 50% 50%/60% 60% 40% 40%;
  background: var(--paper);
  border: 2px solid var(--home-tint);
  font-family: var(--mono);
  font-size: 0.78rem;
  color: var(--deep-blue);
  transform: rotate(45deg);
}
.flow .drop span {
  transform: rotate(-45deg);
  display: block;
}
.flow .fstep:hover .drop {
  background: var(--home-tint);
  color: var(--paper);
  border-color: var(--deep-blue);
  animation: bob 1.6s ease-in-out infinite;
}
@keyframes bob {
  50% {
    transform: rotate(45deg) translateY(-6px);
  }
}
.flow .fstep h3 {
  font-size: 1.08rem;
  margin: 0 0 0.35rem;
}
.flow .fstep p {
  font-size: 0.92rem;
  color: var(--mist);
  margin: 0;
}
.flow .fstep .lvl {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 0;
  background: linear-gradient(180deg, rgba(79, 159, 201, 0.18), rgba(79, 159, 201, 0.32));
  z-index: -1;
  transition: height 0.7s cubic-bezier(0.3, 0.9, 0.2, 1);
}
.flow .fstep:hover .lvl {
  height: 100%;
}
@media (max-width: 820px) {
  .flow .steps {
    grid-template-columns: 1fr;
  }
  .flow .fstep {
    border-right: 0;
    border-bottom: 1px solid var(--line-light);
  }
  .flow .pipe {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-x .hero-media img {
    transition: none;
  }
  .ccard .waveset span,
  .flow .pipe::after,
  .hero-dots button[aria-current="true"]::after {
    animation: none;
  }
  .flow .pipe i {
    transition: none;
    width: 100%;
  }
}

/* =========================================================
   ROUND 3 — inner pages get the homepage design language
   ========================================================= */

/* ------------------- image banner (inner pages) ------------------- */
.banner-x {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  color: var(--paper);
  min-height: clamp(380px, 52vh, 560px);
  display: flex;
  align-items: flex-end;
  padding: clamp(4.5rem, 9vw, 7rem) 0 clamp(2.5rem, 5vw, 4rem);
  background: var(--ink);
}
.banner-x .bmedia {
  position: absolute;
  inset: 0;
  z-index: -2;
  overflow: hidden;
}
.banner-x .bmedia img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.06);
}
.banner-x .bmedia::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(
      90deg,
      rgba(5, 9, 15, 0.94) 0%,
      rgba(8, 18, 38, 0.78) 45%,
      rgba(8, 18, 38, 0.35) 100%
    ),
    linear-gradient(0deg, rgba(5, 9, 15, 0.85), transparent 62%);
}
.banner-x canvas {
  position: absolute;
  inset: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  pointer-events: none;
}
.banner-x .wrap {
  position: relative;
  z-index: 1;
  width: 100%;
}
.banner-x .kicker {
  color: var(--home-tint);
}
.banner-x.red .kicker {
  color: color-mix(in srgb, var(--brand-red) 40%, white);
}
.banner-x h1 {
  font-family: var(--display);
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: -0.02em;
  color: var(--paper);
  font-size: clamp(2.3rem, 5.6vw, 4.6rem);
  margin: 0.7rem 0 1rem;
  max-width: 20ch;
}
.banner-x h1 em {
  font-style: normal;
  background: linear-gradient(
    100deg,
    color-mix(in srgb, var(--home-tint) 50%, white),
    var(--home-tint) 45%,
    var(--deep-blue)
  );
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.banner-x.red h1 em {
  background: linear-gradient(
    100deg,
    color-mix(in srgb, var(--brand-red) 40%, white),
    var(--red-bright) 55%,
    var(--brand-red)
  );
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.banner-x .lead {
  color: rgba(255, 255, 255, 0.82);
  max-width: 62ch;
  font-size: 1.03rem;
}
.banner-x .bstats {
  display: flex;
  flex-wrap: wrap;
  gap: 1.6rem 2.6rem;
  margin-top: 1.8rem;
}
.banner-x .bstats div {
  border-left: 2px solid rgba(255, 255, 255, 0.24);
  padding-left: 0.9rem;
}
.banner-x .bstats .n {
  display: block;
  font-family: var(--display);
  font-size: 1.5rem;
}
.banner-x .bstats .l {
  font-family: var(--mono);
  font-size: 0.6rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.6);
}
@media (max-width: 640px) {
  .banner-x {
    min-height: auto;
    padding-top: 6rem;
  }
}

/* --------------- cards on inner pages: white + water ------------- */
.card {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: var(--paper);
  border-radius: 18px;
  transition:
    transform 0.5s cubic-bezier(0.2, 0.8, 0.2, 1),
    box-shadow 0.5s,
    border-color 0.4s;
}
.card::after {
  content: "";
  position: absolute;
  left: -20%;
  right: -20%;
  bottom: -70%;
  height: 150%;
  z-index: -1;
  border-radius: 45% 55% 0 0/60% 60% 0 0;
  background: radial-gradient(60% 100% at 50% 100%, rgba(79, 159, 201, 0.16), transparent 72%);
  transform: translateY(60%);
  transition: transform 0.75s cubic-bezier(0.3, 0.9, 0.2, 1);
}
.card:hover {
  transform: translateY(-6px);
  box-shadow: 0 28px 55px -34px rgba(8, 18, 38, 0.5);
}
.card:hover::after {
  transform: translateY(0);
}
.card.a-training::after,
.card.a-csr::after {
  background: radial-gradient(60% 100% at 50% 100%, rgba(199, 58, 76, 0.16), transparent 72%);
}
.card .icon {
  color: var(--brand-red);
}

/* section headings on inner pages */
main h2 {
  font-family: var(--display);
  letter-spacing: -0.015em;
}
.section > .wrap > h2 {
  font-size: clamp(1.7rem, 3.3vw, 2.7rem);
}

/* buttons: use the liquid style everywhere */
.btn {
  position: relative;
  overflow: hidden;
  isolation: isolate;
}
.btn::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  background: radial-gradient(
    circle at var(--lx, 50%) var(--ly, 50%),
    rgba(255, 255, 255, 0.28),
    transparent 60%
  );
  opacity: 0;
  transition: opacity 0.4s;
}
.btn:hover::after {
  opacity: 1;
}

/* pale sections stay cool-white, never brownish */
.section.pale {
  background: var(--pale);
}

@media (prefers-reduced-motion: reduce) {
  .card,
  .card::after {
    transition: none;
  }
}

/* training pathway diagram: scroll instead of overflow on small screens */
@media (max-width: 820px) {
  .steps {
    overflow-x: auto;
    scrollbar-width: none;
  }
  .steps::-webkit-scrollbar {
    display: none;
  }
  .steps > .step {
    min-width: 150px;
  }
}
