/* Home page: the brain hero and the sections under it, on the public design system (bp-* from be-public-components.css).
   Product tints colour section markers and the seven marks in the hero. Buttons stay the accent. */
.hb { --t-voice:#7a2a3c; --t-messaging:#ef791e; --t-internet:#009f95; --t-oneai:#9b7bd8; --t-hub:#5fd3f0; --t-capture:#4a8fd4; --t-direct:#b69939; --t-teammate:#6b6fd6; }
[data-product="voice"] { --tint:var(--t-voice); }
[data-product="messaging"] { --tint:var(--t-messaging); }
[data-product="internet"] { --tint:var(--t-internet); }
[data-product="oneai"] { --tint:var(--t-oneai); }
[data-product="hub"] { --tint:var(--t-hub); }
[data-product="capture"] { --tint:var(--t-capture); }
[data-product="direct"] { --tint:var(--t-direct); }
[data-product="teammate"] { --tint:var(--t-teammate); }

/* global.css sizes every heading with !important; the public type scale has to win here */
.hb .bp-display { font-size:clamp(2.4rem, 3.8vw + .5rem, 4rem) !important; }
.hb .bp-h2 { font-size:clamp(2rem, 3vw + .5rem, 3rem) !important; }
.hb .bp-h3 { font-size:clamp(1.3rem, 1.4vw + .5rem, 1.6rem) !important; }
.hb .bp-eyebrow { margin:0; }
.hb .bp-frame { position:relative; }
.hb .bp-frame > .bp-inner { position:relative; }
.hb .bp-grid > * { position:relative; }

/* photos sit under a dark wash so type keeps its contrast */
.hb-bgimg { position:absolute; inset:0; background-size:cover; background-position:center; pointer-events:none; }
.hb-bgimg::after { content:""; position:absolute; inset:0; background:linear-gradient(90deg, #121212 0%, #121212e6 38%, #12121299 70%, #12121266 100%), linear-gradient(0deg, #121212 0%, transparent 30%); }
.hb-hero .hb-bgimg { background-image:url(/assets/img/backgrounds/main-hero.jpg); opacity:0; }

/* hero: dots -> brain -> seven marks (home-brain.js draws it); the fixed header sits over the top 90px */
.hb-hero { position:relative; height:760px; border-bottom:1px dashed var(--line); overflow:hidden; background:var(--bg); }
.hb-hero-inner { position:relative; max-width:1260px; height:100%; margin:0 auto; }
.hb-hero canvas { position:absolute; inset:0; width:100%; height:100%; display:block; }
.hb-brainimg { position:absolute; left:66%; top:44%; width:1500px; max-width:none; transform:translate(-45%, -38%); opacity:0; filter:grayscale(1) brightness(1.45) contrast(1.05); -webkit-mask-image:radial-gradient(ellipse 30% 36% at 45% 38%, #000 35%, transparent 100%); mask-image:radial-gradient(ellipse 30% 36% at 45% 38%, #000 35%, transparent 100%); pointer-events:none; }
.hb-text { position:absolute; left:32px; top:170px; max-width:520px; z-index:1; }
.hb-text .bp-display { margin:20px 0 24px; }
.hb-actions { display:flex; flex-wrap:wrap; gap:12px; margin-top:40px; }
.hb-replay { position:absolute; right:32px; top:120px; z-index:1; }

/* section heads and grids */
.hb-sechead { display:grid; grid-template-columns:minmax(0, 1fr) minmax(0, 1fr); gap:32px; align-items:end; margin-bottom:56px; }
.hb-sechead .bp-h2 { margin-top:16px; }
.hb-sechead .bp-lead { font-size:1.1rem; }
.hb-g2 { grid-template-columns:repeat(2, 1fr); }
.hb-g3 { grid-template-columns:repeat(3, 1fr); }
.hb-g4 { grid-template-columns:repeat(4, 1fr); }
.hb-g5 { grid-template-columns:repeat(5, 1fr); }
.hb-g5 .hb-prod p { font-size:.95rem; }
.hb-group { padding:20px 32px !important; grid-column:1 / -1; }
.hb-nt { border-top:0; }
.hb-pad64 { padding-top:64px !important; padding-bottom:64px !important; }
.hb-h2gap { margin:16px 0 56px; }

/* customers */
.hb-logos-head { display:flex; flex-wrap:wrap; gap:16px; justify-content:space-between; align-items:end; margin-bottom:32px; }
.hb-logos { display:grid; grid-template-columns:repeat(5, 1fr); border-top:1px dashed var(--line); border-left:1px dashed var(--line); }
.hb-logos div { display:flex; align-items:center; justify-content:center; height:104px; padding:20px 28px; border-right:1px dashed var(--line); border-bottom:1px dashed var(--line); }
.hb-logos img { max-width:100%; max-height:52px; object-fit:contain; filter:brightness(0) invert(1); opacity:.7; transition:opacity .15s; }
.hb-logos img.outlined { filter:grayscale(1) brightness(1.15); } /* an outlined logo goes solid white under invert */
.hb-logos div:hover img { opacity:1; }

/* products */
.hb-prod { display:flex; flex-direction:column; gap:12px; min-height:260px; }
.hb-prod::before { content:""; position:absolute; left:-1px; top:-1px; width:56px; height:3px; background:var(--tint); z-index:1; }
.hb-prod p { margin:0; font-size:1rem; }
.hb-prod .more { margin-top:auto; font-size:.95rem; }
.hb-prod .ai { font:500 .7rem/1 var(--font-mono); letter-spacing:.08em; text-transform:uppercase; color:var(--muted); border:1px solid var(--line2); padding:5px 8px; align-self:flex-start; }
.hb-pimg { display:block; width:calc(100% + 64px); margin:-32px -32px 8px; aspect-ratio:16 / 9; object-fit:cover; filter:saturate(.85) brightness(.8); }

/* where the AI is */
.hb-airow { display:grid; grid-template-columns:200px 1fr 1fr; gap:24px; padding:24px 0; border-top:1px solid var(--line2); align-items:baseline; }
.hb-airow:last-child { border-bottom:1px solid var(--line2); }
.hb-airow .bp-eyebrow { color:var(--bright); display:flex; gap:10px; align-items:center; }
.hb-airow .bp-eyebrow::before { content:""; width:8px; height:8px; background:var(--tint); }
.hb-airow p { margin:0; font-size:1rem; }
.hb-airow .who { color:var(--muted); }

/* numbers */
.hb-band .hb-bgimg { background-image:url(/assets/img/backgrounds/abstract-red-1.jpg); }
.hb-band .hb-bgimg::after { background:linear-gradient(0deg, #121212f0, #121212c0); }
.hb-band .bp-h2 { margin:16px 0 48px; max-width:22ch; }
.hb-stats { display:grid; grid-template-columns:repeat(auto-fit, minmax(0, 1fr)); border:1px solid var(--line2); background:#0d0e10d9; }
.hb-stats > div { padding:28px 24px; display:flex; flex-direction:column; gap:40px; justify-content:space-between; }
.hb-stats > div + div { border-left:1px solid var(--line2); }
.hb-stats .v { font:400 clamp(2.4rem, 3vw + 1rem, 3.4rem)/1 var(--font-mono); color:var(--bright); font-variant-numeric:tabular-nums; }
.hb-stats .v small { font-size:.45em; color:var(--ink); margin-left:4px; }
.hb-stats .l { font-size:.9rem; color:var(--ink); }

/* why us */
.hb-why { min-height:220px; }
.hb-why .n { font:400 .8rem/1 var(--font-mono); color:var(--muted); display:block; margin-bottom:40px; }
.hb-why p { font-size:1rem; margin:12px 0 0; }

/* testimonials */
.hb-quotes figure { margin:0; display:flex; flex-direction:column; gap:24px; }
.hb-quotes figure::before { content:""; position:absolute; left:-1px; top:-1px; width:56px; height:3px; background:var(--tint); }
.hb-quotes blockquote { margin:0; font:300 1.25rem/1.5 var(--font-sans); color:var(--bright); }
.hb-quotes figcaption { margin-top:auto; display:flex; justify-content:space-between; gap:12px; align-items:end; font-size:.9rem; }
.hb-quotes figcaption b { display:block; font-weight:500; color:var(--bright); }
.hb-quotes figcaption span { color:var(--muted); }

/* closing call to action */
.hb-cta .bp-inner { display:flex; flex-wrap:wrap; gap:32px; justify-content:space-between; align-items:center; padding-top:72px; padding-bottom:72px; }
.hb-cta .bp-h2 { max-width:20ch; }
.hb-cta .hb-bgimg { background:radial-gradient(closest-side at 85% 50%, #a7092e33, transparent); }
.hb-cta .hb-bgimg::after { content:none; }

@media (max-width: 900px) {
  .hb-hero { height:1000px; }
  .hb-text { left:16px; right:16px; top:160px; }
  .hb-replay { right:16px; top:100px; }
  .hb-brainimg { left:50%; top:62%; width:700px; }
  .hb-sechead, .hb-g2, .hb-g3, .hb-g4, .hb-g5, .hb-stats { grid-template-columns:1fr; }
  .hb-stats > div + div { border-left:0; border-top:1px solid var(--line2); }
  .hb-airow { grid-template-columns:1fr; gap:8px; }
  .hb-logos { grid-template-columns:repeat(3, 1fr); }
}

/* Contact page (src/contact-us.njk): details beside the form, then pp-steps from product.css. */
.cp-grid { display:grid; grid-template-columns:minmax(0, 1fr) minmax(0, 1.1fr); gap:64px; align-items:start; padding-top:170px; padding-bottom:80px; }
.cp-grid .bp-display { margin:20px 0 24px; }
.cp-details { display:grid; gap:22px; margin:44px 0 0; }
.cp-details dd { margin:6px 0 0; font-size:1.15rem; color:var(--bright); }
.cp-details dd span { color:var(--muted); font-size:1rem; }
.cp-details a { color:var(--bright) !important; text-decoration:none !important; border-bottom:1px solid var(--line); }
.cp-details a:hover { border-color:var(--bright); }
.cp-form { border:1px solid var(--line2); background:var(--panel); padding:32px; }
.cp-form .bp-h3 { margin:0 0 8px; }
.cp-form > p { margin:0 0 24px; color:var(--muted); font-size:.95rem; }
.cp-form .enquiry-grid { max-width:none; }
@media (max-width: 900px) {
  .cp-grid { grid-template-columns:1fr; gap:40px; padding-top:120px; }
  .cp-form { padding:20px; }
}

/* About page (src/about-us.njk). */
.ab-open { max-width:72ch; font-size:1.35rem; line-height:1.5; margin:0; }
.hb-band .bp-h2.ab-quote { max-width:40ch; margin-bottom:0; }
.hb-top { padding-top:170px !important; padding-bottom:40px !important; }
.hb-top .bp-display { margin:20px 0 24px; }
.hb-top .bp-lead { max-width:68ch; }
.hb-top .bp-lead + .bp-lead { margin-top:16px; }
@media (max-width: 900px) { .hb-top { padding-top:120px !important; } }
.hb-g1 { grid-template-columns:1fr; }
.hb-g1 .hb-prod { min-height:320px; padding-left:calc(50% + 40px) !important; }
.hb-g1 .hb-pimg { position:absolute; left:0; top:0; width:50%; height:100%; margin:0; aspect-ratio:auto; }
.hb-g1 .hb-prod .more { margin-top:auto; }
@media (max-width: 900px) {
  .hb-g1 .hb-prod { min-height:0; padding-left:32px !important; }
  .hb-g1 .hb-pimg { position:static; width:calc(100% + 64px); height:auto; margin:-32px -32px 8px; aspect-ratio:16 / 9; }
}

/* BE Network catalogue (src/solutions/be-network.njk). */
[data-product="carrier"] { --tint:#6c8c9a; }
.cs-group .bp-eyebrow { margin-bottom:24px; }
.cs-rows { border-top:1px dashed var(--line2); }
.cs-row { display:grid; grid-template-columns:minmax(0, 1fr) 180px 180px; gap:24px; align-items:center; padding:20px 0; border-bottom:1px dashed var(--line2); }
.cs-name { font:300 1.25rem/1.3 var(--font-sans); color:var(--bright) !important; text-decoration:none !important; }
.cs-name:hover { text-decoration:underline !important; }
.cs-what p { margin:4px 0 0; font-size:.95rem; }
.cs-price { font:400 .95rem/1.4 var(--font-mono); color:var(--bright); }
.cs-price span { color:var(--muted); }
.cs-act { text-align:right; }
@media (max-width: 900px) {
  .cs-row { grid-template-columns:1fr; gap:10px; }
  .cs-act { text-align:left; }
}
.hb-prod .hb-links { margin-top:auto; display:flex; flex-wrap:wrap; gap:8px 24px; }
.hb-prod .hb-links .more { margin-top:0; }

/* Products as equals (components/product-grid.njk): eight identical cards; hover shows the photo in light greyscale. */
.hb-eq { display:grid; grid-template-columns:repeat(4, minmax(0, 1fr)); border-top:1px dashed var(--line2); border-left:1px dashed var(--line2); }
.hb-eq-t { position:relative; display:flex; flex-direction:column; gap:12px; padding:28px 26px; min-height:260px; border-right:1px dashed var(--line2); border-bottom:1px dashed var(--line2); overflow:hidden; color:var(--ink) !important; text-decoration:none !important; isolation:isolate; }
.hb-eq-t::before { content:""; position:absolute; left:0; top:0; width:0; height:2px; background:var(--tint); transition:width .25s; z-index:2; }
.hb-eq-bg { position:absolute; inset:0; z-index:-1; background-size:cover; background-position:center; filter:grayscale(1) brightness(1.6) contrast(.85); opacity:0; transform:scale(1.04); transition:opacity .35s, transform .6s; }
.hb-eq-t:hover::before, .hb-eq-t:focus-visible::before { width:100%; }
.hb-eq-t:hover .hb-eq-bg, .hb-eq-t:focus-visible .hb-eq-bg { opacity:.16; transform:scale(1); }
.hb-eq-t:focus-visible { outline:2px solid var(--focus, #fff); outline-offset:-2px; }
.hb-eq-hd { display:flex; justify-content:space-between; align-items:center; gap:12px; margin-bottom:8px; }
.hb-eq-mk { width:44px; height:44px; filter:var(--mark); }
.hb-eq-t .bp-h3 { margin:0; }
.hb-eq-t p { margin:0; font-size:.95rem; }
.hb-eq-go { margin-top:auto; font-size:.9rem; color:var(--bright); border-bottom:1px solid var(--line); align-self:flex-start; }
.hb-eq-t:hover .hb-eq-go { border-color:var(--bright); }
@media (prefers-reduced-motion: reduce) { .hb-eq-bg, .hb-eq-t::before { transition:none; } }
@media (max-width: 1000px) { .hb-eq { grid-template-columns:repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .hb-eq { grid-template-columns:1fr; } .hb-eq-t { min-height:0; } }
.hb-eq-t:hover, .hb-eq-t:hover p, .hb-eq-t p { color:var(--ink) !important; }
.hb-eq-t:hover .bp-h3, .hb-eq-t .bp-h3, .hb-eq-t .hb-eq-go { color:var(--bright) !important; }
.hb-eq-t .bp-eyebrow { color:var(--muted) !important; }
