/* ==========================================================
   Turning Point - section backgrounds + motion / effects
   (loaded after custom.css; remove this file to go back to plain look)
   ========================================================== */

/* ---------- Section backgrounds (each section gets a different, calm tone) ---------- */
.site-section { position: relative; }
.tp-bg-white { background: #fff; }
.tp-bg-grid { background: #fff; }   /* clean plain white (grid removed) */
.tp-bg-soft  { background: #f2f6fb; border-top: 1px solid rgba(5,37,74,.05); border-bottom: 1px solid rgba(5,37,74,.05); }
.tp-bg-steel { background: #e5ecf5; border-top: 1px solid rgba(5,37,74,.05); border-bottom: 1px solid rgba(5,37,74,.05); }
.tp-bg-sky   { background: linear-gradient(135deg, #e3eefb 0%, #f6f9fd 55%, #ffffff 100%); }

/* dark band: soft navy glow, slowly turning gears, cursor spotlight */
.tp-band {
  position: relative; overflow: hidden;
  background:
    radial-gradient(520px circle at var(--mx, 75%) var(--my, 0%), rgba(93,180,255,.16), transparent 60%),
    radial-gradient(circle at 12% 0%, #0b3a73 0%, var(--tp-navy) 55%, var(--tp-navy-dark) 100%);
}
.tp-band > .container { position: relative; z-index: 1; }
.tp-band:before, .tp-band:after {
  content: ""; position: absolute; pointer-events: none; opacity: .07;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'%3E%3Ccircle cx='100' cy='100' r='70' fill='none' stroke='white' stroke-width='22' stroke-dasharray='9.17 9.17'/%3E%3Ccircle cx='100' cy='100' r='58' fill='none' stroke='white' stroke-width='10'/%3E%3Ccircle cx='100' cy='100' r='22' fill='none' stroke='white' stroke-width='8'/%3E%3C/svg%3E") center / contain no-repeat;
}
.tp-band:before { right: -150px; top: -150px; width: 540px; height: 540px; animation: tpSpin 70s linear infinite; }
.tp-band:after  { left: -100px; bottom: -120px; width: 340px; height: 340px; animation: tpSpin 45s linear infinite reverse; }
@keyframes tpSpin { to { transform: rotate(360deg); } }

/* ---------- Inner-page hero banner (same image on all pages, shown in full) ---------- */
.site-blocks-cover.inner-page.tp-page-hero {
  position: relative; overflow: hidden;
  height: clamp(260px, 23vw, 440px); min-height: 0;
  background-size: cover; background-position: center; background-repeat: no-repeat;
  border-bottom: 4px solid var(--tp-blue);
  animation: tpHeroIn 1.4s ease-out both;
}
.site-blocks-cover.inner-page.tp-page-hero .row { height: 100%; min-height: 0; }
.site-blocks-cover.inner-page.tp-page-hero .container { position: relative; z-index: 2; }
.site-blocks-cover.inner-page.tp-page-hero h1 { font-size: clamp(1.9rem, 3.5vw, 3.1rem); text-shadow: 0 3px 18px rgba(3,26,53,.6); }
.site-blocks-cover.inner-page.tp-page-hero .tp-lead { text-shadow: 0 2px 10px rgba(3,26,53,.6); }
.site-blocks-cover.tp-page-hero.overlay:before {
  background: linear-gradient(180deg, rgba(5,37,74,.62) 0%, rgba(5,37,74,.48) 50%, rgba(5,37,74,.68) 100%);
}
.tp-page-hero:after {                /* light sweep passing over the banner */
  content: ""; position: absolute; top: 0; bottom: 0; left: -45%; width: 35%; z-index: 1; pointer-events: none;
  background: linear-gradient(100deg, transparent, rgba(255,255,255,.14), transparent); transform: skewX(-20deg);
  animation: tpSweep 7s ease-in-out 1.6s infinite;
}
@keyframes tpSweep { 0% { left: -45%; } 55%, 100% { left: 125%; } }
@keyframes tpHeroIn { from { filter: brightness(1.7) saturate(.5); } to { filter: none; } }
@keyframes tpUp { from { opacity: 0; transform: translateY(26px); } to { opacity: 1; transform: none; } }
.tp-page-hero .tp-eyebrow { animation: tpUp .8s .15s both; }
.tp-page-hero h1          { animation: tpUp .9s .30s both; }
.tp-page-hero .tp-lead    { animation: tpUp .9s .50s both; }
.tp-page-hero h1 strong {
  background: linear-gradient(90deg, #5db4ff, #d4ecff, #5db4ff); background-size: 200% 100%;
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent;
  animation: tpShine 4.5s linear infinite; text-shadow: none;
}
@keyframes tpShine { to { background-position: -200% 0; } }

/* ---------- Section headings ---------- */
.aos-animate .tp-rule { animation: tpRule .9s .3s cubic-bezier(.2,.8,.2,1) both; transform-origin: center; }
.aos-animate .tp-rule.left { transform-origin: left; }
@keyframes tpRule { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.tp-kicker { position: relative; }

/* ---------- Cards, icons, steps ---------- */
.tp-card, .tp-prod, .tp-step, .tp-person, .tp-ind { will-change: transform; }
.tp-card { transition: transform .25s ease, box-shadow .35s; }
.tp-card .tp-icon { transition: transform .45s cubic-bezier(.3,1.6,.5,1); }
.tp-card:hover .tp-icon { transform: translateY(-4px) scale(1.15) rotate(-6deg); }
.tp-step, .tp-person { transition: transform .25s ease, box-shadow .35s, border-color .3s; }
.tp-step:hover, .tp-person:hover { box-shadow: 0 18px 40px rgba(5,37,74,.12); border-color: var(--tp-blue); }
.tp-step b { transition: transform .5s cubic-bezier(.3,1.6,.5,1), background .3s; }
.tp-step:hover b { transform: translateX(-50%) rotate(360deg) scale(1.1); }
.tp-ind:hover { transform: translateY(-6px); box-shadow: 0 16px 34px rgba(0,0,0,.25); }
.tp-ind:hover .tp-num { transform: scale(1.12); }
.tp-ind .tp-num { display: block; transition: transform .35s, color .3s; }

/* ---------- Buttons ---------- */
.btn { position: relative; overflow: hidden; transition: transform .25s, box-shadow .25s, background .25s, color .25s, border-color .25s; }
.btn:before {
  content: ""; position: absolute; top: 0; left: -80%; width: 50%; height: 100%; pointer-events: none;
  background: linear-gradient(100deg, transparent, rgba(255,255,255,.4), transparent); transform: skewX(-20deg); transition: left .7s;
}
.btn:hover:before { left: 140%; }
.btn:hover { transform: translateY(-3px); box-shadow: 0 12px 24px rgba(11,120,212,.28); }

/* ---------- Navigation: sliding underline ---------- */
.site-navbar .site-navigation .site-menu > li > a { position: relative; }
.site-navbar .site-navigation .site-menu > li:not(.active):not(.tp-cta) > a:after {
  content: ""; position: absolute; left: 50%; bottom: 4px; width: 0; height: 2px; background: var(--tp-blue);
  transform: translateX(-50%); transition: width .3s ease;
}
.site-navbar .site-navigation .site-menu > li:not(.active):not(.tp-cta) > a:hover:after { width: 60%; }

/* ---------- Story image (home / about): curtain reveal + floating badge ---------- */
.aos-animate .tp-story-row .tp-frame .tp-img-main { animation: tpReveal 1.2s cubic-bezier(.77,0,.18,1) both; }
@keyframes tpReveal { from { clip-path: inset(0 100% 0 0); transform: scale(1.18); } to { clip-path: inset(0 0 0 0); transform: scale(1); } }
.aos-animate .tp-story-row .tp-frame:before { animation: tpGrowFrame 1s .5s ease-out both; }
@keyframes tpGrowFrame { from { opacity: 0; transform: translate(14px, -14px) scale(.6); } to { opacity: 1; transform: none; } }
.tp-badge { animation: tpBob 4s ease-in-out infinite; }
@keyframes tpBob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-7px); } }
.tp-story-stats > div { transition: background .3s; }
.tp-story-stats > div:hover { background: rgba(255,255,255,.08); }
.tp-story-stats b { transition: transform .3s; }
.tp-story-stats > div:hover b { transform: scale(1.12); }

/* ---------- Floating call / WhatsApp pulse ---------- */
.tp-float { position: fixed; }
.tp-float:after { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--tp-blue); animation: tpPulse 2.2s ease-out infinite; pointer-events: none; }
.tp-float-wa:after { border-color: #25d366; }
@keyframes tpPulse { 0% { transform: scale(1); opacity: .8; } 100% { transform: scale(1.7); opacity: 0; } }

/* ---------- Scroll progress bar ---------- */
.tp-progress { position: fixed; top: 0; left: 0; height: 3px; width: 0; z-index: 99999; background: linear-gradient(90deg, var(--tp-blue), #5db4ff); box-shadow: 0 0 10px rgba(93,180,255,.7); }

/* ---------- Respect "reduce motion" ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *:before, *:after { animation: none !important; transition: none !important; }
}

/* narrow card text reads better left-aligned (justify makes big gaps in small boxes) */
.site-section .tp-card p, .site-section .tp-step p, .site-section .tp-prod p, .site-section .tp-svc-row p,
.site-section .tp-person p, .site-section .tp-mv p { text-align: left; hyphens: none; -webkit-hyphens: none; }
.tp-mv p { text-align: left; }
.site-blocks-cover.inner-page.tp-page-hero .tp-eyebrow { margin-bottom: 1rem; }

/* ---------- Bigger section headings on all pages ---------- */
.tp-kicker { font-size: 1.05rem; letter-spacing: .26em; margin-bottom: .6rem; }
.display-4.tp-title { font-size: clamp(2.2rem, 4.2vw, 3.45rem); line-height: 1.18; }
.tp-h3 { font-size: clamp(1.8rem, 3vw, 2.5rem); }
.tp-rule { width: 84px; height: 4px; margin-top: 1.4rem; }
.site-section .row.mb-5 .text-center > p, .site-section .row.mb-5 > .text-center p { font-size: 1.2rem; }

/* ---------- Service detail pages: one consistent text style ---------- */
.tp-prose p, .tp-prose p.lead, .tp-prose li { font-size: 1.08rem; font-weight: 400; line-height: 1.85; color: #4a5568; }
.site-section .tp-prose p, .site-section .tp-prose p.lead { text-align: justify; text-align-last: left; hyphens: none; -webkit-hyphens: none; margin-bottom: 1.2rem; }
.tp-prose .tp-sub { font-size: 1.45rem; font-weight: 700; margin: 2.4rem 0 1.1rem; }
.tp-prose .site-block-check li { margin-bottom: .35rem; }
.tp-prose a { color: var(--tp-blue); font-weight: 500; }
.tp-prose .tp-mini b { font-size: 1.35rem; } .tp-prose .tp-mini span { font-size: .85rem; }

/* centre the banner text vertically and horizontally */
.site-blocks-cover.inner-page.tp-page-hero .container { height: 100%; }
.site-blocks-cover.inner-page.tp-page-hero .row { height: 100%; min-height: 0; margin: 0; padding: 0; align-items: center; justify-content: center; }
.site-blocks-cover.inner-page.tp-page-hero .row > [class*="col-"] { display: flex; flex-direction: column; align-items: center; justify-content: center; }
.site-blocks-cover.inner-page.tp-page-hero h1 { margin: 0 0 .6rem; }
.site-blocks-cover.inner-page.tp-page-hero .tp-lead { margin: 0; }

/* ==========================================================
   Paragraphs: justified, with automatic hyphenation so there are
   no big gaps between words. Last line stays left-aligned.
   Centred text (section intros etc.) is left untouched.
   ========================================================== */
body .site-section:not(.tp-band) :not(.text-center) > p:not(.text-center) {
  text-align: justify;
  text-align-last: left;
  text-justify: inter-word;
  word-spacing: normal;
  -webkit-hyphens: auto; hyphens: auto;
  hyphenate-limit-chars: 9 4 4;
  overflow-wrap: break-word;
}

/* narrow cards: justified too - slightly tighter padding + smaller text and hyphenation keep word gaps small */
body .site-section :is(.tp-infra-card, .tp-prod, .tp-step) p {
  text-align: justify !important; text-align-last: left !important;
  -webkit-hyphens: auto !important; hyphens: auto !important;
  hyphenate-limit-chars: 6 2 3;
  font-size: .95rem !important; line-height: 1.7 !important;
}
.tp-infra-card { padding-left: 1.35rem; padding-right: 1.25rem; }
.tp-card.tp-prod { padding-left: 1.35rem; padding-right: 1.25rem; }
.tp-infra { padding-left: 1.35rem; padding-right: 1.25rem; }

/* ---------- Infrastructure "Machines" section: light (white) background ---------- */
.tp-band.tp-band-light {
  background: #fff; background-image: none; color: #4a5568;
  border-bottom: 0;
}
.tp-band.tp-band-light h2, .tp-band.tp-band-light h3 { color: var(--tp-navy); }
.tp-band.tp-band-light .tp-kicker { color: var(--tp-blue); }
.tp-band.tp-band-light .text-center p { color: #4a5568; }
.tp-band.tp-band-light .tp-infra-card {
  background: #fff; border: 1px solid #e3e8ef; border-top: 3px solid var(--tp-blue);
  box-shadow: 0 8px 24px rgba(5,37,74,.07);
}
.tp-band.tp-band-light .tp-infra-card:hover { border-top-color: var(--tp-navy); box-shadow: 0 18px 38px rgba(5,37,74,.14); }
.tp-band.tp-band-light .tp-infra-card .tp-abbr { color: var(--tp-blue); }
.tp-band.tp-band-light .tp-infra-card .tp-abbr:after { background: var(--tp-navy); }
.tp-band.tp-band-light .tp-infra-card h3 { color: var(--tp-navy); }
.tp-band.tp-band-light .tp-infra-card p { color: #4a5568; }

/* section right after the light Machines band: clearly tinted so the two don't blend */
.tp-band-light + .tp-bg-soft { background: #e8f0f9; border-top: 1px solid rgba(5,37,74,.08); }

/* ---------- Machines band: blueprint grid + blue gears + numbered cards ---------- */
.tp-band.tp-band-light { background: #fff; background-image: none; }
.tp-band.tp-band-light:before, .tp-band.tp-band-light:after { display: none !important; content: none !important; animation: none !important; }
.tp-band.tp-band-light .row { counter-reset: tpinfra; }
.tp-band.tp-band-light .tp-infra-card { counter-increment: tpinfra; overflow: hidden; padding-top: 2.4rem; }
.tp-band.tp-band-light .tp-infra-card:before {
  content: "0" counter(tpinfra);
  position: absolute; right: 1rem; top: .35rem;
  font-size: 4.2rem; font-weight: 900; line-height: 1; color: rgba(11,120,212,.09);
  pointer-events: none;
}
.tp-band.tp-band-light .tp-infra-card:after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 4px; width: 0;
  background: linear-gradient(90deg, var(--tp-blue), #5db4ff); transition: width .4s ease;
}
.tp-band.tp-band-light .tp-infra-card:hover:after { width: 100%; }
.tp-band.tp-band-light .tp-infra-card .tp-abbr { position: relative; }
body .tp-band-light .tp-infra-card p {
  text-align: left !important; -webkit-hyphens: none !important; hyphens: none !important;
}
.tp-band.tp-band-light .tp-rule { background: linear-gradient(90deg, var(--tp-blue), #5db4ff); }

/* alternate backgrounds on infrastructure: white / tint / white */
.tp-bg-white { background: #fff; }

/* footer contact: icon column + aligned text (address, phone, email) */
.tp-faddr li:not(:first-child) { display: flex; align-items: flex-start; }
.tp-faddr .tp-fi {
  flex: 0 0 34px; width: 34px; height: 34px; margin-right: .7rem; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  background: rgba(93,180,255,.14); color: #5db4ff; font-size: 1rem;
}
.tp-faddr li > span:not(.tp-fi), .tp-faddr li > a { padding-top: .3rem; line-height: 1.55; }
.tp-faddr li > span:not(.tp-fi) { white-space: normal; }

/* footer: 4 columns spread evenly across the full container width */
@media (min-width: 992px) {
  .site-footer > .container > .row {
    display: grid; grid-template-columns: 1.25fr .7fr 1.55fr 1.5fr; column-gap: 2rem; margin: 0;
  }
  .site-footer > .container > .row > [class*="col-"] {
    flex: none; width: auto; max-width: none; padding: 0 !important; margin-bottom: 0 !important;
  }
}
