/* Rebound brand layer v6 (tag brand6). Fonts, continuous brand gradient headline text, section background motif.
   Colours of buttons, glow and fields are changed in the original files (see CHANGELOG). */

/* ---------- Fonts (Profa). Weight ranges make every request map to a real face, so nothing is faux-bold.
   size-adjust 72% on the headline face: Profa Expanded is much wider than the old Poppins headlines, so lines break as before.
   unicode-range leaves out * ; @ (U+002A, U+003B, U+0040): the trial font draws its preview stamp on those three, so the fallback font draws them instead. Remove this line when the paid web licence files are installed. ---------- */
@font-face{font-family:"Profa Text";src:url("brand/fonts/profa-regular.ttf") format("truetype");font-weight:100 499;font-style:normal;font-display:block;unicode-range:U+0000-0029,U+002B-003A,U+003C-003F,U+0041-10FFFF;}
@font-face{font-family:"Profa Text";src:url("brand/fonts/profa-semibold.ttf") format("truetype");font-weight:500 900;font-style:normal;font-display:block;unicode-range:U+0000-0029,U+002B-003A,U+003C-003F,U+0041-10FFFF;}
@font-face{font-family:"Profa Sub";src:url("brand/fonts/profa-semibold.ttf") format("truetype");font-weight:100 900;font-style:normal;font-display:block;unicode-range:U+0000-0029,U+002B-003A,U+003C-003F,U+0041-10FFFF;}
@font-face{font-family:"Profa Head";src:url("brand/fonts/profa-extrabold-expanded.ttf") format("truetype");font-weight:100 900;font-style:normal;font-display:block;unicode-range:U+0000-0029,U+002B-003A,U+003C-003F,U+0041-10FFFF;size-adjust:72%}

:root{
  --rb-grad:linear-gradient(90deg,#46026c 0%,#16adb9 100%);
  --rb-font-text:"Profa Text","Cairo","Tajawal",system-ui,-apple-system,"Segoe UI",Roboto,sans-serif;
  --rb-font-sub:"Profa Sub","Cairo","Tajawal",system-ui,-apple-system,"Segoe UI",Roboto,sans-serif;
  --rb-font-head:"Profa Head","Cairo","Tajawal",system-ui,-apple-system,"Segoe UI",Roboto,sans-serif;
}

/* ROLE 3: normal text (icon fonts keep their own font) */
html body :is(p,li,span,a,div,label,input,textarea,select,button,option,td,th,small,figcaption,blockquote,dt,dd,em,strong,b,i,cite,address,summary,legend,caption,time,nav,form):not(:is(.fa,.fas,.far,.fab,.fa-solid,.fa-regular,.fa-brands,.dashicons,.material-icons,[class*="eicon-"],[class^="fa-"],[class*=" fa-"],[class*="ct-icon"],.ct-icon-container,.star-rating,.star-rating span,.rbh-ch)),
html body{font-family:var(--rb-font-text)!important}

/* ROLE 2: text directly under a headline */
html body :not(#rb):is(h1,h2,h3,h4) + :is(p,div.muted,div.textwidget,div.elementor-widget-text-editor),
html body :not(#rb):is(.rbcar-lead,.rbv-sub,.rbt-au-lead,.rbfaq-p,.lead,.subtitle,.sub-title,.page-description,.entry-excerpt,.ct-page-title-description,.woocommerce-products-header p,.term-description,.elementor-widget-heading + .elementor-widget-text-editor p,.rbt .page-heading p,.rbh-ph p,.rb-pm .brand-sub,.rbh-by),
html body :not(#rb):is(h1,h2,h3,h4) + :is(p,div.muted,div.textwidget,div.elementor-widget-text-editor) :is(p,span,a,li){font-family:var(--rb-font-sub)!important}

/* ROLE 1: headlines */
html body :not(#rb):is(h1,h2,h3,h4,h5,h6,.elementor-heading-title,.widget-title,.entry-title,.page-title,.woocommerce-loop-product__title,.product_title,.rbg,.brand-title,.rbh-word,.rbh-word i,.rbt .page-heading h1,.rbh-ph h1,.rb-pm .brand-title,.rbt-au-h,.rbfaq-h,.rbcar-h,[class*="-h1"],[class*="-h2"]){font-family:var(--rb-font-head)!important;font-weight:800!important;letter-spacing:-.01em}
/* words inside a headline (Meet <span>Tarek</span>) use the same face, weight and spacing */
html body :not(#rb):is(h1,h2,h3,h4,h5,h6,.elementor-heading-title) :is(span,em,strong,b,i,a,small,mark):not(:is(.fa,.fas,.far,.fab,.fa-solid,.fa-regular,.fa-brands,.dashicons,[class*="eicon-"],[class*="ct-icon"])){font-family:var(--rb-font-head)!important;font-weight:800!important;letter-spacing:inherit;font-style:normal}
html body :is(h1,.elementor-widget-heading h1){letter-spacing:-.02em}
html body :is(h1,h2,h3,h4,h5,h6,.elementor-heading-title){overflow-wrap:break-word;hyphens:manual}

/* ---------- Brand gradient on the WHOLE headline, from the first letter. JS (rbh-brand.js) adds .rb-on-dark where the background is dark. ---------- */
html body :is(h1,h2,h3,.elementor-heading-title,.rbt .page-heading h1,.rbh-ph h1,.rbt-au-h,.rbfaq-h,.rbcar-h):where(:not(.rb-on-dark)):where(:not([data-rb-split])):where(:not(:is(.rbh,#wpadminbar,.ct-footer,footer,.ct-panel) *)){
  background-image:var(--rb-grad)!important;background-size:100% 100%;background-repeat:no-repeat;
  -webkit-background-clip:text!important;background-clip:text!important;
  -webkit-text-fill-color:transparent!important;color:transparent!important;padding-bottom:.08em;
}
/* A coloured word inside such a headline joins the headline gradient instead of starting its own. */
html body :is(h1,h2,h3,.elementor-heading-title,.rbt .page-heading h1,.rbh-ph h1,.rbt-au-h,.rbfaq-h,.rbcar-h):where(:not(.rb-on-dark)):where(:not([data-rb-split])):where(:not(:is(.rbh,#wpadminbar,.ct-footer,footer,.ct-panel) *)) :is(.rbg,span,em,strong,b,i):not(.rb-w){
  background:none!important;background-image:none!important;-webkit-text-fill-color:transparent!important;color:transparent!important}
html body :is(h1,h2,h3,.elementor-heading-title).rb-on-dark{-webkit-text-fill-color:currentColor!important;background-image:none!important}

/* Split headline (JS wraps each word): every word paints its own slice of ONE gradient laid along all lines, so the colour runs on from line to line.
   Until a heading has been measured (or while it is hidden) its words stay one solid brand purple, never a gradient per word. */
html body [data-rb-split]:not(#rb):not(.rb-on-dark){background:none!important;-webkit-text-fill-color:currentColor!important;color:#46026c!important}
html body [data-rb-split]:not(#rb) .rb-w{background:none!important;-webkit-text-fill-color:#46026c!important;color:#46026c!important}
html body [data-rb-split][data-rb-ok]:not(#rb):not(.rb-on-dark) .rb-w{background-image:var(--rb-grad)!important;background-repeat:no-repeat!important;background-size:var(--rb-bw,100%) 100%!important;background-position:var(--rb-bx,0) 0!important;-webkit-background-clip:text!important;background-clip:text!important;-webkit-text-fill-color:transparent!important;color:transparent!important}

/* ---------- Header logo (image replaces the plain R tile) ---------- */
.rbh .rbh-logo .rbh-tile{width:auto!important;height:auto!important;background:none!important;border-radius:0!important;box-shadow:none!important;display:flex;align-items:center}
.rbh .rbh-logo .rbh-tile img{display:block;height:44px;width:auto;max-width:none}
.rbh .rbh-logo:hover .rbh-tile{transform:scale(1.04)}
.rbh .rbh-word{color:#46026c!important;-webkit-text-fill-color:#46026c!important;background:none!important;font-size:20px!important;letter-spacing:-.01em!important}
.rbh .rbh-word i{color:#16adb9!important;-webkit-text-fill-color:#16adb9!important}
@media(max-width:782px){.rbh .rbh-logo .rbh-tile img{height:38px}}

/* ---------- Dark sections look like the light ones (no blue bands). ---------- */
html body .rbp-sec.rbp-sec.rbp-sec.rbp-dark:not(:first-child){background:radial-gradient(700px 380px at 12% 100%,rgba(22,173,185,.2),transparent 65%),linear-gradient(180deg,#fff,#F0FAF9)!important}
html body .rbp-sec.rbp-dark:not(:first-child) :is(p,li,h4,h5,h6,label,small):not(:is(a,.elementor-button,.elementor-button *,button,button *,.rbp-btn,.rbp-btn *)){color:#2C2C2E!important}

/* ---------- Background motif. Hero piece on every page; every page gets its own long wave (drawn by rbh-brand.js) from the top of the page to the end instead. ---------- */
:is(.rbp-sec,.elementor-top-section,.e-con.e-parent):first-child{position:relative;isolation:isolate}
:is(.rbp-sec,.elementor-top-section,.e-con.e-parent):first-child::after{content:"";position:absolute;inset:0;z-index:-1;pointer-events:none;
  background:url("brand/brand-hero.svg") right top/min(1200px,100%) auto no-repeat}
.rb-wave-host{position:relative;isolation:isolate;background:linear-gradient(180deg,#F0FAF9 0,#fff 14%,#F7FCFC 100%)}
.rb-wave-host>.rb-wave{position:absolute;left:0;top:0;width:100%;z-index:-1;pointer-events:none;overflow:hidden}
.rb-wave svg{display:block}
html body .rb-wave-host.rb-wave-host.rb-wave-host>.rbp-sec.rbp-sec.rbp-sec.rbp-sec.rbp-sec{background:transparent!important}
/* Pages with sections: same look before the script runs, so nothing jumps */
html body .rbp-sec.rbp-sec.rbp-sec.rbp-sec.rbp-sec.rbp-sec{background:transparent!important}
/* brand11: the Mission page look everywhere = same wave + same hero piece (brand-hero.svg) on the first section. Pain Map section excluded. */
html body :is(.rbp-sec,.elementor-top-section,.e-con.e-parent):first-child:has(.rb-pm, #rb-pm, [data-rb-pm])::after{display:none!important}

/* ---------- Sizes: smaller, one scale for every page ---------- */
html:root{--rb-h1-size:clamp(32px,4.2vw,54px);--rb-h2-size:clamp(24px,2.6vw,35px)}
html body .rbp-sec:not(:first-child) .elementor-widget-heading:not(.rbp-eye) h2.elementor-heading-title{font-size:var(--rb-h2-size)!important;line-height:1.15!important}

/* ---------- Eyebrows (small text above a headline): one style on every page ---------- */
html body :not(#rb):is(.rbp-eye .elementor-heading-title,.rbp-eye .elementor-heading-title :is(span,.rb-w),.rbt .page-heading .eyebrow,.rbt .health-header .mini-label){font-family:var(--rb-font-sub)!important;font-size:13px!important;font-weight:600!important;letter-spacing:.14em!important;text-transform:uppercase!important;line-height:1.25!important}
html body .rbt :is(.page-heading .eyebrow,.health-header .mini-label):not(#rb){display:inline-block;background-color:transparent!important;background-image:var(--rb-grad)!important;-webkit-background-clip:text!important;background-clip:text!important;-webkit-text-fill-color:transparent!important;color:transparent!important;padding:0 0 .1em!important;margin-bottom:12px!important}

/* ---------- Line spacing: Profa Head is drawn smaller (size-adjust), so its lines need a smaller line-height to sit as tight as before ---------- */
html body :not(#rb):is(h1,h2,.rbt .page-heading h1,.elementor-widget-heading h1,.elementor-widget-heading h2){line-height:.86!important}
html body :not(#rb):is(h3,h4,h5,h6,.elementor-widget-heading h3,.elementor-widget-heading h4){line-height:.95!important}
html body :not(#rb):is(.rbp-eye .elementor-heading-title,.rbt .page-heading .eyebrow,.rbt .health-header .mini-label){line-height:1.25!important}

/* ---------- Anti flash: the page stays hidden until fonts and the script are ready (failsafe 2.5 s in the page head) ---------- */
html.rb-pre body{opacity:0!important}
html body{transition:opacity .2s ease}
/* brand10: wave pages without Elementor sections (Booking, Shop, Mission) */
html body.rb-wave-main main#main .ct-container,html body.rb-wave-main main#main article,html body.rb-wave-main main#main .entry-content,html body.rb-wave-main main#main .rbt,html body.rb-wave-main main#main .platform-section,html body.rb-wave-main main#main .m10-sec,html body.rb-wave-main main#main .woocommerce,html body.rb-wave-main main#main .site-main,html body.rb-wave-main main#main .ct-woocommerce-container{background:transparent!important}
/* brand10b: top-anchored wave host for Booking, Shop, Mission (starts behind header and page title) */
html body .rb-wave-top{position:relative;isolation:isolate}
html body .rb-wave-top>.rb-wave{position:absolute;left:0;top:0;width:100%;z-index:-1;pointer-events:none;overflow:hidden;background:linear-gradient(180deg,#F0FAF9 0,#fff 14%,#F7FCFC 100%)}
html body.rb-wave-main .hero-section,html body.rb-wave-main main#main{background:transparent!important}

/* brand10c: page title area must not hide the wave */
html body.rb-wave-main main#main .hero-section,html body.rb-wave-main main#main .hero-section[data-type],html body.rb-wave-main main#main .hero-section .entry-header{background:none!important;background-color:transparent!important;background-image:none!important;box-shadow:none!important}
html body.rb-wave-main main#main .hero-section::before,html body.rb-wave-main main#main .hero-section::after{display:none!important}
/* brand12: the hero piece lives inside the wave layer, so it is never cut at a section edge */
html body :is(.rbp-sec,.elementor-top-section,.e-con.e-parent):first-child::after{display:none!important}
.rb-wave::before{content:"";position:absolute;inset:0;pointer-events:none;background:url("brand/brand-hero.svg") right top/min(1200px,100%) auto no-repeat}

/* brand14: text of the three floating labels around the Home 3D circle only (bold headline font, brand blend on an inner span). Box, shape and shadow stay as the original. */
html body .rbx-chip:not(#rb){font-family:var(--rb-font-head)!important;font-weight:800!important;font-size:12px!important;letter-spacing:.06em!important;text-transform:uppercase!important;white-space:nowrap}
html body .rbx-chip:not(#rb) i{font-style:normal;font-family:inherit;font-weight:inherit;background:var(--rb-grad);-webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:transparent;color:transparent}

/* brand15: the wave and brand elements run behind the footer too, to the end of the page */
html body.rb-wave-main footer.ct-footer,html body.rb-wave-main footer.ct-footer [data-row],html body.rb-wave-main footer.ct-footer .ct-container,html body.rb-wave-main #footer{background:none!important;background-color:transparent!important;background-image:none!important}
html body.rb-wave-main .elementor,html body.rb-wave-main .elementor-section-wrap,html body.rb-wave-main .rb-wave-host{background-color:transparent!important}

/* brand16: footer. Soft white fade behind the text, larger text, headings larger than links. */
html body footer.ct-footer#footer{background-image:linear-gradient(180deg,rgba(255,255,255,0) 0,rgba(255,255,255,.7) 26%,rgba(255,255,255,.86) 100%)!important}
html body footer.ct-footer .ct-widget,html body footer.ct-footer .ct-widget p,html body footer.ct-footer .ct-widget li,html body footer.ct-footer .ct-widget a{font-size:18px!important;line-height:1.6!important}
html body footer.ct-footer .ct-footer-copyright,html body footer.ct-footer .ct-footer-copyright a{font-size:15px!important}
html body footer.ct-footer .widget-title:not(#rb){font-size:24px!important;line-height:1.1!important;margin:0 0 16px!important}

/* brand17: footer call-to-action and link row */
html body footer.ct-footer .rbh-foot-actions{display:flex;flex-wrap:wrap;align-items:center;gap:14px 20px;margin:18px 0 0!important}
html body footer.ct-footer a.rbh-foot-cta{display:inline-flex;align-items:center;justify-content:center;padding:13px 26px;border-radius:999px;background:var(--rb-grad);color:#fff!important;font-family:var(--rb-font-sub);font-weight:600;font-size:14px!important;letter-spacing:.12em;text-transform:uppercase;text-decoration:none;box-shadow:0 10px 26px -10px rgba(70,2,108,.55)}
html body footer.ct-footer a.rbh-foot-link{font-weight:600;text-decoration:underline;text-underline-offset:4px}
