/* ALG sitewide tweaks */

/* FAQ accordions: chevron (from the Figma 'chevron_down' icon) for icon slots with nothing in them; flips when open.
   Slots that already hold an icon (SVG, image or a drawn chevron element) are left alone. */
.e-accordion-item-icon-base:not(:has(*))::after {
  content: '';
  display: block;
  width: 12px;
  height: 7px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='7' viewBox='0 0 12 7'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23000' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat center / contain;
  transition: transform 0.25s ease;
}
details[open] > summary .e-accordion-item-icon-base:not(:has(*))::after { transform: rotate(180deg); }

/* Links written inside paragraph text (e.g. Home 'Why we do this work') are underlined, as in Figma.
   Whole-paragraph links (nav, footer, buttons) carry .e-paragraph-link-base and are left alone. */
body .elementor .e-paragraph-base a:not(.e-paragraph-link-base) {
  text-decoration: underline;
  text-decoration-thickness: from-font;
  text-underline-position: from-font;
  text-decoration-skip-ink: none;
  color: inherit;
  cursor: pointer;
}

/* Bulleted lists inside paragraph text: a smaller indent than the browser's 40px, so short points
   (e.g. Coaching 'Is coaching for you?') stay on one line. */
[data-elementor-type="wp-page"] .e-paragraph-base ul { padding-left: 1.4em; }

/* Hide the scrollbar on the Leadership Immersions location carousel (arrows drive it). */
[data-id="14653808"] { scrollbar-width: none; }
[data-id="14653808"]::-webkit-scrollbar { display: none; }

/* ---------------------------------------------------------------------------------------------
   Header: 'Contact us' stays on one line; between 1025px and ~1300px the header tightens its side
   padding (and below 1120px its menu gaps and logo) so the menu never collides with the button.
   --------------------------------------------------------------------------------------------- */
[data-id="7c7a78f5"] { white-space: nowrap; flex-shrink: 0; }
@media (min-width: 1025px) {
  body .elementor .elementor-element[data-id="5cf408b4"] {
    padding-inline-start: clamp(32px, calc((100vw - 1000px) / 2), 150px);
    padding-inline-end: clamp(32px, calc((100vw - 1000px) / 2), 150px);
  }
  body .elementor [data-id="7cb93cb0"] { flex-shrink: 0; }
}
@media (min-width: 1025px) and (max-width: 1120px) {
  body .elementor .elementor-element[data-id="7cb93cb0"] { gap: 18px; }
  body .elementor [data-id="622cdb2e"] > a { width: 190px; flex-shrink: 0; }
  body .elementor [data-id="622cdb2e"] > a img { width: 100%; height: auto; }
}
/* Mobile header: logo at a readable size */
@media (max-width: 767px) {
  body .elementor [data-id="622cdb2e"] > a { width: 200px; max-width: 60vw; flex-shrink: 0; }
  body .elementor [data-id="622cdb2e"] > a img { width: 100%; height: auto; }
}

/* ---------------------------------------------------------------------------------------------
   Text first: page text always paints in front of collage / tear textures, and textures move out
   of the way of text as the window narrows. (Header excluded - it has its own stacking order.)
   --------------------------------------------------------------------------------------------- */
[data-elementor-type="wp-page"] .e-heading-base,
[data-elementor-type="wp-page"] .e-paragraph-base,
[data-elementor-type="wp-page"] .e-button-base { position: relative; z-index: 3; }

/* Desktop widths below the 1440 design */
@media (min-width: 1025px) {
  /* Coaching hero tear: never starts left of the heading's right edge, and its bottom edge always
     sits on the bottom of the hero (also on landscape tablets) */
  body .elementor [data-id="2721c33f"] { inset-inline-start: max(56.5%, 800px); }
  body .elementor .elementor-element[data-id="2721c33f"] {
    top: auto; inset-block-start: auto; bottom: 0; inset-block-end: 0;
    height: auto; aspect-ratio: 2503 / 621;
    background-size: 100% auto; background-position: left bottom;
    /* stops growing past 1200px wide, so it doesn't fill the whole hero on big screens */
    width: min(99%, 1200px);
  }
  /* Masterclasses hero: the collage is the 1440 design's right-hand 664 x 400 of the hero, pinned
     to the top-right and never starting left of 776px (clear of the heading) */
  body .elementor .elementor-element[data-id="790ab78e"] {
    left: max(776px, calc(100% - 664px)); right: auto; inset-inline-end: auto;
    top: 0; inset-block-start: 0; width: 664px; height: 400px;
    background-size: 100% 100%; background-position: left top;
  }
}
@media (min-width: 1025px) and (max-width: 1279px) {
  /* About: pink tear beside 'Great teams don't happen by accident' */
  body .elementor [data-id="dd9f39e"] { width: 42%; }
}

/* Tablet */
@media (min-width: 768px) and (max-width: 1024px) {
  /* Coaching hero: tear becomes a strip along the bottom, below the text (as on mobile) */
  body .elementor .elementor-element[data-id="96660fb"] { padding-block-end: 190px; }
  body .elementor [data-id="2721c33f"] {
    width: 820px; height: 204px;
    inset-block-start: auto; inset-block-end: -50px;
    inset-inline-start: auto; inset-inline-end: -120px;
  }
  /* Masterclasses hero collage: scaled down in the top-right corner */
  body .elementor .elementor-element[data-id="790ab78e"] {
    left: auto; inset-inline-start: auto; right: 0; inset-inline-end: 0;
    top: 0; inset-block-start: 0; width: 420px; height: 253px; opacity: 1;
    background-size: 100% 100%; background-position: left top;
  }
  /* Coaching 'Ultimately, our goal' tear: smaller and further off the right edge */
  body .elementor [data-id="837bb27"] { width: 200px; height: 511px; inset-block-start: -120px; inset-inline-end: -90px; }
  /* Leadership Immersions 'How it works' tear: only its tip shows, below the text */
  body .elementor [data-id="7871744"] { inset-block-end: -440px; }
  /* FAQs: corner tears hidden on tablet (already hidden on mobile) */
  body .elementor [data-id="54627ddc"],
  body .elementor [data-id="22552af0"] { display: none; }
  /* Home 'The Authentic Leadership Journey' cards: two per row, left-aligned, never skinny */
  body .elementor .elementor-element[data-id="5a1ea527"] { justify-content: flex-start; }
  body .elementor [data-id="d28362b"],
  body .elementor [data-id="2a454ac1"],
  body .elementor [data-id="6d104af4"] { flex: 0 0 calc(50% - 13px); max-width: calc(50% - 13px); width: auto; }
}

/* Mobile */
@media (max-width: 767px) {
  body .elementor [data-id="837bb27"] { inset-inline-end: -120px; }
  body .elementor [data-id="7871744"] { inset-block-end: -290px; }
  /* Masterclasses hero collage: small, in the top-right corner */
  body .elementor .elementor-element[data-id="790ab78e"] {
    left: auto; inset-inline-start: auto; right: 0; inset-inline-end: 0;
    top: 0; inset-block-start: 0; width: 232px; height: 140px;
    background-size: 100% 100%; background-position: left top;
  }
}

/* Header: the page you're on is bold (class added by v3.js) */
body [data-elementor-type="header"] a.alg-current { font-weight: 600; }

/* ---------------------------------------------------------------------------------------------
   Masterclasses 'Masterclass Modules': arrows sit top-right, level with the bottom of the intro
   text, styled as in Figma (28px beige circles; an arrow that can't be used fades to 20%)
   --------------------------------------------------------------------------------------------- */
body .elementor [data-id="18baeb9"],
body .elementor [data-id="5f19a190"] {
  position: absolute; top: auto; inset-block-start: auto; bottom: calc(100% + 32px); inset-block-end: calc(100% + 32px);
  left: auto; inset-inline-start: auto; transform: none;
  width: 28px; height: 28px; min-width: 0; min-height: 0; padding: 0; margin: 0;
  border: 0; border-radius: 50%; box-shadow: none;
  background-color: #F0E7D4; background-repeat: no-repeat; background-position: center; background-size: 7px 12px;
  color: transparent; font-size: 0; line-height: 0;
  transition: opacity 0.2s ease, background-color 0.2s ease;
}
body .elementor [data-id="18baeb9"] {
  right: 32px; inset-inline-end: 32px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 6.9279 11.9958'%3E%3Cg%3E%3Cpath fill='%23000' d='M0.22 6.7179C0.0793078 6.57738 0.00017505 6.38674 0 6.1879V5.8079C0.00230401 5.60949 0.0811163 5.41962 0.22 5.2779L5.36 0.147899C5.45388 0.0532428 5.58168 0 5.715 0C5.84832 0 5.97612 0.0532428 6.07 0.147899L6.78 0.857899C6.87406 0.950063 6.92707 1.07621 6.92707 1.2079C6.92707 1.33959 6.87406 1.46574 6.78 1.5579L2.33 5.9979L6.78 10.4379C6.87466 10.5318 6.9279 10.6596 6.9279 10.7929C6.9279 10.9262 6.87466 11.054 6.78 11.1479L6.07 11.8479C5.97612 11.9426 5.84832 11.9958 5.715 11.9958C5.58168 11.9958 5.45388 11.9426 5.36 11.8479L0.22 6.7179Z'/%3E%3C/g%3E%3C/svg%3E");
}
body .elementor [data-id="5f19a190"] {
  right: 0; inset-inline-end: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 6.9279 11.9958'%3E%3Cg transform='matrix(-1 0 0 1 6.9279 0)'%3E%3Cpath fill='%23000' d='M0.22 6.7179C0.0793078 6.57738 0.00017505 6.38674 0 6.1879V5.8079C0.00230401 5.60949 0.0811163 5.41962 0.22 5.2779L5.36 0.147899C5.45388 0.0532428 5.58168 0 5.715 0C5.84832 0 5.97612 0.0532428 6.07 0.147899L6.78 0.857899C6.87406 0.950063 6.92707 1.07621 6.92707 1.2079C6.92707 1.33959 6.87406 1.46574 6.78 1.5579L2.33 5.9979L6.78 10.4379C6.87466 10.5318 6.9279 10.6596 6.9279 10.7929C6.9279 10.9262 6.87466 11.054 6.78 11.1479L6.07 11.8479C5.97612 11.9426 5.84832 11.9958 5.715 11.9958C5.58168 11.9958 5.45388 11.9426 5.36 11.8479L0.22 6.7179Z'/%3E%3C/g%3E%3C/svg%3E");
}
body .elementor [data-id="18baeb9"]:hover,
body .elementor [data-id="5f19a190"]:hover { background-color: #E6DAC0; color: transparent; }
@media (max-width: 767px) {
  /* keep the intro text clear of the arrows on phones */
  body .elementor .elementor-element[data-id="53116537"] { padding-inline-end: 72px; }
}

/* Leadership Immersions photo collage: gentle hover on each photo (no click-to-enlarge) */
body .elementor [data-id="3e58e420"] > * > * { transition: opacity 0.2s ease; }
body .elementor [data-id="3e58e420"] > * > *:hover { opacity: 0.88; }

/* Home: empty spacer above the footer collage */
body .elementor [data-id="d807ee7"] { display: none; }

/* ---------------------------------------------------------------------------------------------
   About: LinkedIn badges use the Figma LinkedIn icon ('in' cut out, so the card shows through)
   --------------------------------------------------------------------------------------------- */
body .elementor [data-id="534e16a4"],
body .elementor [data-id="a6026ac"],
body .elementor [data-id="74217e93"],
body .elementor [data-id="29e46dee"],
body .elementor [data-id="734f537e"],
body .elementor [data-id="7558f9d7"] {
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20.9488 20.9488'%3E%3Cpath fill='%23000' fill-rule='evenodd' d='M16.5841 2.61865H4.3639C3.39976 2.61865 2.61816 3.40025 2.61816 4.36439V16.5845C2.61816 17.5487 3.39976 18.3303 4.3639 18.3303H16.5841C17.5482 18.3303 18.3298 17.5487 18.3298 16.5845V4.36439C18.3298 3.40025 17.5482 2.61865 16.5841 2.61865ZM7.41894 15.2752C7.41894 15.5163 7.22354 15.7117 6.98251 15.7117H5.6732C5.43217 15.7117 5.23677 15.5163 5.23677 15.2752V9.16516C5.23677 8.92413 5.43217 8.72873 5.6732 8.72873H6.98251C7.22354 8.72873 7.41894 8.92413 7.41894 9.16516V15.2752ZM6.32785 7.85586C5.60475 7.85586 5.01855 7.26967 5.01855 6.54656C5.01855 5.82345 5.60475 5.23726 6.32785 5.23726C7.05096 5.23726 7.63716 5.82345 7.63716 6.54656C7.63716 7.26967 7.05096 7.85586 6.32785 7.85586ZM15.7112 15.2752C15.7112 15.5163 15.5158 15.7117 15.2748 15.7117H13.9655C13.7244 15.7117 13.529 15.5163 13.529 15.2752V12.002C13.529 11.2789 12.9428 10.6927 12.2197 10.6927C11.4966 10.6927 10.9104 11.2789 10.9104 12.002V15.2752C10.9104 15.5163 10.715 15.7117 10.474 15.7117H9.16468C8.92364 15.7117 8.72824 15.5163 8.72824 15.2752V9.16516C8.72824 8.92413 8.92364 8.72873 9.16468 8.72873H10.474C10.715 8.72873 10.9104 8.92413 10.9104 9.16516V9.68889C11.4413 8.88096 12.3742 8.4313 13.337 8.51924C14.714 8.68903 15.7395 9.87286 15.7112 11.26V15.2752Z'/%3E%3C/svg%3E") no-repeat center / 100% 100%;
  background-color: transparent;
  color: transparent;
  font-size: 0;
  border-radius: 0;
}
body .elementor [data-id="534e16a4"] a,
body .elementor [data-id="a6026ac"] a,
body .elementor [data-id="74217e93"] a,
body .elementor [data-id="29e46dee"] a,
body .elementor [data-id="734f537e"] a,
body .elementor [data-id="7558f9d7"] a { display: block; width: 100%; height: 100%; color: transparent; font-size: 0; }

/* About: team photos fade gently from black-and-white to colour (layer added by v3.js) */
.alg-team-colour {
  position: absolute; inset: 0; z-index: 0;
  opacity: 0; transition: opacity 0.9s ease;
  pointer-events: none; border-radius: inherit;
}
[data-alg-team]:hover > .alg-team-colour,
[data-alg-team]:focus-within > .alg-team-colour { opacity: 1; }
@media (prefers-reduced-motion: reduce) { .alg-team-colour { transition-duration: 0.01s; } }

/* Masterclasses 'A masterclass experience may include': image layers swapped by v3.js */
.alg-exp-layer {
  position: absolute; inset: 0;
  background-size: cover; background-position: center; background-repeat: no-repeat;
  opacity: 0; transition: opacity 0.45s ease; pointer-events: none;
}
.alg-exp-layer.is-on { opacity: 1; }

/* ---------------------------------------------------------------------------------------------
   Screens wider than the 1440 design
   --------------------------------------------------------------------------------------------- */
@media (min-width: 1025px) {
  /* Leadership Immersions hero: tear keeps its 1440 size, anchored top-right, instead of growing
     until only its empty top shows */
  body .elementor .elementor-element[data-id="57d9578b"] { background-size: min(77.3%, 1100px) auto; }
}
@media (min-width: 1441px) {
  /* Leadership Immersions case study: the tear was exported cut at the design's right edge, so keep
     that cut edge on the screen edge */
  body .elementor [data-id="3ba2a12a"] { left: auto; inset-inline-start: auto; right: calc((100% - 100vw) / 2); }
  /* Coaching CTA: the bottom tear strip grows with the screen so its torn top edge is never cropped;
     the section's bottom padding grows with it */
  body .elementor .elementor-element[data-id="47800f9c"] { padding-block-end: calc(68px + 11.17vw); }
  body .elementor [data-id="5eb6c51c"] { top: auto; inset-block-start: auto; height: 11.17vw; }
}
