/*
 * Karnaf V3 — cookie consent banner (plugin: cookie-law-info / CookieYes).
 * CSS-only restyle: compact navy bar, Assistant font, RTL.
 * Mobile: bottom bar (~110px), floating WhatsApp icon lifted above it while visible,
 *         room kept at the inline-end (left in RTL) for the Ally accessibility button.
 * Desktop: card at the bottom inline-start corner (right in RTL), away from the WhatsApp tab.
 * The plugin writes inline colours on the buttons, hence the !important rules.
 */

body .cky-consent-container{
  --kcb-bg:var(--navy,#1B252F);
  --kcb-ink:#FFFFFF;
  --kcb-muted:#D7DCE0;
  --kcb-accent:var(--orange,#F7A11A);
  z-index:9990; /* below the floating WhatsApp (9999) and Ally buttons */
  font-family:var(--f-body,"Assistant",system-ui,sans-serif);
  direction:rtl;
  text-align:right;
}
body .cky-consent-container .cky-consent-bar{
  background:var(--kcb-bg) !important;
  border:0 !important;
  border-top:3px solid var(--kcb-accent) !important;
  box-shadow:0 -10px 30px -12px rgba(15,22,28,.45);
  padding:14px 20px;
  color:var(--kcb-ink);
}
body .cky-consent-container .cky-notice .cky-title{
  color:var(--kcb-ink) !important;
  font-family:var(--f-head,"Rubik",system-ui,sans-serif);
  font-size:16px;
  line-height:1.3;
  font-weight:700;
  margin:0 0 6px;
}
body .cky-consent-container .cky-notice-des,
body .cky-consent-container .cky-notice-des *{
  color:var(--kcb-muted) !important;
  font-family:inherit;
  font-size:14px;
  line-height:1.45;
}
body .cky-consent-container .cky-notice-des a,
body .cky-consent-container .cky-notice-des .cky-policy{
  color:var(--kcb-accent) !important;
  border:0;
}
body .cky-consent-container .cky-notice-btn-wrapper{
  display:flex;
  flex-direction:row;
  flex-wrap:nowrap;
  gap:8px;
  margin:0;
}
body .cky-consent-container .cky-notice-btn-wrapper .cky-btn{
  font-family:inherit;
  font-size:14px;
  font-weight:700;
  line-height:1.2;
  min-height:36px;
  padding:8px 16px;
  margin:0 !important;
  border-radius:999px;
  border:1.5px solid rgba(255,255,255,.55) !important;
  background:transparent !important;
  color:var(--kcb-ink) !important;
  white-space:nowrap;
  width:auto;
  order:0;
}
body .cky-consent-container .cky-notice-btn-wrapper .cky-btn:hover{
  border-color:var(--kcb-ink) !important;
  background:rgba(255,255,255,.08) !important;
}
body .cky-consent-container .cky-notice-btn-wrapper .cky-btn-customize{
  border-color:transparent !important;
  text-decoration:underline;
  text-underline-offset:3px;
  padding-inline:8px;
}
body .cky-consent-container .cky-notice-btn-wrapper .cky-btn-accept{
  background:var(--kcb-accent) !important;
  border-color:var(--kcb-accent) !important;
  color:var(--navy,#1B252F) !important;
}
body .cky-consent-container .cky-notice-btn-wrapper .cky-btn-accept:hover{
  background:#FFB84A !important;
}
body .cky-consent-container .cky-btn:focus-visible,
body .cky-consent-container .cky-notice-des a:focus-visible{
  outline:3px solid var(--kcb-accent) !important;
  outline-offset:2px;
}
body .cky-consent-container .cky-notice-btn-wrapper .cky-btn-accept:focus-visible{
  outline-color:var(--kcb-ink) !important;
}

/* Preference centre (modal): brand font + accent only. */
body .cky-modal,
body .cky-modal *{ font-family:var(--f-body,"Assistant",system-ui,sans-serif); }
body .cky-modal .cky-btn-accept,
body .cky-modal .cky-btn-preferences{
  background:var(--orange,#F7A11A) !important;
  border-color:var(--orange,#F7A11A) !important;
  color:var(--navy,#1B252F) !important;
}
body .cky-modal .cky-btn-reject,
body .cky-modal .cky-btn-preferences{
  border-radius:999px;
}
body .cky-modal .cky-btn{ border-radius:999px; font-weight:700; }
body .cky-modal .cky-btn-reject{
  color:var(--navy,#1B252F) !important;
  border-color:var(--navy,#1B252F) !important;
  background:transparent !important;
}

/* "Revisit consent" round button: small navy hexagon-ish dot, right side (left side holds WhatsApp tab / Ally). */
body .cky-btn-revisit-wrapper{
  background:var(--navy,#1B252F) !important;
  width:40px;
  height:40px;
  left:auto !important;
  right:20px !important;
  bottom:20px !important;
  z-index:9990;
  box-shadow:0 4px 14px rgba(15,22,28,.3);
  border:2px solid var(--orange,#F7A11A);
}
body .cky-btn-revisit-wrapper .cky-btn-revisit img{ width:22px; height:22px; }
body .cky-btn-revisit-wrapper::before,
body .cky-btn-revisit-wrapper::after{ display:none !important; } /* English hover tooltip */

/* Desktop / tablet: floating card at the inline-start bottom corner. */
@media (min-width:769px){
  body .cky-consent-container{
    left:auto;
    right:20px;
    bottom:20px;
    width:min(540px, calc(100% - 300px));
  }
  body .cky-consent-container .cky-consent-bar{
    border-radius:var(--radius,20px);
    border-top:0 !important;
    box-shadow:var(--shadow-l,0 30px 60px -24px rgba(27,37,47,.35));
    padding:18px 22px;
  }
  body .cky-consent-container .cky-notice-group{
    display:block;
  }
  body .cky-consent-container .cky-notice-btn-wrapper{
    margin-top:12px;
    justify-content:flex-start;
  }
}

/* Mobile: compact bottom bar. */
@media (max-width:768px){
  body .cky-consent-container{
    left:0;
    right:0;
    bottom:0;
    width:100%;
  }
  body .cky-consent-container .cky-consent-bar{
    padding:8px 12px calc(8px + env(safe-area-inset-bottom, 0px)) !important;
  }
  /* The greeting title stays for screen readers only. */
  body .cky-consent-container .cky-notice .cky-title{
    position:absolute !important;
    width:1px; height:1px;
    overflow:hidden;
    clip:rect(0 0 0 0);
    clip-path:inset(50%);
    white-space:nowrap;
    margin:0;
    padding:0 !important;
  }
  body .cky-consent-container .cky-notice-group{ display:block; }
  body .cky-consent-container .cky-notice-des{
    padding:0 !important;
    max-height:calc(3 * 1.35em) !important; /* 3 lines, rest scrolls */
    overflow-y:auto !important;
  }
  body .cky-consent-container .cky-notice-des,
  body .cky-consent-container .cky-notice-des *{
    font-size:12.5px !important;
    line-height:1.35 !important;
  }
  body .cky-consent-container .cky-notice-des br{ display:none; }
  body .cky-consent-container .cky-notice-btn-wrapper{
    padding:0 !important;
    padding-inline-end:68px !important; /* Ally button zone (bottom-left in RTL) */
    margin-top:6px !important;
    justify-content:flex-start;
  }
  body .cky-consent-container .cky-notice-btn-wrapper .cky-btn{
    flex:0 1 auto;
    font-size:13px !important;
    min-height:32px;
    padding:5px 12px;
  }
  body .cky-consent-container .cky-notice-btn-wrapper .cky-btn-customize{ padding-inline:4px; }

  /* Lift the mobile floating WhatsApp icon above the bar while the bar is shown. */
  body:has(.cky-consent-container:not(.cky-hide)) .elementor-element.elementor-global-3484.elementor-fixed{
    bottom:calc(112px + env(safe-area-inset-bottom, 0px)) !important;
    transition:bottom .25s var(--ease,ease);
  }
  /* Revisit button sits above the WhatsApp icon (bottom-right). */
  body .cky-btn-revisit-wrapper{
    width:36px;
    height:36px;
    right:26px !important;
    bottom:88px !important;
  }
}

@media (prefers-reduced-motion:reduce){
  body .cky-consent-container,
  body .elementor-element.elementor-global-3484{ transition:none !important; animation:none !important; }
}
