/* Community pages: polished layout + styled sidebar + FAQ accordion. */
body .wp-block-post-content:has(> .pb-community-layout) {
  max-width: none;
  width: 100%;
}

.pb-community-layout {
  box-sizing: border-box;
  width: min(1180px, calc(100% - 40px));
  max-width: 1180px;
  margin: 42px auto 76px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 330px);
  align-items: start;
  gap: clamp(28px, 4vw, 54px);
  font-family: inherit;
}

.pb-community-content {
  min-width: 0;
  overflow-wrap: anywhere;
}

.pb-community-content > :first-child { margin-top: 0; }
.pb-community-content > * + * { margin-top: 1rem; }

.pb-community-content h1,
.pb-community-content h2,
.pb-community-content h3 {
  color: #1257a1;
  line-height: 1.18;
  letter-spacing: -0.02em;
}

.pb-community-content h1 {
  font-size: clamp(2rem, 3.2vw, 3rem);
  margin: 0 0 1rem;
}

.pb-community-content h2 {
  font-size: clamp(1.65rem, 2.2vw, 2.2rem);
  margin-top: 2.2rem;
  margin-bottom: 1rem;
}

.pb-community-content h3 {
  font-size: clamp(1.3rem, 1.8vw, 1.55rem);
  margin-top: 2rem;
  margin-bottom: .9rem;
}

.pb-community-content p,
.pb-community-content li {
  color: #2d3748;
  line-height: 1.8;
  font-size: 1rem;
}

.pb-community-content ul,
.pb-community-content ol {
  padding-left: 1.3rem;
  margin: 1rem 0 1.25rem;
}

.pb-community-content ul li::marker,
.pb-community-content ol li::marker {
  color: #1257a1;
}

.pb-community-content a {
  color: #1257a1;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}
.pb-community-content a:hover { color: #0f4b89; }

.pb-community-content img {
  max-width: 100%;
  height: auto;
  border-radius: 14px;
  box-shadow: 0 12px 28px rgba(16, 38, 73, 0.08);
}

.pb-community-content::after {
  content: '';
  display: block;
  clear: both;
}

/* FAQ / details styling */
.pb-community-content details {
  border: 1px solid #d9e5f0;
  border-radius: 12px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(18, 87, 161, 0.05);
  overflow: hidden;
  margin: 0 0 14px;
}

.pb-community-content details summary {
  list-style: none;
  cursor: pointer;
  position: relative;
  padding: 16px 52px 16px 18px;
  font-weight: 700;
  color: #173e6a;
  line-height: 1.5;
}
.pb-community-content details summary::-webkit-details-marker { display: none; }
.pb-community-content details summary::after {
  content: '+';
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: #edf4fb;
  color: #1257a1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  font-weight: 800;
}
.pb-community-content details[open] summary {
  background: linear-gradient(180deg, #f8fbff 0%, #f1f7fd 100%);
  border-bottom: 1px solid #d9e5f0;
}
.pb-community-content details[open] summary::after { content: '−'; }
.pb-community-content details > *:not(summary) {
  padding: 16px 18px 18px;
  margin: 0;
}
.pb-community-content details > p:last-child { margin-bottom: 0; }

/* Sidebar styling */
.pb-community-sidebar {
  min-width: 0;
  padding: 22px;
  background: linear-gradient(180deg, #f7faff 0%, #f1f6fd 100%);
  border: 1px solid #dbe5ef;
  border-radius: 18px;
  position: sticky;
  top: 110px;
  overflow-wrap: anywhere;
  box-shadow: 0 20px 40px rgba(16, 38, 73, 0.08);
}

.pb-community-sidebar a { color: #1257a1; }
.pb-community-sidebar .title,
.pb-community-sidebar .iLocalCommunity-title {
  display: block;
  margin: 0 0 12px;
  color: #6e7f93;
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.pb-community-sidebar .ilocal-community-container,
.pb-community-sidebar .ilocal-community-menu-search,
.pb-community-sidebar #iLocalCommunityMenuContainer,
.pb-community-sidebar .ilocal-community-menu {
  margin: 0 0 16px;
}

.pb-community-sidebar .iLocalCommunity-communityList,
.pb-community-sidebar #iLocalCommunityMenuContainer,
.pb-community-sidebar .ilocal-community-menu-search {
  background: #fff;
  border: 1px solid #e3ebf3;
  border-radius: 14px;
  padding: 16px;
}

.pb-community-sidebar .menu-items,
.pb-community-sidebar ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.pb-community-sidebar .menu-item + .menu-item,
.pb-community-sidebar li + li {
  margin-top: 8px;
}

.pb-community-sidebar .menu-item a,
.pb-community-sidebar li a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 10px;
  background: #f7faff;
  border: 1px solid #e7eef6;
  text-decoration: none;
  font-weight: 700;
  transition: all .2s ease;
}
.pb-community-sidebar .menu-item a::after,
.pb-community-sidebar li a::after {
  content: '›';
  font-size: 22px;
  line-height: 1;
  color: #7e93ab;
}
.pb-community-sidebar .menu-item a:hover,
.pb-community-sidebar li a:hover {
  background: #1257a1;
  border-color: #1257a1;
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 12px 24px rgba(18, 87, 161, 0.18);
}
.pb-community-sidebar .menu-item a:hover::after,
.pb-community-sidebar li a:hover::after {
  color: #fff;
}

.pb-community-sidebar .ilocal-community-menu-search {
  position: relative;
  padding: 12px 14px;
}
.pb-community-sidebar .search-icon {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 16px;
  opacity: .65;
}
.pb-community-sidebar input[type="text"],
.pb-community-sidebar .city-search-input,
.pb-community-sidebar input[type="search"] {
  width: 100%;
  border: 1px solid #d5e1ec;
  border-radius: 10px;
  padding: 12px 40px 12px 14px;
  font-size: .96rem;
  background: #fff;
  color: #173e6a;
  outline: none;
  box-sizing: border-box;
}
.pb-community-sidebar input[type="text"]:focus,
.pb-community-sidebar .city-search-input:focus,
.pb-community-sidebar input[type="search"]:focus {
  border-color: #1257a1;
  box-shadow: 0 0 0 4px rgba(18, 87, 161, 0.12);
}
.pb-community-sidebar input::placeholder { color: #8da0b2; }

@media (max-width: 980px) {
  .pb-community-layout {
    grid-template-columns: minmax(0, 1fr);
    width: calc(100% - 32px);
    margin-top: 28px;
  }
  .pb-community-sidebar {
    position: static;
    order: -1;
  }
}

@media (max-width: 640px) {
  .pb-community-content img[style*="float"] {
    float: none !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 12px 0 18px !important;
  }
  .pb-community-content h1 { font-size: 2rem; }
  .pb-community-sidebar { padding: 18px; border-radius: 14px; }
  .pb-community-content details summary { padding-right: 46px; }
}


/* ==========================================
   PRICE BUSTERS - CLEAN COMMUNITY SIDEBAR
   ========================================== */

/* ONE MAIN SIDEBAR CARD */
.pb-community-layout {
  padding: 75px 20px;
}
.pb-community-layout .pb-community-sidebar {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 12px !important;
    padding: 24px !important;
    box-shadow: 0 8px 28px rgba(0, 40, 90, 0.06) !important;
    position: sticky;
    top: 119px;
    min-width: 0;
}

/* RESET NESTED BACKGROUNDS AND BOXES */
.pb-community-sidebar #iLocalCommunityMenu,
.pb-community-sidebar .ilocal-community-menu-wrapper,
.pb-community-sidebar .ilocal-community-menu,
.pb-community-sidebar .ilocal-community-container,
.pb-community-sidebar .iLocalCommunity-communityList {
    background: transparent !important;
    background-image: none !important;
    border: none !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    width: 100% !important;
    min-height: 0 !important;
}

/* CITY HEADING */
.pb-community-sidebar .iLocalCommunity-communityList .title {
    display: block !important;
    color: #1257a1 !important;
    font-size: 17px !important;
    font-weight: 800 !important;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 0 0 12px !important;
    margin: 0 0 16px !important;
    border: none !important;
    border-bottom: 2px solid #ff6f16 !important;
    background: transparent !important;
}

/* CLEAN CITY LINKS */
.pb-community-sidebar .menu-items {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
    background: transparent !important;
    border: 0 !important;
}

.pb-community-sidebar .menu-item {
    list-style: none !important;
    margin: 0 0 8px !important;
    padding: 0 !important;
    background: transparent !important;
    border: none !important;
}

/* SINGLE LINK BACKGROUND */
.pb-community-sidebar .menu-item a {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    box-sizing: border-box;
    padding: 13px 15px !important;
    background: #f4f8fc !important;
    border: 1px solid #e0eaf4 !important;
    border-radius: 8px !important;
    box-shadow: none !important;
    color: #1257a1 !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    text-decoration: none !important;
    transition: 0.2s ease;
}

.pb-community-sidebar ul.menu-items li.menu-item.menu-parent a::after {
    content: "\203A";
    font-size: 22px;
    color: #1257a1;
    line-height: 1;
    transform: unset;
    border: 0px;
    width: auto;
    height: auto;
    top: auto;
}

.pb-community-sidebar .menu-item a:hover {
    background: #1257a1 !important;
    border-color: #1257a1 !important;
    color: #ffffff !important;
}

.pb-community-sidebar .menu-item a:hover::after {
    color: #ffffff;
}

/* SEARCH - REMOVE EXTRA WHITE PILL */
.pb-community-sidebar .ilocal-community-menu-search {
    display: block !important;
    position: relative !important;
    width: 100% !important;
    box-sizing: border-box;
    background: transparent !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 20px 0 0 !important;
}

/* SEARCH INPUT */
.pb-community-sidebar #citySearchInput {
    display: block !important;
    width: 100% !important;
    box-sizing: border-box;
    min-height: 44px;
    background: #ffffff !important;
    border: 1px solid #dce6f0 !important;
    border-radius: 8px !important;
    padding: 12px 42px 12px 14px !important;
    font-size: 14px !important;
    color: #334155 !important;
    outline: none;
    box-shadow: none !important;
}

.pb-community-sidebar #citySearchInput:focus {
    border-color: #1257a1 !important;
    box-shadow: 0 0 0 3px rgba(18,87,161,0.10) !important;
}

/* SEARCH ICON */
.pb-community-sidebar .search-icon {
    position: absolute !important;
    top: 50% !important;
    right: 14px !important;
    transform: translateY(-50%) !important;
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent !important;
    pointer-events: none;
}

.pb-community-sidebar .search-icon img {
    width: 17px !important;
    height: 17px !important;
}

/* DYNAMIC SEARCH RESULTS */
.pb-community-sidebar #iLocalCommunityMenuContainer {
    background: transparent !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 12px 0 0 !important;
    min-height: 0 !important;
}

/* HIDE EMPTY RESULTS CONTAINER */
.pb-community-sidebar #iLocalCommunityMenuContainer:empty {
    display: none !important;
}

/* MOBILE */
@media (max-width: 900px) {
    .pb-community-layout .pb-community-sidebar {
        position: static !important;
        padding: 20px !important;
    }
}

/* v4.1: style iLocal AJAX drill-down navigation consistently. */
.pb-community-sidebar #iLocalCommunityMenuContainer .iLocalCommunity-communityList {
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 0 !important;
}
.pb-community-sidebar #iLocalCommunityMenuContainer .title {
    display: block !important;
    margin: 20px 0 16px !important;
    padding: 0 0 12px !important;
    border: 0 !important;
    border-bottom: 2px solid #ff6f16 !important;
    color: #1257a1 !important;
    font-size: 17px !important;
    line-height: 1.35 !important;
    font-weight: 800 !important;
    text-transform: uppercase;
    letter-spacing: .02em;
}
.pb-community-sidebar #iLocalCommunityMenuContainer .menu-items {
    padding: 0 !important;
    margin: 0 !important;
    list-style: none !important;
}
.pb-community-sidebar #iLocalCommunityMenuContainer .menu-item {
    padding: 0 !important;
    margin: 0 0 9px !important;
    list-style: none !important;
}
.pb-community-sidebar #iLocalCommunityMenuContainer .menu-item a {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 13px 15px !important;
    border: 1px solid #e0eaf4 !important;
    background: #f4f8fc !important;
    color: #1257a1 !important;
    border-radius: 8px !important;
    text-decoration: none !important;
    box-shadow: none !important;
    font-size: 14px !important;
    font-weight: 700 !important;
}
.pb-community-sidebar #iLocalCommunityMenuContainer .menu-item a:hover,
.pb-community-sidebar #iLocalCommunityMenuContainer .menu-item a:focus-visible {
    background: #1257a1 !important;
    border-color: #1257a1 !important;
    color: #fff !important;
}
.pb-community-sidebar #iLocalCommunityMenuContainer .menu-item a:hover::after,
.pb-community-sidebar #iLocalCommunityMenuContainer .menu-item a:focus-visible::after {
    color: #fff !important;
}
/* A back button is a navigation control, not another card. */
.pb-community-sidebar #iLocalCommunityMenuContainer .action-back {
    margin: 0 0 12px !important;
}
.pb-community-sidebar #iLocalCommunityMenuContainer .aws-back {
    appearance: none !important;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: auto !important;
    min-height: 36px;
    padding: 8px 12px !important;
    border: 1px solid #dbe6f0 !important;
    background: #fff !important;
    color: #1257a1 !important;
    border-radius: 7px !important;
    box-shadow: none !important;
    font: inherit !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
    cursor: pointer;
}
.pb-community-sidebar #iLocalCommunityMenuContainer .aws-back:hover,
.pb-community-sidebar #iLocalCommunityMenuContainer .aws-back:focus-visible {
    background: #eef5fc !important;
    border-color: #1257a1 !important;
}
/* V4.2: prevent the browser/plugin blue focus ring on sidebar menu links.
   Maintain a subtle background cue for keyboard users instead. */
.pb-community-sidebar .menu-item a:focus,
.pb-community-sidebar .menu-item a:focus-visible,
.pb-community-sidebar #iLocalCommunityMenuContainer .menu-item a:focus,
.pb-community-sidebar #iLocalCommunityMenuContainer .menu-item a:focus-visible {
    outline: none !important;
    outline-offset: 0 !important;
    box-shadow: none !important;
    border-color: #e0eaf4 !important;
    background: #edf4fb !important;
    color: #1257a1 !important;
}
.pb-community-sidebar .menu-item a:focus::after,
.pb-community-sidebar .menu-item a:focus-visible::after {
    color: #1257a1 !important;
}
/* Keep a keyboard focus indication on actual form fields and navigation buttons. */
.pb-community-sidebar button:focus-visible,
.pb-community-sidebar input:focus-visible {
    outline: 2px solid #1257a1;
    outline-offset: 2px;
}


/* Community full-width CTA: outside the two-column grid, above the footer. */
.pb-community-bottom-cta {
    width: 100vw;
    max-width: none !important;
    margin: 0 0 0 calc(50% - 50vw) !important;
    position: relative;
    isolation: isolate;
    min-height: 460px;
    box-sizing: border-box;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: clamp(64px, 7vw, 100px) 24px;
    background-color: #123d70;
    background-image: linear-gradient(rgba(18, 61, 112, .82), rgba(18, 61, 112, .82)), var(--pb-community-cta-image);
    background-size: cover;
    background-position: center;
    color: #fff;
    text-align: center;
}
.pb-community-bottom-cta__inner {
    width: 100%;
    max-width: 760px;
    margin: 0 auto;
}
.pb-community-bottom-cta h2 {
    color: #fff !important;
    font-size: clamp(1.9rem, 3vw, 2.6rem);
    line-height: 1.2;
    font-weight: 800;
    margin: 0 0 22px;
}
.pb-community-bottom-cta p {
    font-size: clamp(1.1rem, 1.6vw, 1.35rem);
    line-height: 1.65;
    color: #fff !important;
    margin: 0 auto 26px;
}
.pb-community-bottom-cta__actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 14px;
}
.pb-community-bottom-cta__button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 800;
    text-decoration: none !important;
    transition: filter .2s ease, transform .2s ease;
}
.pb-community-bottom-cta__button:hover { filter: brightness(1.06); transform: translateY(-1px); }
.pb-community-bottom-cta__button--primary { background: #ff6f16; color: #fff !important; }
.pb-community-bottom-cta__button--secondary { background: #fff; color: #1257a1 !important; }
.pb-community-bottom-cta__button:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
@media(max-width:600px) {
  .pb-community-bottom-cta { min-height: 420px; padding: 62px 20px; }
  .pb-community-bottom-cta__actions { flex-direction: column; align-items: stretch; }
}

/* The CTA is rendered after the grid; avoid extra spacing below the grid. */
.pb-community-layout:has(+ .pb-community-bottom-cta) { margin-bottom: 0; }
