/* Community feed — match Join Community mock, Sky Paw theme */

.community-section {
  --comm-teal: var(--teal);
  --comm-teal-soft: rgba(24, 119, 242, 0.12);
  --comm-card: #fff;
  --comm-sky: #e7f0fe;
  --comm-surface: #f5fafd;
  position: relative;
  z-index: 0;
  padding: 8rem 0 3rem;
  margin: -6.75rem 0 0;
  width: 100%;
  /* Keep transparent — fixed graphics live on .community-bg */
  background: transparent;
}

/*
  Fixed pattern + soft sky wash.
  Color rises gradually (no solid top band). Pattern stays fixed.
*/
.community-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-color: transparent;
  background-image:
    url("../assets/images/ui/community-bg-pattern.svg"),
    linear-gradient(
      180deg,
      rgba(231, 240, 254, 0) 0%,
      rgba(231, 240, 254, 0.18) 16%,
      rgba(231, 240, 254, 0.48) 34%,
      rgba(231, 240, 254, 0.82) 55%,
      #e7f0fe 72%,
      #e7f0fe 100%
    ),
    radial-gradient(ellipse 95% 70% at 50% 18%, rgba(187, 212, 252, 0.38), transparent 62%),
    radial-gradient(ellipse 85% 55% at 50% 100%, rgba(24, 119, 242, 0.12), transparent 58%);
  background-size: 400px 400px, 100% 100%, 100% 100%, 100% 100%;
  background-repeat: repeat, no-repeat, no-repeat, no-repeat;
  background-position: center top, center top, center top, center bottom;
  /* Pattern fixed; color wash scrolls with the section so the seam stays smooth */
  background-attachment: fixed, scroll, fixed, fixed;
  -webkit-mask-image: linear-gradient(
    180deg,
    transparent 0%,
    rgba(0, 0, 0, 0.06) 12%,
    rgba(0, 0, 0, 0.28) 28%,
    rgba(0, 0, 0, 0.62) 48%,
    rgba(0, 0, 0, 0.9) 68%,
    #000 82%,
    #000 100%
  );
  mask-image: linear-gradient(
    180deg,
    transparent 0%,
    rgba(0, 0, 0, 0.06) 12%,
    rgba(0, 0, 0, 0.28) 28%,
    rgba(0, 0, 0, 0.62) 48%,
    rgba(0, 0, 0, 0.9) 68%,
    #000 82%,
    #000 100%
  );
}

/* Long soft seam: shop white → surface → sky (past the community title) */
.community-section::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 24rem;
  pointer-events: none;
  z-index: 2;
  background: linear-gradient(
    180deg,
    #ffffff 0%,
    rgba(255, 255, 255, 0.94) 12%,
    rgba(248, 252, 255, 0.82) 26%,
    rgba(245, 250, 253, 0.58) 42%,
    rgba(231, 240, 254, 0.28) 62%,
    rgba(231, 240, 254, 0.1) 80%,
    transparent 100%
  );
}

.community-section::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 11rem;
  pointer-events: none;
  z-index: 2;
  background: linear-gradient(
    180deg,
    rgba(231, 240, 254, 0) 0%,
    rgba(255, 255, 255, 0.45) 38%,
    rgba(255, 255, 255, 0.88) 72%,
    #ffffff 100%
  );
}

.community-section > .container,
.community-section > .community-shell {
  position: relative;
  z-index: 3;
}
.community-section .container {
  max-width: var(--max, 1180px);
}

.community-head {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 760px;
  margin: 0 auto 1.75rem;
  padding: 0.5rem 1rem 0;
  text-align: center;
}
.community-head-glow {
  position: absolute;
  inset: -2.5rem -4rem -1rem;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(40% 55% at 30% 45%, rgba(24, 119, 242, 0.14), transparent 70%),
    radial-gradient(35% 50% at 72% 40%, rgba(247, 127, 0, 0.12), transparent 70%),
    radial-gradient(30% 45% at 50% 80%, rgba(46, 160, 67, 0.1), transparent 70%);
  filter: blur(6px);
}
.community-head-paw {
  position: absolute;
  z-index: -1;
  width: 34px;
  height: 34px;
  opacity: 0.22;
  pointer-events: none;
  animation: community-paw-float 7s ease-in-out infinite;
}
.community-head-paw--l {
  top: 1.4rem;
  left: 2%;
  transform: rotate(-22deg);
}
.community-head-paw--r {
  top: 3.6rem;
  right: 3%;
  width: 26px;
  height: 26px;
  transform: rotate(18deg);
  animation-delay: -3.5s;
}
@keyframes community-paw-float {
  0%, 100% { translate: 0 0; }
  50% { translate: 0 -8px; }
}
.community-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.32rem 0.85rem 0.32rem 0.7rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(24, 119, 242, 0.18);
  box-shadow: 0 6px 18px -8px rgba(24, 119, 242, 0.45);
  backdrop-filter: blur(6px);
  color: #1457d0;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.community-eyebrow-dot {
  position: relative;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22c55e;
}
.community-eyebrow-dot::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: #22c55e;
  animation: community-live 1.8s ease-out infinite;
}
@keyframes community-live {
  from { transform: scale(1); opacity: 0.7; }
  to { transform: scale(2.6); opacity: 0; }
}
.community-head h2 {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.2rem 0.65rem;
  margin: 0.85rem 0 0.5rem;
  font-family: var(--display, var(--font));
  font-size: clamp(1.7rem, 3.4vw, 2.5rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.025em;
  color: #0f2a4f;
}
.community-head-logo {
  display: block;
  width: auto;
  height: 1.55em;
  margin-block: -0.1em;
  filter: drop-shadow(0 6px 14px rgba(15, 42, 79, 0.16));
  transition: transform 0.3s ease;
}
.community-head:hover .community-head-logo {
  transform: rotate(-2deg) scale(1.03);
}
.community-head-accent {
  background: linear-gradient(100deg, #1877f2 0%, #7c5cdb 45%, #f77f00 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.community-head p {
  margin: 0;
  max-width: 46ch;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.55;
}
.community-head-chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem;
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
}
.community-head-chips li {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.42rem 0.9rem;
  border-radius: 999px;
  background: #fff;
  border: 1px solid rgba(15, 42, 79, 0.08);
  box-shadow: 0 6px 16px -10px rgba(15, 42, 79, 0.35);
  color: #33475f;
  font-size: 0.82rem;
  font-weight: 650;
}
.community-head-chips svg {
  width: 16px;
  height: 16px;
}
.community-head-chips li:nth-child(1) svg { color: #1877f2; }
.community-head-chips li:nth-child(2) svg { color: #7c5cdb; }
.community-head-chips li:nth-child(3) svg { color: #f77f00; }
@media (max-width: 560px) {
  .community-head-paw { display: none; }
  .community-head-logo { height: 1.15em; }
}
@media (prefers-reduced-motion: reduce) {
  .community-head-paw,
  .community-eyebrow-dot::after { animation: none; }
}

/* Compact, aligned community intro + compose on mobile */
@media (max-width: 640px) {
  .community-section {
    margin-top: -3.25rem;
    padding: 4.75rem 0 1.75rem;
  }
  .community-section::before {
    height: 12rem;
  }
  .community-head {
    margin: 0 auto 0.95rem;
    padding: 0 0.15rem;
    max-width: none;
  }
  .community-head-glow {
    inset: -1rem -0.5rem -0.35rem;
    filter: blur(5px);
    opacity: 0.8;
  }
  .community-eyebrow {
    font-size: 0.64rem;
    letter-spacing: 0.06em;
    padding: 0.24rem 0.7rem 0.24rem 0.55rem;
    gap: 0.35rem;
  }
  .community-head h2 {
    margin: 0.5rem 0 0.3rem;
    font-size: clamp(1.28rem, 6vw, 1.55rem);
    gap: 0.1rem 0.35rem;
    line-height: 1.12;
  }
  .community-head p {
    font-size: 0.86rem;
    line-height: 1.4;
    max-width: 32ch;
  }
  .community-head-chips {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    width: 100%;
    gap: 0.4rem;
    margin: 0.7rem 0 0;
  }
  .community-head-chips li {
    justify-content: center;
    width: 100%;
    box-sizing: border-box;
    padding: 0.4rem 0.3rem;
    font-size: 0.7rem;
    gap: 0.25rem;
    box-shadow: 0 4px 12px -8px rgba(15, 42, 79, 0.3);
  }
  .community-head-chips svg {
    width: 13px;
    height: 13px;
    flex-shrink: 0;
  }

  .compose-v2 {
    gap: 0.55rem;
    padding: 0.8rem 0.8rem 0.75rem;
    margin-bottom: 0.6rem;
  }
  .compose-v2-row {
    gap: 0.55rem;
    align-items: center;
  }
  .compose-v2 .avatar {
    width: 38px;
    height: 38px;
    font-size: 0.82rem;
  }
  .compose-v2-field {
    min-height: 42px;
    padding: 0.55rem 0.9rem;
    font-size: 0.86rem;
  }
  .compose-v2-meta {
    /* Align under the field, matching avatar + gap offset */
    padding-left: calc(38px + 0.55rem);
    gap: 0.45rem;
    flex-wrap: wrap;
  }
  .compose-tools {
    gap: 0.3rem;
  }
  .compose-tools .compose-tool,
  .compose-tools button {
    min-width: 34px;
    height: 34px;
    padding: 0 0.45rem;
    border-radius: 9px;
    font-size: 0.8rem;
  }
  .compose-lock {
    font-size: 0.7rem;
    padding: 0.3rem 0.6rem;
    gap: 0.28rem;
    margin-left: 0;
  }
}

/* Shell wraps the community container (same width as before) */
.community-shell {
  display: block;
  width: 100%;
  max-width: var(--max, 1180px);
  margin: 0 auto;
  padding: 0 1rem;
  box-sizing: border-box;
}
.community-core {
  flex: none;
  min-width: 0;
  max-width: var(--max, 1180px);
}
.community-core.container {
  width: 100%;
  max-width: var(--max, 1180px);
  padding-left: 0;
  padding-right: 0;
}

.community-grid {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr) 280px;
  gap: 1rem;
  align-items: start;
}

@media (min-width: 1280px) {
  /* Wider sidebars; center feed stays ~620px so posts don't stretch */
  .community-grid {
    grid-template-columns: minmax(300px, 1fr) 620px minmax(320px, 1fr);
    gap: 1.25rem;
  }
}

.comm-card {
  background: var(--comm-card);
  border-radius: 14px;
  border: 1px solid rgba(42, 54, 66, 0.07);
  box-shadow: 0 8px 24px rgba(42, 54, 66, 0.05);
}

.comm-col-left,
.comm-col-right {
  position: sticky;
  top: calc(var(--nav-h) + 0.65rem);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  height: calc(100vh - var(--nav-h) - 1.25rem);
  max-height: calc(100vh - var(--nav-h) - 1.25rem);
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  /* Keep gutter reserved — fade thumb on hover instead of growing width */
  scrollbar-gutter: stable;
  scrollbar-width: thin;
  scrollbar-color: transparent transparent;
}
.comm-col-left:hover,
.comm-col-right:hover,
.comm-col-left:focus-within,
.comm-col-right:focus-within {
  scrollbar-color: rgba(24, 119, 242, 0.45) transparent;
}
.comm-col-left::-webkit-scrollbar,
.comm-col-right::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
.comm-col-left::-webkit-scrollbar-track,
.comm-col-right::-webkit-scrollbar-track {
  background: transparent;
}
.comm-col-left::-webkit-scrollbar-thumb,
.comm-col-right::-webkit-scrollbar-thumb {
  background: transparent;
  border-radius: 99px;
}
.comm-col-left:hover::-webkit-scrollbar-thumb,
.comm-col-right:hover::-webkit-scrollbar-thumb,
.comm-col-left:focus-within::-webkit-scrollbar-thumb,
.comm-col-right:focus-within::-webkit-scrollbar-thumb {
  background: rgba(24, 119, 242, 0.4);
}

/* —— Categories: grow with content; column scrolls —— */
.cat-panel {
  padding: 0;
  overflow: visible;
  display: flex;
  flex-direction: column;
  flex: 0 0 auto;
  min-height: 0;
  max-height: none;
}
.cat-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.9rem 0.85rem 0.6rem 1rem;
  margin: 0;
  flex-shrink: 0;
}
.cat-panel-head h3 {
  margin: 0;
  font-size: 1rem;
  font-weight: 800;
}
.cat-panel-all {
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  background: rgba(24, 119, 242, 0.08);
  font-size: 0.74rem;
  font-weight: 750;
  color: var(--teal-deep);
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease;
}
.cat-panel-all:hover {
  background: var(--teal);
  color: #fff;
}
.cat-scroll {
  flex: 0 0 auto;
  min-height: 0;
  max-height: none;
  overflow: visible;
  padding: 0 0.55rem 0.55rem;
}
.cat-nav {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.15rem;
}
.cat-nav a {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 0.55rem;
  border-radius: 10px;
  font-size: 0.9rem;
  font-weight: 650;
  color: var(--text);
}
.cat-nav a:hover { background: var(--comm-teal-soft); }
.cat-nav img {
  width: 36px;
  height: 36px;
  object-fit: cover;
  border-radius: 10px;
  flex-shrink: 0;
  background: rgba(15, 118, 110, 0.08);
}
.cat-nav .chev {
  margin-left: auto;
  color: var(--teal);
  font-size: 0.85rem;
  opacity: 0.75;
}

/* Expandable category tree (type → category → sub-sub) */
.cat-tree {
  margin: 0 0 0.5rem;
}
.cat-tree-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}
.cat-tree-node {
  border-radius: 12px;
}
.cat-tree-node.is-open > .cat-tree-expand {
  background: rgba(24, 119, 242, 0.08);
}
.cat-tree-expand {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.55rem 0.45rem 0.55rem 0.4rem;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 0.88rem;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s ease;
}
.cat-tree-expand:hover,
.cat-tree-expand--link:hover {
  background: var(--comm-teal-soft, rgba(24, 119, 242, 0.08));
}
.cat-tree-ico {
  width: 34px;
  height: 34px;
  object-fit: cover;
  border-radius: 10px;
  flex-shrink: 0;
  background: rgba(15, 118, 110, 0.08);
}
.cat-tree-name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  line-height: 1.25;
}
.cat-tree-count {
  flex-shrink: 0;
  min-width: 1.35rem;
  height: 1.35rem;
  padding: 0 0.35rem;
  border-radius: 999px;
  background: rgba(42, 54, 66, 0.08);
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 800;
  display: grid;
  place-items: center;
}
.cat-tree-chev {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  margin-left: 0.1rem;
  border-radius: 50%;
  background: rgba(24, 119, 242, 0.1);
  position: relative;
  transition: transform 0.2s ease, background 0.15s ease;
}
.cat-tree-chev::before {
  content: "";
  position: absolute;
  inset: 0;
  margin: auto;
  width: 6px;
  height: 6px;
  border-right: 2px solid var(--teal);
  border-bottom: 2px solid var(--teal);
  transform: rotate(-45deg) translate(-1px, -1px);
  box-sizing: border-box;
}
.cat-tree-chev.is-open {
  background: rgba(24, 119, 242, 0.2);
  transform: rotate(90deg);
}
.cat-tree-chev--go::before {
  width: 5px;
  height: 5px;
  transform: rotate(-45deg) translate(-1px, 0);
}
.cat-tree-expand .cat-tree-name {
  color: inherit;
  text-decoration: none;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.cat-tree-expand .cat-tree-name:hover {
  color: var(--teal);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.cat-tree-branch {
  list-style: none;
  margin: 0.15rem 0.55rem 0.35rem 1.15rem;
  padding: 0.15rem 0.35rem 0.15rem 0.55rem;
  border-left: 2px solid rgba(24, 119, 242, 0.14);
  display: grid;
  gap: 0.1rem;
  animation: catTreeOpen 0.22s ease;
}
.cat-tree-branch--leaf {
  margin: 0.1rem 0.35rem 0.25rem 0.85rem;
  padding: 0.1rem 0.25rem 0.1rem 0.45rem;
  border-left-color: rgba(42, 54, 66, 0.1);
}
@keyframes catTreeOpen {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: none; }
}
.cat-tree-node--cat .cat-tree-expand {
  font-size: 0.84rem;
  font-weight: 650;
  padding: 0.45rem 0.35rem 0.45rem 0.4rem;
}
.cat-tree-node--cat .cat-tree-ico {
  width: 28px;
  height: 28px;
  border-radius: 8px;
}
.cat-tree-node--cat .cat-tree-chev {
  background: rgba(42, 54, 66, 0.08);
}
.cat-tree-node--cat .cat-tree-chev::before {
  border-right-color: rgba(42, 54, 66, 0.45);
  border-bottom-color: rgba(42, 54, 66, 0.45);
}
.cat-tree-node--cat .cat-tree-chev.is-open {
  background: rgba(42, 54, 66, 0.14);
}
.cat-tree-node--cat.is-open > .cat-tree-expand {
  background: rgba(42, 54, 66, 0.05);
}
.cat-tree-leaf-link {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.4rem 0.45rem;
  border-radius: 10px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--muted);
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease;
}
.cat-tree-leaf-link:hover {
  background: rgba(24, 119, 242, 0.07);
  color: var(--text);
}
.cat-tree-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--teal);
  opacity: 0.55;
  flex-shrink: 0;
}
.cat-tree-node--footer {
  margin-top: 0.25rem;
  padding-top: 0.35rem;
  border-top: 1px dashed rgba(42, 54, 66, 0.1);
}
.cat-tree-node--footer .cat-tree-expand {
  font-weight: 750;
}
.cat-tree-node--ad {
  list-style: none;
  margin: 0.45rem 0 0.3rem;
  padding: 0;
}
.cat-tree-node--ad .ad-sidebar-card,
.cat-tree-node--ad .ad-unit {
  margin: 0;
}

/* Top-level pet types: accent-tinted tiles (--cat-accent set per row) */
.cat-tree-list {
  gap: 0.4rem;
}
.cat-tree-node--type {
  --cat-accent: var(--teal);
  --cat-soft: color-mix(in srgb, var(--cat-accent) 11%, #fff);
  --cat-line: color-mix(in srgb, var(--cat-accent) 18%, transparent);
}
.cat-tree-node--type > .cat-tree-expand {
  gap: 0.65rem;
  padding: 0.45rem 0.5rem 0.45rem 0.45rem;
  border: 1px solid var(--cat-line);
  border-radius: 14px;
  background: linear-gradient(105deg, var(--cat-soft) 0%, #fff 80%);
  transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}
.cat-tree-node--type > .cat-tree-expand:hover,
.cat-tree-node--type.is-open > .cat-tree-expand {
  background: linear-gradient(105deg, color-mix(in srgb, var(--cat-accent) 18%, #fff) 0%, #fff 88%);
  border-color: color-mix(in srgb, var(--cat-accent) 34%, transparent);
  box-shadow: 0 6px 16px color-mix(in srgb, var(--cat-accent) 14%, transparent);
}
.cat-tree-node--type > .cat-tree-expand:hover {
  transform: translateX(2px);
}
.cat-tree-node--type > .cat-tree-expand:focus-visible {
  outline: 2px solid var(--cat-accent);
  outline-offset: 2px;
}
.cat-tree-node--type > .cat-tree-expand .cat-tree-ico {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: var(--cat-soft);
  box-shadow:
    0 0 0 2px #fff,
    0 4px 10px color-mix(in srgb, var(--cat-accent) 24%, transparent);
  transition: transform 0.25s ease;
}
.cat-tree-node--type > .cat-tree-expand:hover .cat-tree-ico {
  transform: rotate(-4deg) scale(1.06);
}
.cat-tree-text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.08rem;
}
.cat-tree-node--type > .cat-tree-expand .cat-tree-name {
  flex: none;
  max-width: 100%;
  font-size: 0.9rem;
  font-weight: 800;
  color: #1d2b38;
}
.cat-tree-node--type > .cat-tree-expand .cat-tree-name:hover {
  color: var(--cat-accent);
}
.cat-tree-sub {
  font-size: 0.7rem;
  font-weight: 600;
  line-height: 1.3;
  color: #7a8898;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cat-tree-node--type > .cat-tree-expand .cat-tree-count {
  background: var(--cat-accent);
  color: #fff;
  box-shadow: 0 2px 6px color-mix(in srgb, var(--cat-accent) 30%, transparent);
}
.cat-tree-node--type > .cat-tree-expand .cat-tree-chev {
  width: 22px;
  height: 22px;
  background: #fff;
  box-shadow: 0 1px 3px rgba(15, 40, 72, 0.1);
}
.cat-tree-node--type > .cat-tree-expand .cat-tree-chev::before {
  border-right-color: var(--cat-accent);
  border-bottom-color: var(--cat-accent);
}
.cat-tree-node--type > .cat-tree-expand .cat-tree-chev.is-open {
  background: var(--cat-accent);
}
.cat-tree-node--type > .cat-tree-expand .cat-tree-chev.is-open::before {
  border-right-color: #fff;
  border-bottom-color: #fff;
}
.cat-tree-node--type .cat-tree-branch {
  border-left-color: var(--cat-line);
}
.cat-tree-node--type .cat-tree-dot {
  background: var(--cat-accent);
}
.cat-tree-node--type .cat-tree-node--cat > .cat-tree-expand:hover,
.cat-tree-node--type .cat-tree-leaf-link:hover {
  background: var(--cat-soft);
}

/* Expandable "Combo Offers" row (purple accent, preview of the first combos) */
.cat-tree-node--combo > .cat-tree-expand {
  background: linear-gradient(105deg, #f1eaff 0%, #f8f4ff 55%, #fff 100%);
}
.cat-tree-ico--emoji {
  display: grid;
  place-items: center;
  font-size: 1.3rem;
  line-height: 1;
}
.cat-tree-node--combo > .cat-tree-expand .cat-tree-ico--emoji {
  background: #fff;
}
.cat-combo-list {
  gap: 0.15rem;
}
.cat-combo-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.45rem 0.35rem 0.35rem;
  border-radius: 10px;
  color: var(--text);
  text-decoration: none;
  transition: background 0.15s ease;
}
.cat-combo-item:hover {
  background: var(--cat-soft);
}
.cat-combo-thumb {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
  border-radius: 8px;
  object-fit: cover;
  background: var(--cat-soft);
  box-shadow: inset 0 0 0 1px var(--cat-line);
}
.cat-combo-name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.8rem;
  font-weight: 650;
}
.cat-combo-price {
  flex-shrink: 0;
  font-size: 0.74rem;
  font-weight: 800;
  color: var(--cat-accent);
}
.cat-combo-all {
  display: inline-flex;
  align-items: center;
  margin: 0.15rem 0 0.1rem 0.35rem;
  font-size: 0.76rem;
  font-weight: 800;
  color: var(--cat-accent);
  text-decoration: none;
}
.cat-combo-all:hover {
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* Quick links under the tree */
.cat-tree-node--footer {
  margin-top: 0.3rem;
  padding-top: 0.6rem;
}
.cat-quick {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.45rem;
}
/* An unpaired last chip (odd count, e.g. when combos are off/on) spans the row */
.cat-quick > :last-child:nth-child(odd) {
  grid-column: 1 / -1;
}
.cat-quick-chip {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  min-width: 0;
  padding: 0.5rem;
  border-radius: 14px;
  color: #1d2b38;
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.cat-quick-chip:hover {
  transform: translateY(-1px);
}
.cat-quick-chip--hot {
  background: linear-gradient(135deg, #fff4e3 0%, #ffe4d4 100%);
  border: 1px solid rgba(228, 138, 31, 0.22);
}
.cat-quick-chip--hot:hover {
  box-shadow: 0 6px 16px rgba(228, 138, 31, 0.18);
}
.cat-quick-chip--club {
  background: linear-gradient(135deg, #ecf4ff 0%, #e3ebff 100%);
  border: 1px solid rgba(24, 119, 242, 0.18);
}
.cat-quick-chip--club:hover {
  box-shadow: 0 6px 16px rgba(24, 119, 242, 0.16);
}
.cat-quick-ico {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  border-radius: 9px;
  background: #fff;
  font-size: 0.9rem;
  box-shadow: 0 2px 6px rgba(15, 40, 72, 0.08);
}
.cat-quick-copy {
  display: flex;
  flex-direction: column;
  min-width: 0;
  line-height: 1.2;
}
.cat-quick-copy strong {
  font-size: 0.76rem;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cat-quick-copy small {
  font-size: 0.64rem;
  font-weight: 600;
  color: #7a8898;
}

/* Sponsored inside category column */
.ad-sponsored {
  margin: 0.55rem 0.55rem 0.35rem;
  padding: 0.85rem;
  border-radius: 16px;
  background: linear-gradient(170deg, #ffffff 0%, #f4f9ff 100%);
  border: 1px solid rgba(24, 119, 242, 0.14);
  box-shadow: 0 10px 24px rgba(42, 54, 66, 0.05);
  display: flex;
  flex-direction: column;
}
.ad-sponsored .label,
.ad-sponsored .ad-label {
  margin-bottom: 0.55rem;
}
.ad-sponsored img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 12px;
  display: block;
}
.ad-sponsored p {
  margin: 0.65rem 0 0.75rem;
  font-size: 0.82rem;
  font-weight: 650;
  line-height: 1.35;
  color: var(--text);
}
.ad-sponsored .btn,
.ad-sponsored .ad-cta {
  width: 100%;
}

.join-fb-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: 0.35rem 0.75rem 0.9rem;
  padding: 1rem 0.9rem 0.95rem;
  border-radius: 16px;
  border: 1px solid rgba(24, 119, 242, 0.08);
  background:
    radial-gradient(120% 80% at 0% 0%, rgba(255, 255, 255, 0.9) 0%, rgba(255, 255, 255, 0) 60%),
    linear-gradient(160deg, #f3f8ff 0%, #edf5fd 50%, #ecf8f3 100%);
  text-align: center;
  flex-shrink: 0;
  overflow: hidden;
  isolation: isolate;
}
.join-fb-card::after {
  content: "";
  position: absolute;
  right: -14px;
  bottom: -16px;
  width: 78px;
  height: 78px;
  background: url("/assets/logo-paw.svg") center / contain no-repeat;
  opacity: 0.06;
  transform: rotate(-18deg);
  pointer-events: none;
  z-index: -1;
}
.join-fb-badge {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  margin-bottom: 0.55rem;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 4px 12px rgba(24, 119, 242, 0.1);
}
.join-fb-badge img {
  width: 18px;
  height: 18px;
}
.join-fb-card .join-fb-title {
  margin: 0;
  max-width: 17rem;
  font-size: 0.84rem;
  font-weight: 700;
  color: #2f4458;
  line-height: 1.4;
}
.join-fb-card .join-fb-sub {
  margin: 0.25rem 0 0.8rem;
  font-size: 0.74rem;
  font-weight: 500;
  color: #6f8193;
  line-height: 1.4;
}
.join-fb-card button.btn {
  cursor: pointer;
  font: inherit;
}
.join-fb-card .join-fb-btn {
  width: 100%;
  gap: 0.45rem;
  padding: 0.55rem 0.9rem;
  border: 0;
  background: linear-gradient(180deg, #4b95f7 0%, #2b82f3 100%);
  color: #fff;
  font-weight: 650;
  font-size: 0.84rem;
  letter-spacing: 0.01em;
  box-shadow: 0 6px 16px rgba(24, 119, 242, 0.18);
}
.join-fb-card .join-fb-btn:hover {
  background: linear-gradient(180deg, #3f8cf5 0%, var(--teal) 100%);
  box-shadow: 0 8px 20px rgba(24, 119, 242, 0.24);
}
.join-fb-card .join-fb-btn img {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

/* —— Feed compose —— */
.compose-v2 {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  padding: 1.05rem 1.15rem 0.95rem;
  margin-bottom: 0.85rem;
  height: fit-content;
  align-self: start;
}
.compose-v2.compose-sticky {
  /* keep class for JS docking; do not stick — avoids empty gap over feed */
  position: relative;
  top: auto;
  z-index: 2;
}
.compose-v2-row {
  display: flex;
  gap: 0.75rem;
  align-items: center;
}
.compose-v2 .avatar {
  width: 44px;
  height: 44px;
  font-size: 0.95rem;
  margin-top: 0;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(24, 119, 242, 0.22);
}
.compose-v2-field {
  display: flex;
  align-items: center;
  flex: 1;
  min-width: 0;
  min-height: 48px;
  border: 1px solid rgba(42, 54, 66, 0.1);
  border-radius: 999px;
  padding: 0.75rem 1.1rem;
  background: #f3f6fb;
  color: var(--muted);
  font: inherit;
  font-size: 0.95rem;
  font-weight: 500;
  line-height: 1.35;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}
.compose-v2-field:hover {
  background: #eef3fa;
  border-color: rgba(24, 119, 242, 0.35);
  color: var(--text);
  box-shadow: 0 0 0 3px rgba(24, 119, 242, 0.08);
}
.compose-v2-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem 0.85rem;
  padding: 0 0.1rem;
  flex-wrap: nowrap;
}
.compose-lock {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.78rem;
  color: var(--muted);
  font-weight: 600;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  background: rgba(42, 54, 66, 0.04);
  white-space: nowrap;
  margin-left: auto;
}
.compose-tools {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}
.compose-tools .compose-tool,
.compose-tools button {
  border: 0;
  background: rgba(24, 119, 242, 0.06);
  min-width: 38px;
  height: 38px;
  padding: 0 0.65rem;
  border-radius: 10px;
  cursor: pointer;
  color: var(--teal-deep, #0f766e);
  font-size: 0.92rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: background 0.15s ease, transform 0.12s ease;
}
.compose-tools .compose-tool:hover,
.compose-tools button:hover {
  background: rgba(24, 119, 242, 0.14);
  transform: translateY(-1px);
}

/* mobile compose tightness lives with .community-head @media (max-width: 640px) above */

/* —— Posts —— */
.feed-post,
.post.feed-card {
  padding: 1.1rem 1.2rem 0.95rem;
  margin-bottom: 0.9rem;
}
.social-feed {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}
.social-feed > .feed-card,
.social-feed > .ad-inline,
.social-feed > .ad-unit {
  margin-bottom: 0.85rem;
}
.feed-comment-preview {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  padding: 0.55rem 0 0.1rem;
  border-top: 1px solid rgba(42, 54, 66, 0.06);
  margin-top: 0.35rem;
}
.feed-comment-row {
  display: flex;
  gap: 0.55rem;
  align-items: flex-start;
}
.feed-comment-bubble {
  flex: 1;
  min-width: 0;
  background: #f3f6f9;
  border-radius: 14px;
  padding: 0.5rem 0.75rem 0.55rem;
  text-align: left;
  font-size: 0.9rem;
  line-height: 1.45;
  color: #243442;
}
.feed-comment-bubble .name {
  font-weight: 750;
  font-size: 0.84rem;
  color: #163a66;
  display: inline-block;
  margin-right: 0.35rem;
}

.feed-product {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.6rem 0.7rem;
  margin: 0 0 0.65rem;
  border-radius: 12px;
  border: 1px solid rgba(24, 119, 242,0.25);
  background: linear-gradient(135deg, #f5f9ff, #e7f0fe);
}
.feed-product-link {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex: 1;
  min-width: 0;
  color: inherit;
  text-decoration: none;
}
.feed-product-link:hover strong {
  color: var(--teal-deep);
}
.feed-product img,
.feed-product-link img {
  width: 56px; height: 56px;
  border-radius: 10px;
  object-fit: cover;
  background: #fff;
  flex-shrink: 0;
}
.feed-product-copy { flex: 1; min-width: 0; }
.feed-product-copy strong {
  display: block;
  font-size: 0.88rem;
}
.feed-product-copy .meta {
  font-size: 0.75rem;
  color: var(--muted);
}
.feed-product-copy .price {
  font-weight: 800;
  color: var(--teal-deep);
  font-size: 0.95rem;
}
.feed-product-actions {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  flex-shrink: 0;
}
.feed-product-actions .btn,
.feed-product-actions .btn-primary,
.feed-product-actions .pcard-buy {
  flex: 0 0 auto !important;
  border-radius: 999px;
  padding: 0 0.65rem !important;
  min-height: 30px !important;
  height: 30px !important;
  max-height: 30px !important;
  line-height: 1 !important;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.01em;
  background: linear-gradient(180deg, var(--action) 0%, var(--action-deep) 100%);
  color: var(--action-text);
  border: 1px solid var(--action-border);
  box-shadow: 0 6px 14px rgba(245, 200, 74, 0.28);
  cursor: pointer;
}
.feed-product-actions .btn:hover,
.feed-product-actions .btn-primary:hover,
.feed-product-actions .pcard-buy:hover {
  filter: brightness(0.97);
  color: var(--action-text);
  cursor: pointer;
}
.feed-product-actions .pcard-buy {
  gap: 0.25rem;
}
.feed-product-actions .pcard-cart {
  flex: 0 0 auto;
  width: 30px !important;
  min-width: 30px !important;
  height: 30px !important;
  max-height: 30px !important;
  box-sizing: border-box;
  border-radius: 50%;
  background: linear-gradient(180deg, var(--action) 0%, var(--action-deep) 100%);
  border: 1px solid var(--action-border);
  box-shadow: 0 6px 14px rgba(245, 200, 74, 0.28);
  display: grid;
  place-items: center;
  padding: 0 !important;
  cursor: pointer;
}
.feed-product-actions .cart-ico img,
.feed-product-actions .pcard-cart img {
  width: 15px;
  height: 15px;
  border-radius: 0;
  background: transparent;
  pointer-events: none;
  filter: brightness(0) saturate(100%) invert(18%) sepia(18%) saturate(900%) hue-rotate(12deg) brightness(92%) contrast(92%);
}

/* Reactions row */
.react-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.35rem 0 0.5rem;
  border-bottom: 1px solid var(--line);
  font-size: 0.8rem;
  color: var(--muted);
}
.react-pills {
  display: flex;
  align-items: center;
  gap: 0.15rem;
}
.react-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px; height: 26px;
  border-radius: 50%;
  border: 2px solid #fff;
  font-size: 0.75rem;
  margin-left: -6px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}
.react-pill:first-child { margin-left: 0; }
.react-pill.like { background: #1877F2; color: #fff; }
.react-pill.heart { background: #e87a8a; color: #fff; }
.react-pill.wow { background: #e9b44c; color: #fff; }
.react-count { margin-left: 0.35rem; font-weight: 650; }

.action-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.25rem;
  padding: 0.25rem 0 0.15rem;
}
.action-row button {
  border: 0;
  background: transparent;
  padding: 0.55rem 0.35rem;
  border-radius: 10px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--muted);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
}
.action-row button:hover {
  background: var(--surface);
  color: var(--teal-deep);
}
.action-row button .ico { color: var(--teal); font-size: 1rem; }

.feed-comment-bar {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  padding: 0.75rem 1rem;
  margin-top: 0.25rem;
}
.feed-comment-bar input {
  flex: 1;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.6rem 0.9rem;
  background: var(--surface);
  font: inherit;
}
.feed-comment-bar .tools {
  display: flex;
  gap: 0.15rem;
}
.feed-comment-bar .tools button {
  border: 0;
  background: transparent;
  cursor: pointer;
  padding: 0.35rem;
  border-radius: 8px;
  color: var(--teal-deep);
}

.feed-comment-bubble .badge-waiting {
  display: inline-block;
  margin-top: 0.35rem;
}
.feed-comment-bubble .ep-comment-media {
  max-width: min(100%, 220px);
}
.feed-comment-bubble .ep-comment-media-sticker {
  width: 120px;
  height: auto;
}
.feed-comment-bubble .ep-comment-media-gif,
.feed-comment-bubble .ep-comment-media-photo {
  width: 168px;
  height: auto;
}

/* —— Right widgets —— */
/* Ads must not flex-shrink — overflow:hidden on the card would clip image/CTA to “Sponsored” only. */
.comm-col-left .ad-unit,
.comm-col-right .ad-unit,
.shop-sidebar-ad .ad-unit,
.comm-col-left .ad-sidebar-card,
.comm-col-right .ad-sidebar-card,
.shop-sidebar-ad .ad-sidebar-card {
  flex: 0 0 auto;
  min-height: 0;
  max-height: none;
}

/* Compact sponsored card: square thumb (full image, letterboxed) beside title + CTA */
.comm-col-left .ad-sidebar-card,
.comm-col-right .ad-sidebar-card,
.shop-sidebar-ad .ad-sidebar-card {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  grid-template-rows: auto 1fr 1fr;
  column-gap: 0.7rem;
  margin-top: 0;
  padding: 0.6rem 0.65rem 0.7rem;
  border-radius: 14px;
  box-shadow: 0 6px 16px rgba(42, 54, 66, 0.04);
}
.comm-col-left .ad-sidebar-card-label,
.comm-col-right .ad-sidebar-card-label,
.shop-sidebar-ad .ad-sidebar-card-label {
  grid-column: 1 / -1;
  margin-bottom: 0.5rem;
  font-size: 0.62rem;
}
.comm-col-left .ad-sidebar-card-label .ad-label-ico,
.comm-col-right .ad-sidebar-card-label .ad-label-ico,
.shop-sidebar-ad .ad-sidebar-card-label .ad-label-ico {
  width: 12px;
  height: 12px;
}
.comm-col-left .ad-sidebar-card-media,
.comm-col-right .ad-sidebar-card-media,
.shop-sidebar-ad .ad-sidebar-card-media {
  grid-column: 1;
  grid-row: 2 / span 2;
  width: 92px;
  aspect-ratio: 1;
  max-height: none;
  margin: 0;
  border-radius: 12px;
  border: 1px solid rgba(24, 119, 242, 0.1);
  background: #fff;
  overflow: hidden;
}
.comm-col-left .ad-sidebar-card-media > a,
.comm-col-right .ad-sidebar-card-media > a,
.shop-sidebar-ad .ad-sidebar-card-media > a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}
.comm-col-left .ad-sidebar-card-media img,
.comm-col-right .ad-sidebar-card-media img,
.shop-sidebar-ad .ad-sidebar-card-media img {
  width: 100%;
  height: 100%;
  max-height: none;
  padding: 0;
  object-fit: contain;
  transition: transform 0.3s ease;
}
.comm-col-left .ad-sidebar-card:hover .ad-sidebar-card-media img,
.comm-col-right .ad-sidebar-card:hover .ad-sidebar-card-media img,
.shop-sidebar-ad .ad-sidebar-card:hover .ad-sidebar-card-media img {
  transform: scale(1.04);
}
.comm-col-left .ad-sidebar-card-title,
.comm-col-right .ad-sidebar-card-title,
.shop-sidebar-ad .ad-sidebar-card-title {
  grid-column: 2;
  grid-row: 2;
  align-self: end;
  margin: 0;
  font-size: 0.84rem;
  font-weight: 750;
  line-height: 1.3;
  -webkit-line-clamp: 3;
  overflow-wrap: anywhere;
}
.comm-col-left .ad-sidebar-card .ad-cta,
.comm-col-right .ad-sidebar-card .ad-cta,
.shop-sidebar-ad .ad-sidebar-card .ad-cta {
  grid-column: 2;
  grid-row: 3;
  align-self: start;
  justify-self: start;
  width: auto;
  min-height: 1.75rem;
  margin: 0.45rem 0 0;
  padding: 0.25rem 0.8rem;
  border-radius: 999px;
  font-size: 0.74rem;
  white-space: nowrap;
  box-shadow: 0 4px 10px rgba(24, 119, 242, 0.08);
}
.comm-col-left .ad-sidebar-card-title:last-child,
.comm-col-right .ad-sidebar-card-title:last-child,
.shop-sidebar-ad .ad-sidebar-card-title:last-child {
  grid-row: 2 / span 2;
  align-self: center;
}
.comm-col-left .ad-sidebar-card > .ad-cta:not(.ad-sidebar-card-title + .ad-cta),
.comm-col-right .ad-sidebar-card > .ad-cta:not(.ad-sidebar-card-title + .ad-cta),
.shop-sidebar-ad .ad-sidebar-card > .ad-cta:not(.ad-sidebar-card-title + .ad-cta) {
  grid-row: 2 / span 2;
  align-self: center;
  margin-top: 0;
}
.comm-col-left .ad-sidebar-card-label + .ad-sidebar-card-title,
.comm-col-right .ad-sidebar-card-label + .ad-sidebar-card-title,
.shop-sidebar-ad .ad-sidebar-card-label + .ad-sidebar-card-title,
.comm-col-left .ad-sidebar-card-label + .ad-sidebar-card-title + .ad-cta,
.comm-col-right .ad-sidebar-card-label + .ad-sidebar-card-title + .ad-cta,
.shop-sidebar-ad .ad-sidebar-card-label + .ad-sidebar-card-title + .ad-cta,
.comm-col-left .ad-sidebar-card-label + .ad-cta,
.comm-col-right .ad-sidebar-card-label + .ad-cta,
.shop-sidebar-ad .ad-sidebar-card-label + .ad-cta {
  grid-column: 1 / -1;
}
.comm-col-right .activity-panel {
  flex: 0 0 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  padding: 0;
  overflow: visible;
}
.comm-col-right .faq-panel {
  flex: 0 0 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: visible;
  max-height: none;
}

.widget-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 0;
  padding: 0.85rem 1rem 0.55rem;
  flex-shrink: 0;
}
.widget-head h3 {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}
.widget-head a {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--teal-deep);
}
.section-ico {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  display: block;
}

.activity-scroll {
  flex: 0 0 auto;
  min-height: 0;
  overflow: visible;
  padding: 0.15rem 1rem 0.85rem;
  display: grid;
  gap: 0.7rem;
  align-content: start;
}
.activity-scroll::-webkit-scrollbar { width: 5px; }
.activity-scroll::-webkit-scrollbar-thumb {
  background: rgba(24, 119, 242,0.4);
  border-radius: 99px;
}

.activity-row {
  display: flex;
  gap: 0.55rem;
  align-items: flex-start;
  font-size: 0.8rem;
  line-height: 1.35;
  color: var(--muted);
}
.activity-row strong { color: var(--text); font-weight: 700; }
.activity-row .activity-actor,
.activity-row .activity-object {
  color: var(--text);
  font-weight: 700;
  text-decoration: none;
}
.activity-row .activity-object {
  color: var(--teal-deep);
  font-weight: 700;
  appearance: none;
  border: 0;
  background: transparent;
  padding: 0;
  margin: 0;
  font: inherit;
  cursor: pointer;
  display: inline;
}
.activity-row .activity-actor:hover,
.activity-row .activity-object:hover {
  text-decoration: underline;
}
.activity-row .avatar {
  width: 34px; height: 34px;
  font-size: 0.7rem;
}
.activity-row .when {
  display: block;
  font-size: 0.7rem;
  color: var(--muted);
  opacity: 0.85;
  margin-top: 0.1rem;
}

/* Facebook-style member timeline */
.fb-timeline-page {
  max-width: 720px;
  padding-top: 0.5rem;
}
.profile-community-section {
  margin-top: 0;
  padding-top: 1.5rem;
  padding-bottom: 2.5rem;
}
.profile-community-section .community-bg {
  /* Keep fixed sky, but skip the long homepage white fade */
  -webkit-mask-image: none;
  mask-image: none;
  background-color: #e7f0fe;
}
.profile-community-section::before,
.profile-community-section::after {
  display: none;
}
.fb-timeline {
  display: grid;
  gap: 0;
  min-width: 0;
}
.fb-hero {
  background: #fff;
  border-radius: 14px;
  border: 1px solid rgba(24, 119, 242, 0.1);
  box-shadow:
    0 1px 2px rgba(15, 40, 72, 0.04),
    0 10px 24px rgba(15, 40, 72, 0.05);
  overflow: hidden;
  margin-bottom: 0.75rem;
}
.fb-cover {
  height: 168px;
  border-radius: 0;
  position: relative;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.55) 55%, #fff 100%),
    radial-gradient(ellipse at 30% 40%, rgba(120, 180, 210, 0.55), transparent 55%),
    radial-gradient(ellipse at 80% 20%, rgba(140, 190, 160, 0.45), transparent 50%),
    linear-gradient(135deg, #d7e8f4 0%, #e8f2ec 48%, #edf3f8 100%);
}
.fb-cover::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 72px;
  background: linear-gradient(to top, #fff 10%, rgba(255, 255, 255, 0.7) 48%, transparent);
  pointer-events: none;
}
.fb-identity {
  display: flex;
  align-items: flex-end;
  gap: 0.95rem;
  margin: -52px 1.05rem 0;
  padding: 0 0 1rem;
  position: relative;
  z-index: 1;
}
.fb-avatar {
  width: 112px;
  height: 112px;
  border-radius: 999px;
  border: 4px solid #fff;
  background: linear-gradient(145deg, #2f6f88, #4a9bb0);
  color: #fff;
  font-size: 2.4rem;
  font-weight: 800;
  display: grid;
  place-items: center;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.16);
  flex-shrink: 0;
  overflow: hidden;
}
.fb-avatar.has-photo {
  background: #e8eef4;
}
.fb-avatar.has-photo img,
.fb-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 999px;
}
.fb-identity-copy {
  padding: 56px 0 0.15rem;
  min-width: 0;
  flex: 1;
}
.fb-identity-copy h1 {
  margin: 0 0 0.2rem;
  font-size: clamp(1.25rem, 2.2vw, 1.55rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #1a334d;
  line-height: 1.2;
}
.fb-identity-copy p {
  margin: 0;
  color: #5a6d7e;
  font-size: 0.9rem;
  line-height: 1.4;
}
.fb-joined {
  margin-top: 0.2rem !important;
  font-size: 0.82rem !important;
  color: #7a8b9c !important;
  font-weight: 600;
}
.fb-activity-badge {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.55rem 0.85rem 0.15rem;
  font-size: 0.78rem;
  font-weight: 700;
  color: #3d8585;
}
.fb-activity-badge time {
  font-weight: 600;
  color: var(--muted);
  font-size: 0.72rem;
}
.fb-activity-badge.liked { color: #e11d48; }
.fb-activity-badge.commented { color: #1877f2; }
.fb-activity-badge.posted { color: #0f766e; }
.fb-comment-excerpt {
  margin: 0 0.85rem 0.45rem;
  padding: 0.55rem 0.75rem;
  border-left: 3px solid rgba(24, 119, 242, 0.45);
  background: rgba(24, 119, 242, 0.06);
  border-radius: 0 10px 10px 0;
  font-size: 0.88rem;
  color: var(--text);
  font-style: italic;
}
.fb-post {
  margin-bottom: 0.85rem;
}
.fb-tabs {
  display: flex;
  gap: 0.35rem;
  margin: 0 0 0.85rem;
  padding: 0.35rem;
  border-radius: 12px;
  background: #f3f6fa;
  border: 1px solid rgba(70, 98, 122, 0.1);
}
.fb-tabs button,
.fb-tabs a {
  appearance: none;
  border: 0;
  background: transparent;
  color: #5a6d7e;
  font: inherit;
  font-weight: 700;
  font-size: 0.92rem;
  padding: 0.55rem 0.9rem;
  border-radius: 9px;
  text-decoration: none;
  cursor: pointer;
  flex: 1;
  text-align: center;
}
.fb-tabs button.is-active,
.fb-tabs a:hover {
  background: #fff;
  color: #1877f2;
  box-shadow: 0 1px 2px rgba(15, 40, 72, 0.06);
}
.fb-feed {
  display: grid;
  gap: 0.85rem;
}
.fb-post .post-open {
  cursor: pointer;
}
.post-page-shell {
  min-height: 50vh;
}

@media (max-width: 640px) {
  .fb-cover { height: 132px; }
  .fb-identity { margin-left: 0.75rem; margin-right: 0.75rem; gap: 0.75rem; }
  .fb-avatar { width: 88px; height: 88px; font-size: 1.85rem; }
  .fb-identity-copy { padding-top: 44px; }
  .fb-identity-copy h1 { font-size: 1.2rem; }
}

.highlight-item {
  display: flex;
  gap: 0.55rem;
  align-items: center;
  text-align: left;
  border: 0;
  background: transparent;
  padding: 0;
  cursor: pointer;
  width: 100%;
  color: inherit;
  font: inherit;
}
.highlight-item img {
  width: 48px; height: 48px;
  border-radius: 10px;
  object-fit: cover;
  flex-shrink: 0;
  background: var(--surface);
}
.highlight-item strong {
  display: block;
  font-size: 0.8rem;
  line-height: 1.3;
  color: var(--text);
}
.highlight-item span {
  font-size: 0.72rem;
  color: var(--muted);
}
.highlight-item:hover strong { color: var(--teal-deep); }

/* FAQ accordion */
.faq-panel h3 {
  margin: 0;
  padding: 0.85rem 1rem 0.45rem;
  font-size: 0.95rem;
  font-weight: 800;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}
.faq-scroll {
  flex: 0 0 auto;
  min-height: 0;
  overflow: visible;
  padding: 0 1rem 0.65rem;
}
.faq-item {
  border-bottom: 1px solid var(--line);
}
.faq-item:last-child { border-bottom: 0; }
.faq-item summary {
  list-style: none;
  cursor: pointer;
  padding: 0.65rem 0;
  font-size: 0.85rem;
  font-weight: 650;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  color: var(--text);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "▾";
  color: var(--teal);
  font-size: 0.75rem;
  transition: transform 0.15s ease;
}
.faq-item[open] summary::after { transform: rotate(180deg); }
.faq-item p {
  margin: 0 0 0.65rem;
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.45;
}
.faq-panel-footer {
  flex-shrink: 0;
  padding: 0.15rem 1rem 0.9rem;
}
.faq-panel-footer .view-all {
  display: inline-flex;
  align-items: center;
  font-size: 0.85rem;
}
.activity-more {
  flex-shrink: 0;
  padding: 0.15rem 1rem 0.85rem;
}
.activity-show-more {
  width: 100%;
  border: 1px solid rgba(24, 119, 242, 0.22);
  background: rgba(24, 119, 242, 0.06);
  color: var(--teal-deep);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  padding: 0.55rem 0.75rem;
  border-radius: 12px;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}
.activity-show-more:hover:not(:disabled) {
  background: rgba(24, 119, 242, 0.12);
  border-color: rgba(24, 119, 242, 0.4);
}
.activity-show-more:disabled {
  opacity: 0.65;
  cursor: wait;
}

/* —— Outer ad rail (outside container, large only) —— */
.ad-rail {
  display: none;
  flex: 0 0 200px;
  width: 200px;
  position: sticky;
  top: calc(var(--nav-h) + 0.65rem);
  align-self: flex-start;
  max-height: calc(100vh - var(--nav-h) - 1.25rem);
}
.ad-rail .ad-vertical {
  height: 100%;
  max-height: calc(100vh - var(--nav-h) - 1.25rem);
  min-height: 480px;
}
.ad-in-column {
  display: block;
}
@media (min-width: 1481px) {
  .ad-rail--outer {
    display: block;
  }
  .ad-in-column {
    display: none;
  }
}

.ad-vertical {
  border-radius: 16px;
  overflow: hidden;
  background: linear-gradient(180deg, #ffffff 0%, #f5f9ff 100%);
  border: 1px solid rgba(24, 119, 242, 0.12);
  box-shadow: 0 12px 28px rgba(42, 54, 66, 0.055);
  display: flex;
  flex-direction: column;
  padding: 0.85rem 0.75rem 0.9rem;
}
.ad-vertical .ad-label,
.ad-inline .ad-label {
  padding: 0;
  margin: 0 0 0.55rem;
}
.ad-vertical-copy {
  padding: 0 0.15rem 0.65rem;
  text-align: left;
}
.ad-vertical-copy h4,
.ad-inline-copy h4 {
  margin: 0 0 0.75rem;
  font-family: var(--display);
  font-size: 1.05rem;
  font-weight: 650;
  line-height: 1.28;
  letter-spacing: -0.01em;
  color: var(--text);
}
.ad-vertical-copy .heart,
.ad-inline-copy .heart {
  color: var(--teal);
  font-size: 1.1rem;
}
.ad-vertical-media {
  flex: 0 0 auto;
  min-height: 0;
  max-height: 360px;
  margin: 0;
  border-radius: 12px;
  overflow: hidden;
  background: transparent;
  box-shadow: none;
  display: flex;
  align-items: center;
  justify-content: center;
}
.ad-vertical-media img {
  background: transparent;
  box-shadow: none;
  filter: none;
  width: 100%;
  height: auto;
  max-height: 360px;
  object-fit: contain;
}
.ad-vertical-cta {
  padding: 0.85rem 0 0;
  text-align: center;
}
.ad-vertical-cta p {
  margin: 0 0 0.65rem;
  font-size: 0.8rem;
  font-weight: 650;
  color: var(--muted);
}
.ad-vertical-cta .btn,
.ad-vertical-cta .ad-cta {
  width: 100%;
}
.ad-vertical-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.55rem 0 0;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text);
}
.ad-vertical-brand img {
  width: 22px; height: 22px;
}

/* Inline feed ad — always visible (distinct from rail placements) */
.ad-inline,
.ad-inline.ad-inline--visible {
  display: block;
  margin-bottom: 0.75rem;
}
.ad-inline-inner {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 1rem;
  align-items: center;
  background: linear-gradient(135deg, #f7fbff 0%, #eef5ff 100%);
  border-radius: 16px;
  border: 1px solid rgba(24, 119, 242, 0.12);
  box-shadow: 0 12px 28px rgba(42, 54, 66, 0.045);
  overflow: hidden;
  padding: 1rem;
}
.ad-inline-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 0;
}
.ad-inline-copy .ad-label { padding: 0; margin-bottom: 0.5rem; }
.ad-inline-copy h4 { margin-bottom: 0.85rem; }
.ad-inline-copy p {
  margin: 0.35rem 0 0.75rem;
  font-size: 0.85rem;
  color: var(--muted);
  font-weight: 600;
}
.ad-inline-copy .ad-cta {
  margin-top: auto;
}
.ad-inline-media {
  border-radius: 12px;
  overflow: hidden;
  aspect-ratio: auto;
  min-height: 0;
  max-height: 340px;
  background: transparent;
  box-shadow: none;
  display: flex;
  align-items: center;
  justify-content: center;
}
.ad-inline-media img {
  background: transparent;
  box-shadow: none;
  filter: none;
  width: 100%;
  height: auto;
  max-height: 340px;
  object-fit: contain;
}

/* Responsive */
@media (max-width: 1480px) {
  .community-shell { padding: 0 0.75rem; }
}
@media (max-width: 1279px) {
  .community-shell { max-width: var(--max, 1180px); }
  .community-core,
  .community-core.container { max-width: var(--max, 1180px); }
  .community-grid {
    grid-template-columns: 230px minmax(0, 1fr) 260px;
  }
}
@media (max-width: 1020px) {
  .community-grid {
    grid-template-columns: 210px minmax(0, 1fr);
  }
  .comm-col-left {
    height: calc(100vh - var(--nav-h) - 1.25rem);
  }
  .comm-col-right {
    grid-column: 1 / -1;
    position: static;
    height: auto;
    max-height: none;
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 0.85rem;
  }
  .comm-col-right .activity-panel,
  .comm-col-right .faq-panel {
    max-height: 360px;
    flex: none;
  }
  .activity-scroll,
  .faq-scroll { max-height: 280px; }
}
@media (max-width: 760px) {
  .community-grid { grid-template-columns: 1fr; }
  .comm-col-left {
    position: static;
    height: auto;
    max-height: none;
  }
  .cat-panel {
    max-height: none;
  }
  .cat-scroll {
    min-height: 0;
    max-height: 360px;
  }
  .comm-col-right {
    grid-template-columns: 1fr;
  }
  .ad-inline-inner {
    grid-template-columns: 1fr;
  }
  .ad-inline-media {
    aspect-ratio: auto;
    max-height: 260px;
  }
  .ad-inline-media img {
    max-height: 260px;
  }
}
@media (max-width: 520px) {
  .community-shell { padding: 0 0.65rem; }
  .cat-scroll { max-height: 280px; }
  .action-row button { font-size: 0.78rem; }
  .comm-col-right .activity-panel,
  .comm-col-right .faq-panel { max-height: 300px; }
}
@media (max-width: 980px) and (min-width: 641px) {
  .community-section {
    margin-top: -4.25rem;
    padding-top: 6rem;
  }
  .community-section::before {
    height: 16rem;
  }
  .community-head-chips {
    gap: 0.45rem;
  }
}

/* iOS / coarse pointers: fixed bg is unreliable — keep color, scroll the pattern */
@media (hover: none), (max-width: 720px) {
  .community-bg {
    background-attachment: scroll, scroll, scroll, scroll;
  }
}


button.compose-v2-field,
button.compose-tool,
button.compose-fab {
  font: inherit;
  cursor: pointer;
}
button.compose-v2-field {
  border: 0;
  width: 100%;
  text-align: left;
}

/* ---------------------------------------------------------------------------
   Tagged product box (FeedProductAttach) + post popup product card:
   never overflow the post card. Full product name wraps (no clamp/ellipsis),
   image fixed, text column flexible, buttons never shrink and wrap below the
   text on narrow widths.
   --------------------------------------------------------------------------- */
.post-products {
  grid-template-columns: minmax(0, 1fr);
  min-width: 0;
}
.product-attach {
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
}
.product-attach-row {
  flex-wrap: wrap;
  row-gap: 0.55rem;
  min-width: 0;
}
.product-attach-main {
  flex: 1 1 14rem;
  min-width: 0;
}
.product-attach .mini {
  flex: 0 0 58px;
  width: 58px;
  height: 58px;
}
.product-attach .mini img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.product-attach .mini--fallback {
  display: grid;
  place-items: center;
  background: linear-gradient(160deg, #f3f8ff 0%, #e3eeff 100%);
}
.product-attach .mini--fallback img {
  width: 58%;
  height: 58%;
  object-fit: contain;
  opacity: 0.6;
}
.product-attach-copy {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}
/* Long names clamp to two lines and clip — never spill over the price below. */
.product-attach-copy strong {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  white-space: normal;
  overflow: hidden;
  text-overflow: ellipsis;
  overflow-wrap: anywhere;
  word-break: normal;
}
.product-attach-copy .feed-product-price {
  margin-top: 0;
  line-height: 1.25;
}
.product-attach-row > .feed-product-actions {
  flex: 0 0 auto;
  margin-left: auto;
}
/* softer honey-butter CTA, matching the product cards */
.product-attach .feed-product-actions .pcard-buy,
.product-attach .feed-product-actions .pcard-cart {
  background: linear-gradient(180deg, #faedc2 0%, #f1d68f 100%);
  color: #4a3a12;
  border: 1px solid #e3c472;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.65), 0 5px 12px -6px rgba(190, 150, 50, 0.45);
}
.product-attach .feed-product-actions .pcard-buy:hover,
.product-attach .feed-product-actions .pcard-cart:hover {
  background: linear-gradient(180deg, #f8e6ad 0%, #ecca78 100%);
  filter: none;
}

/* post popup (PostModal) product card: same no-overflow rules */
.ep-product-card {
  flex-wrap: wrap;
  row-gap: 0.55rem;
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
}
.ep-product-link {
  flex: 1 1 14rem;
}
.ep-product-info strong {
  overflow-wrap: anywhere;
  word-break: break-word;
}
.ep-product-card > .ep-product-actions {
  margin-left: auto;
}

/* ==========================================================================
   FAQ questions: bullet-point icon before each question (sidebar FAQ card +
   the PDP sidebar FAQ that shares the same accordion style). The caret stays
   on the right via margin-left:auto.
   ========================================================================== */
.faq-item summary,
.pdp-faq-item summary {
  justify-content: flex-start;
}
.faq-item summary::before,
.pdp-faq-item summary::before {
  content: "";
  flex: 0 0 auto;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 0 3px rgba(24, 119, 242, 0.14);
  margin: 0 0.2rem 0 0.15rem;
  align-self: flex-start;
  /* optically centre on the first line of the question */
  margin-top: calc(0.5lh - 4px);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.faq-item[open] summary::before,
.pdp-faq-item[open] summary::before,
.faq-item summary:hover::before,
.pdp-faq-item summary:hover::before {
  transform: scale(1.12);
  box-shadow: 0 0 0 4px rgba(24, 119, 242, 0.2);
}
.faq-item summary::after,
.pdp-faq-item summary::after {
  margin-left: auto;
  flex: 0 0 auto;
}
.faq-item p,
.pdp-faq-item p {
  padding-left: calc(8px + 0.35rem + 0.2rem);
}

/* ==========================================================================
   Feed page sticky sidebars: breathing room at the top/bottom of the scroll
   containers so cards (and their shadows) aren't clipped at the edges, plus a
   soft fade where content scrolls out of view instead of a hard cut.
   ========================================================================== */
.comm-col-left,
.comm-col-right {
  box-sizing: border-box;
  padding-top: 0.6rem;
  padding-bottom: 1rem;
  scroll-padding-block: 0.6rem 1rem;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 0.6rem, #000 calc(100% - 1rem), transparent 100%);
  mask-image: linear-gradient(to bottom, transparent 0, #000 0.6rem, #000 calc(100% - 1rem), transparent 100%);
}
/* the column itself starts 0.6rem lower inside, so pull it up to keep the old card position */
@media (min-width: 761px) {
  .comm-col-left {
    top: calc(var(--nav-h) + 0.65rem);
    height: calc(100vh - var(--nav-h) - 0.7rem);
    max-height: calc(100vh - var(--nav-h) - 0.7rem);
  }
}
@media (min-width: 1021px) {
  .comm-col-right {
    top: calc(var(--nav-h) + 0.65rem);
    height: calc(100vh - var(--nav-h) - 0.7rem);
    max-height: calc(100vh - var(--nav-h) - 0.7rem);
  }
}
/* stacked (non-sticky) layouts: no fade needed */
@media (max-width: 1020px) {
  .comm-col-right {
    padding-top: 0;
    padding-bottom: 0;
    -webkit-mask-image: none;
    mask-image: none;
  }
}
@media (max-width: 760px) {
  .comm-col-left {
    padding-top: 0;
    padding-bottom: 0;
    -webkit-mask-image: none;
    mask-image: none;
  }
}