/* phpcs:ignoreFile */

/*
 * Styling for sticky header element
 * The `is-position-sticky` class is added by WordPress Group blocks with sticky positioning
 * Applies styles if a child of `site-header` has this class
*/
header.site-header:has(> .is-position-sticky) {
  --wp-admin--admin-bar--position-offset: var(--wp-admin--admin-bar--height, 0px);
  position: sticky;
  top: calc(0px + var(--wp-admin--admin-bar--position-offset, 0px));
  z-index: 10;
}

/*
 * If any of blocks within the main elements contains the `is-position-sticky
 * While the header is sticky, we need to add additional spacing to the top
 * So that the sticky element won't overlap with the header
*/
header.site-header:has(> .is-position-sticky)
  + main[class]
  .wp-block-group.is-position-sticky {
  --wp-admin--admin-bar--position-offset: var(--wp-admin--admin-bar--height, 0px);
  position: sticky;
  top: calc(90px + var(--wp-admin--admin-bar--position-offset, 0px));

  /* Need to lower the stacking than the default one (which is 10) */
  z-index: 9;
}

/*
 * We need to re-assign the position of header on the editor page
 * So that it won't position itself a bit lower than the top
 */
body.block-editor-page header.site-header:has(> .is-position-sticky) {
  --wp-admin--admin-bar--position-offset: 0px;
}

/* Styling for the BBC icons */
:where(
  .apt-singlecasestudy-bed,
  .apt-singlecasestudy-bath,
  .apt-singlecasestudy-car,
  .apt-property-bed,
  .apt-property-bath,
  .apt-property-car
) {
  font-size: 0;
}

:where(
  .apt-singlecasestudy-bed,
  .apt-singlecasestudy-bath,
  .apt-singlecasestudy-car,
  .apt-property-bed,
  .apt-property-bath,
  .apt-property-car
)::before {
  content: "";
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  background: var(--wp--preset--color--text-primary);
  mask-size: contain;
  mask-position: center;
  mask-repeat: no-repeat;
}

.apt-singlecasestudy-bed::before,
.apt-property-bed::before {
  mask-image: url("data:image/svg+xml,%0A%3Csvg width='28' height='28' viewBox='0 0 28 28' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Crect width='28' height='28' rx='4' fill='none'/%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M6 6C6 5.44772 5.55228 5 5 5C4.44772 5 4 5.44772 4 6V22C4 22.5523 4.44772 23 5 23C5.55228 23 6 22.5523 6 22V20H22V22C22 22.5523 22.4477 23 23 23C23.5523 23 24 22.5523 24 22V17C24 16.4477 23.5523 16 23 16H6V6ZM12 13C12 14.1046 11.1046 15 10 15C8.89543 15 8 14.1046 8 13C8 11.8954 8.89543 11 10 11C11.1046 11 12 11.8954 12 13ZM14 11H20C22.2091 11 24 12.7909 24 15H14V11Z' fill='currentColor'/%3E%3C/svg%3E%0A");
}

.apt-singlecasestudy-bath,
.apt-property-bath {
  mask-image: url("data:image/svg+xml,%0A%3Csvg width='28' height='28' viewBox='0 0 28 28' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Crect width='28' height='28' rx='4' fill='none'/%3E%3Cpath d='M22.5714 16.1429V18.2857C22.5714 19.5432 22.0952 20.6071 21.1429 21.4777V23.6429C21.1429 23.747 21.1094 23.8326 21.0424 23.8996C20.9754 23.9665 20.8899 24 20.7857 24H20.0714C19.9673 24 19.8817 23.9665 19.8147 23.8996C19.7478 23.8326 19.7143 23.747 19.7143 23.6429V22.3259C19.2455 22.4896 18.7693 22.5714 18.2857 22.5714H9.71429C9.23065 22.5714 8.75446 22.4896 8.28571 22.3259V23.5536C8.28571 23.6801 8.25037 23.7861 8.17969 23.8717C8.109 23.9572 8.0253 24 7.92857 24H7.21429C7.11756 24 7.03385 23.9572 6.96317 23.8717C6.89249 23.7861 6.85714 23.6801 6.85714 23.5536V21.4777C5.90476 20.6071 5.42857 19.5432 5.42857 18.2857V16.1429H22.5714ZM24 14.3571V15.0714C24 15.1756 23.9665 15.2612 23.8996 15.3281C23.8326 15.3951 23.747 15.4286 23.6429 15.4286H4.35714C4.25298 15.4286 4.16741 15.3951 4.10045 15.3281C4.03348 15.2612 4 15.1756 4 15.0714V14.3571C4 14.253 4.03348 14.1674 4.10045 14.1004C4.16741 14.0335 4.25298 14 4.35714 14H5.42857V6.85714C5.42857 6.06845 5.70759 5.39509 6.26562 4.83705C6.82366 4.27902 7.49702 4 8.28571 4C9.08929 4 9.77381 4.29018 10.3393 4.87054C10.6815 4.72917 11.0461 4.68452 11.433 4.73661C11.8199 4.78869 12.1659 4.93378 12.471 5.17188L12.7165 4.92634C12.7984 4.84449 12.8802 4.84449 12.9621 4.92634L13.4308 5.39509C13.5126 5.47693 13.5126 5.55878 13.4308 5.64063L9.92634 9.14509C9.84449 9.22693 9.76265 9.22693 9.6808 9.14509L9.21205 8.67634C9.13021 8.59449 9.13021 8.51265 9.21205 8.4308L9.45759 8.18527C9.18973 7.84301 9.03906 7.4561 9.00558 7.02455C8.9721 6.59301 9.05952 6.19122 9.26786 5.8192C8.99256 5.55878 8.66518 5.42857 8.28571 5.42857C7.89137 5.42857 7.55469 5.56808 7.27567 5.8471C6.99665 6.12612 6.85714 6.4628 6.85714 6.85714V14H23.6429C23.747 14 23.8326 14.0335 23.8996 14.1004C23.9665 14.1674 24 14.253 24 14.3571Z' fill='currentColor'/%3E%3C/svg%3E%0A");
}

.apt-singlecasestudy-car,
.apt-property-car {
  mask-image: url("data:image/svg+xml,%0A%3Csvg width='28' height='28' viewBox='0 0 28 28' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Crect width='28' height='28' rx='4' fill='none'/%3E%3Cpath d='M5.12373 22H6.12092C6.74605 22 7.23599 21.5083 7.23599 20.8702V19.4213C9.11212 19.542 11.8243 19.6281 13.9957 19.6281C16.1757 19.6281 18.8879 19.542 20.764 19.4213V20.8702C20.764 21.5083 21.2457 22 21.8791 22H22.8763C23.5101 22 24 21.5083 24 20.8702V15.8935C24 14.4442 23.7127 13.6246 22.9271 12.5898L22.2172 11.6495C21.9047 10.0972 21.347 8.46683 21.0513 7.82869C20.6032 6.8538 19.7246 6.27565 18.6009 6.12071C18.0349 6.05152 16.1844 6 13.9957 6C11.816 6 9.9651 6.06036 9.39909 6.12071C8.27536 6.25872 7.39678 6.8538 6.94902 7.82832C6.6534 8.46683 6.09532 10.0972 5.78275 11.6495L5.0729 12.5898C4.28697 13.625 4 14.4442 4 15.8935V20.8702C4 21.5083 4.4903 22 5.12373 22ZM7.4898 10.9337C7.69241 9.98491 8.09799 8.75131 8.37667 8.25081C8.60487 7.84598 8.85003 7.67302 9.30644 7.61303C9.94816 7.51808 11.3848 7.46619 13.9957 7.46619C16.6152 7.46619 18.0515 7.50078 18.6939 7.61303C19.1417 7.68185 19.3865 7.84562 19.6233 8.25117C19.9107 8.74285 20.2906 9.98454 20.5102 10.9337C20.5866 11.2527 20.4597 11.3734 20.1302 11.3477C18.7278 11.2616 17.0547 11.1666 13.9957 11.1666C10.9457 11.1666 9.27255 11.2616 7.86978 11.3477C7.54027 11.3734 7.42202 11.2527 7.48944 10.9337M7.83553 17.3942C7.03302 17.3942 6.43312 16.773 6.43312 15.9623C6.43312 15.1427 7.03302 14.5307 7.83553 14.5307C8.6384 14.5307 9.2383 15.1427 9.2383 15.9623C9.2383 16.773 8.6384 17.3939 7.83589 17.3939M20.1641 17.3939C19.3612 17.3939 18.7617 16.7727 18.7617 15.9619C18.7617 15.1423 19.3612 14.5303 20.1641 14.5303C20.9583 14.5303 21.5665 15.1423 21.5665 15.9619C21.5665 16.7727 20.9583 17.3939 20.1641 17.3939ZM11.7569 16.9968C11.1653 16.9968 10.751 16.5655 10.751 15.9615C10.751 15.3492 11.1653 14.9267 11.7569 14.9267H16.2435C16.8347 14.9267 17.249 15.3492 17.249 15.9615C17.249 16.5651 16.8347 16.9968 16.2431 16.9968H11.7569Z' fill='currentColor'/%3E%3C/svg%3E%0A");
}

:where(.apt-singlecasestudy-featured-img) img {
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

/* Styling for the agent contact icons */
.ap-agents-phone,
.ap-agents-mobile,
.ap-agents-email {
  display: inline-flex;
  align-items: center;
}

.ap-agents-phone::before,
.ap-agents-mobile::before,
.ap-agents-email::before {
  content: "";
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  background: var(--wp--preset--color--additional-base-tertiary);
  mask-size: contain;
  mask-position: center;
  mask-repeat: no-repeat;
  vertical-align: 5px;
  margin-right: 12px;
}

.ap-agents-phone::before {
  mask-image: url("data:image/svg+xml,%0A%3Csvg width='32' height='32' viewBox='0 0 32 32' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M17.8752 25.7406C17.5047 25.5758 17.1398 25.3985 16.7811 25.2091C14.9951 24.1993 13.3548 22.9511 11.9055 21.4988C10.0244 19.728 8.47927 17.6314 7.34496 15.3103C6.73746 14.0632 6.32745 12.7292 6.12961 11.3562C5.85993 9.96964 6.01322 8.53403 6.56961 7.23567C6.91328 6.67675 7.32712 6.1654 7.80042 5.7147C7.99252 5.49932 8.22617 5.32499 8.48733 5.20217C8.7485 5.07935 9.03179 5.01059 9.3202 5C9.92074 5.09038 10.4642 5.40432 10.84 5.88238C11.6605 6.79448 12.5405 7.61502 13.4074 8.48194C13.7487 8.77448 13.9616 9.18951 13.9996 9.63783C13.9854 10.0148 13.8403 10.3751 13.5894 10.657C13.3016 11.022 12.952 11.3562 12.6178 11.7058C12.416 11.9003 12.2616 12.1387 12.1668 12.4025C12.0719 12.6662 12.0391 12.9483 12.0708 13.2268C12.2794 13.8785 12.6382 14.472 13.1185 14.9594C13.6964 15.7503 14.2732 16.4816 14.926 17.2558C16.0999 18.6124 17.4917 19.7639 19.0442 20.6628C19.2587 20.825 19.5124 20.9273 19.7795 20.9592C20.0465 20.9912 20.3172 20.9517 20.5639 20.8447C21.0799 20.5559 21.5382 20.1746 21.9161 19.7198C22.2431 19.3214 22.7116 19.0657 23.223 19.0051C23.6784 19.0288 24.1077 19.2239 24.424 19.5521C24.8331 19.9017 25.1827 20.3132 25.5633 20.6925C25.9426 21.0731 26.2471 21.3466 26.5658 21.6962C26.9475 22.0327 27.3078 22.3931 27.6444 22.776C27.906 23.1137 28.0297 23.5371 27.994 23.9616C27.8584 24.4698 27.5658 24.9221 27.158 25.2542C26.5846 25.851 25.8878 26.3153 25.1163 26.6148C24.3448 26.9142 23.5172 27.0416 22.6914 26.9881C21.0194 26.8941 19.3826 26.4701 17.8752 25.7406Z' stroke='%23003B44' stroke-width='1.5' stroke-miterlimit='10' stroke-linecap='round'/%3E%3C/svg%3E%0A");
}

.ap-agents-mobile::before {
  mask-image: url("data:image/svg+xml,%0A%3Csvg width='32' height='32' viewBox='0 0 32 32' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cmask id='path-1-inside-1_1237_14204' fill='white'%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M21 5.5H12C11.6022 5.5 11.2206 5.65804 10.9393 5.93934C10.658 6.22064 10.5 6.60218 10.5 7V25C10.5 25.3978 10.658 25.7794 10.9393 26.0607C11.2206 26.342 11.6022 26.5 12 26.5H21C21.3978 26.5 21.7794 26.342 22.0607 26.0607C22.342 25.7794 22.5 25.3978 22.5 25V7C22.5 6.60218 22.342 6.22064 22.0607 5.93934C21.7794 5.65804 21.3978 5.5 21 5.5ZM12 4C11.2044 4 10.4413 4.31607 9.87868 4.87868C9.31607 5.44129 9 6.20435 9 7V25C9 25.7957 9.31607 26.5587 9.87868 27.1213C10.4413 27.6839 11.2044 28 12 28H21C21.7957 28 22.5587 27.6839 23.1213 27.1213C23.6839 26.5587 24 25.7957 24 25V7C24 6.20435 23.6839 5.44129 23.1213 4.87868C22.5587 4.31607 21.7957 4 21 4H12Z'/%3E%3C/mask%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M21 5.5H12C11.6022 5.5 11.2206 5.65804 10.9393 5.93934C10.658 6.22064 10.5 6.60218 10.5 7V25C10.5 25.3978 10.658 25.7794 10.9393 26.0607C11.2206 26.342 11.6022 26.5 12 26.5H21C21.3978 26.5 21.7794 26.342 22.0607 26.0607C22.342 25.7794 22.5 25.3978 22.5 25V7C22.5 6.60218 22.342 6.22064 22.0607 5.93934C21.7794 5.65804 21.3978 5.5 21 5.5ZM12 4C11.2044 4 10.4413 4.31607 9.87868 4.87868C9.31607 5.44129 9 6.20435 9 7V25C9 25.7957 9.31607 26.5587 9.87868 27.1213C10.4413 27.6839 11.2044 28 12 28H21C21.7957 28 22.5587 27.6839 23.1213 27.1213C23.6839 26.5587 24 25.7957 24 25V7C24 6.20435 23.6839 5.44129 23.1213 4.87868C22.5587 4.31607 21.7957 4 21 4H12Z' fill='%23003B44'/%3E%3Cpath d='M21 5.5V1.5V5.5ZM12 5.5V1.5V5.5ZM10.5 7H6.5H10.5ZM12 4V0V4ZM9 7H5H9ZM9 25H5H9ZM21 1.5H12V9.5H21V1.5ZM12 1.5C10.5413 1.5 9.14236 2.07946 8.11091 3.11091L13.7678 8.76777C13.2989 9.23661 12.663 9.5 12 9.5V1.5ZM8.11091 3.11091C7.07946 4.14236 6.5 5.54131 6.5 7H14.5C14.5 7.66304 14.2366 8.29893 13.7678 8.76777L8.11091 3.11091ZM6.5 7V25H14.5V7H6.5ZM6.5 25C6.5 26.4587 7.07947 27.8576 8.11091 28.8891L13.7678 23.2322C14.2366 23.7011 14.5 24.337 14.5 25H6.5ZM8.11091 28.8891C9.14236 29.9205 10.5413 30.5 12 30.5V22.5C12.663 22.5 13.2989 22.7634 13.7678 23.2322L8.11091 28.8891ZM12 30.5H21V22.5H12V30.5ZM21 30.5C22.4587 30.5 23.8576 29.9205 24.8891 28.8891L19.2322 23.2322C19.7011 22.7634 20.337 22.5 21 22.5V30.5ZM24.8891 28.8891C25.9205 27.8576 26.5 26.4587 26.5 25H18.5C18.5 24.337 18.7634 23.7011 19.2322 23.2322L24.8891 28.8891ZM26.5 25V7H18.5V25H26.5ZM26.5 7C26.5 5.54131 25.9205 4.14236 24.8891 3.11091L19.2322 8.76777C18.7634 8.29892 18.5 7.66304 18.5 7H26.5ZM24.8891 3.11091C23.8576 2.07946 22.4587 1.5 21 1.5V9.5C20.337 9.5 19.7011 9.23661 19.2322 8.76777L24.8891 3.11091ZM12 0C10.1435 0 8.36301 0.737498 7.05025 2.05025L12.7071 7.70711C12.5196 7.89464 12.2652 8 12 8V0ZM7.05025 2.05025C5.7375 3.36301 5 5.14348 5 7H13C13 7.26522 12.8946 7.51957 12.7071 7.70711L7.05025 2.05025ZM5 7V25H13V7H5ZM5 25C5 26.8565 5.7375 28.637 7.05025 29.9497L12.7071 24.2929C12.8946 24.4804 13 24.7348 13 25H5ZM7.05025 29.9497C8.363 31.2625 10.1435 32 12 32V24C12.2652 24 12.5196 24.1054 12.7071 24.2929L7.05025 29.9497ZM12 32H21V24H12V32ZM21 32C22.8565 32 24.637 31.2625 25.9497 29.9497L20.2929 24.2929C20.4804 24.1054 20.7348 24 21 24V32ZM25.9497 29.9497C27.2625 28.637 28 26.8565 28 25H20C20 24.7348 20.1054 24.4804 20.2929 24.2929L25.9497 29.9497ZM28 25V7H20V25H28ZM28 7C28 5.14348 27.2625 3.36301 25.9497 2.05025L20.2929 7.70711C20.1054 7.51957 20 7.26522 20 7H28ZM25.9497 2.05025C24.637 0.737499 22.8565 0 21 0V8C20.7348 8 20.4804 7.89464 20.2929 7.70711L25.9497 2.05025ZM21 0H12V8H21V0Z' fill='%23003B44' mask='url(%23path-1-inside-1_1237_14204)'/%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M16.5 25C16.8978 25 17.2794 24.842 17.5607 24.5607C17.842 24.2794 18 23.8978 18 23.5C18 23.1022 17.842 22.7206 17.5607 22.4393C17.2794 22.158 16.8978 22 16.5 22C16.1022 22 15.7206 22.158 15.4393 22.4393C15.158 22.7206 15 23.1022 15 23.5C15 23.8978 15.158 24.2794 15.4393 24.5607C15.7206 24.842 16.1022 25 16.5 25Z' fill='%23003B44'/%3E%3C/svg%3E%0A");
}

.ap-agents-email::before {
  mask-image: url("data:image/svg+xml,%0A%3Csvg width='32' height='32' viewBox='0 0 32 32' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M10.7148 12.5706L16.4291 16.5706L22.1434 12.5706' stroke='%23003B44' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M5 21.7143V10.2857C5 9.02335 6.02335 8 7.28571 8H25.5714C26.8338 8 27.8571 9.02335 27.8571 10.2857V21.7143C27.8571 22.9767 26.8338 24 25.5714 24H7.28571C6.02335 24 5 22.9767 5 21.7143Z' stroke='%23003B44' stroke-width='1.5'/%3E%3C/svg%3E%0A");
}
