.gcm-wrap {
  --gcm-columns: 4;
  --gcm-accent: #A8471F;
  --gcm-surface: #1F2622;
  --gcm-text: #EDE6D6;
  --gcm-image-height: 160px;
  width: 100%;
  color: var(--gcm-text);
}

.gcm-heading-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.gcm-title {
  margin: 0;
  font-size: clamp(1.5rem, 2vw, 2.15rem);
  line-height: 1.15;
}

.gcm-grid {
  display: grid;
  grid-template-columns: repeat(var(--gcm-columns), minmax(0, 1fr));
  gap: 14px;
  align-items: start;
}

.gcm-card {
  position: relative;
  box-sizing: border-box;
  display: flex;
  min-height: 150px;
  flex-direction: column;
  gap: 10px;
  overflow: hidden;
  border: 1px solid rgba(237, 230, 214, .16);
  border-radius: 16px;
  background: var(--gcm-surface);
  color: var(--gcm-text);
  text-decoration: none !important;
  transform: translateY(0);
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.gcm-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 5px;
  height: 100%;
  background: var(--gcm-accent);
  opacity: .95;
  z-index: 1;
}

a.gcm-card {
  padding: 18px;
}

.gcm-category-image {
  display: block;
  width: 100%;
  height: var(--gcm-image-height);
  flex: 0 0 auto;
  overflow: hidden;
  border-radius: 11px;
  background: rgba(255,255,255,.05);
}

.gcm-category-image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .3s ease;
}

.gcm-card.has-category-image:hover .gcm-category-image img,
.gcm-card.has-category-image:focus-within .gcm-category-image img {
  transform: scale(1.035);
}

.gcm-card.gcm-image-background {
  background-color: var(--gcm-surface);
  background-image: linear-gradient(rgba(20, 24, 22, .78), rgba(20, 24, 22, .88)), var(--gcm-category-image);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.gcm-card.gcm-image-background:hover,
.gcm-card.gcm-image-background:focus-within {
  background-image: linear-gradient(rgba(20, 24, 22, .70), rgba(20, 24, 22, .84)), var(--gcm-category-image);
}

.gcm-card:hover,
.gcm-card:focus-within,
.gcm-card.is-active {
  color: var(--gcm-text);
  border-color: var(--gcm-accent);
  transform: translateY(-3px);
  box-shadow: 0 10px 26px rgba(0,0,0,.16);
}

.gcm-card:focus-visible,
.gcm-toggle:focus-visible,
.gcm-post-list a:focus-visible,
.gcm-view-all:focus-visible {
  outline: 3px solid var(--gcm-accent);
  outline-offset: 2px;
}

.gcm-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.gcm-name {
  font-size: 1.05rem;
  font-weight: 800;
  line-height: 1.2;
}

.gcm-count {
  flex: 0 0 auto;
  min-width: 30px;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(168, 71, 31, .28);
  color: var(--gcm-text);
  font-size: .78rem;
  font-weight: 700;
  text-align: center;
}

.gcm-description {
  color: rgba(237, 230, 214, .76);
  font-size: .9rem;
  line-height: 1.45;
}

.gcm-children {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.gcm-chip {
  padding: 3px 7px;
  border: 1px solid rgba(237, 230, 214, .14);
  border-radius: 999px;
  color: rgba(237, 230, 214, .76);
  font-size: .72rem;
  line-height: 1.25;
}

.gcm-open {
  color: var(--gcm-accent);
  font-size: .82rem;
  font-weight: 800;
  letter-spacing: .01em;
}

a.gcm-card .gcm-open {
  margin-top: auto;
}

.gcm-card-expandable {
  min-height: 0;
}

.gcm-toggle {
  appearance: none;
  width: 100%;
  min-height: 150px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 18px;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.gcm-toggle-main {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  gap: 10px;
}

.gcm-toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
}

.gcm-chevron {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: 1px solid rgba(237, 230, 214, .18);
  border-radius: 50%;
  color: var(--gcm-text);
  font-size: 1.15rem;
  line-height: 1;
  transition: transform .2s ease, background .2s ease;
}

.gcm-toggle[aria-expanded="true"] .gcm-chevron {
  transform: rotate(180deg);
  background: rgba(168, 71, 31, .22);
}

.gcm-post-panel {
  position: relative;
  z-index: 2;
  padding: 0 18px 18px 23px;
  border-top: 1px solid rgba(237, 230, 214, .12);
}

.gcm-post-panel[hidden] {
  display: none !important;
}

.gcm-post-list {
  list-style: none;
  margin: 0;
  padding: 12px 0 6px;
}

.gcm-post-list li {
  margin: 0;
  padding: 0;
  border-bottom: 1px solid rgba(237, 230, 214, .09);
}

.gcm-post-list li:last-child {
  border-bottom: 0;
}

.gcm-post-list a {
  display: block;
  padding: 9px 0;
  color: var(--gcm-text) !important;
  text-decoration: none !important;
  font-size: .9rem;
  line-height: 1.35;
}

.gcm-post-list a:hover {
  color: var(--gcm-accent) !important;
}

.gcm-no-posts {
  margin: 12px 0;
  color: rgba(237, 230, 214, .72);
  font-size: .88rem;
}

.gcm-view-all {
  display: inline-block;
  margin-top: 8px;
  color: var(--gcm-accent) !important;
  text-decoration: none !important;
  font-size: .84rem;
  font-weight: 800;
}

.gcm-view-all:hover {
  text-decoration: underline !important;
}

.gcm-empty {
  padding: 16px;
  border: 1px dashed #bbb;
  border-radius: 12px;
  text-align: center;
}

@media (max-width: 1100px) {
  .gcm-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  .gcm-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  a.gcm-card,
  .gcm-toggle { min-height: 135px; padding: 16px; }
  .gcm-post-panel { padding: 0 16px 16px 21px; }
}

@media (max-width: 480px) {
  .gcm-grid { grid-template-columns: 1fr; }
  a.gcm-card,
  .gcm-toggle { min-height: auto; }
}
