/* =========================================================
   ARMY READY — Community
========================================================= */

.community-page {
  min-height: 100vh;
  margin: 0;
  background: #f7f8f9;
  color: #202124;
}

.community-page *,
.community-page *::before,
.community-page *::after {
  box-sizing: border-box;
}

.community-header {
  position: sticky;
  z-index: 30;
  top: 0;
  border-bottom: 1px solid rgba(230, 233, 236, 0.92);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(18px);
}

.community-header-inner {
  width: min(100%, 980px);
  min-height: 72px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  margin: 0 auto;
  padding: 10px 22px;
}

.community-back {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid #e3e7e9;
  border-radius: 50%;
  background: #ffffff;
  color: #202124;
  font-size: 31px;
  line-height: 1;
  text-decoration: none;
}

.community-header-copy p,
.community-header-copy h1 {
  margin: 0;
}

.community-header-copy p {
  color: #8a9096;
  font-size: 9px;
  font-weight: 850;
  letter-spacing: 0.15em;
}

.community-header-copy h1 {
  margin-top: 2px;
  font-size: 22px;
  line-height: 1.1;
  letter-spacing: -0.03em;
}

.community-favorite-toggle {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 12px;
  border: 1px solid #e1e5e7;
  border-radius: 999px;
  background: #ffffff;
  color: #4e555b;
  font: inherit;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.community-favorite-toggle.active {
  border-color: #111318;
  background: #111318;
  color: #ffffff;
}

.community-main {
  width: min(100%, 980px);
  margin: 0 auto;
  padding: 24px 22px 96px;
}

.community-hero {
  padding: 30px;
  overflow: hidden;
  border-radius: 26px;
  background:
    radial-gradient(
      circle at top right,
      rgba(255, 128, 171, 0.27),
      transparent 38%
    ),
    #111318;
  color: #ffffff;
}

.community-eyebrow {
  margin: 0 0 11px;
  color: #ff9cc0;
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0.12em;
}

.community-hero h2 {
  margin: 0;
  font-size: clamp(30px, 6vw, 46px);
  line-height: 1;
  letter-spacing: -0.05em;
}

.community-hero > p:last-child {
  max-width: 640px;
  margin: 18px 0 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: 14px;
  line-height: 1.75;
}

.community-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  align-items: center;
  gap: 14px;
  margin-top: 22px;
}

.community-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.community-filter {
  min-height: 38px;
  padding: 8px 13px;
  border: 1px solid #e1e5e7;
  border-radius: 999px;
  background: #ffffff;
  color: #6f757b;
  font: inherit;
  font-size: 12px;
  font-weight: 750;
  cursor: pointer;
}

.community-filter.active {
  border-color: #111318;
  background: #111318;
  color: #ffffff;
}

.community-search input {
  width: 100%;
  min-height: 42px;
  padding: 0 14px;
  border: 1px solid #e1e5e7;
  border-radius: 14px;
  outline: none;
  background: #ffffff;
  color: #202124;
  font: inherit;
  font-size: 13px;
}

.community-search input:focus {
  border-color: #e788ac;
  box-shadow: 0 0 0 3px rgba(255, 128, 171, 0.12);
}

.community-status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 22px 2px 9px;
}

.community-status p {
  margin: 0;
  color: #8a9096;
  font-size: 12px;
  font-weight: 700;
}

.community-status button {
  padding: 0;
  border: 0;
  background: transparent;
  color: #bf4d78;
  font: inherit;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.community-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.community-card {
  min-width: 0;
  display: flex;
  flex-direction: column;
  padding: 22px;
  border: 1px solid #e6eaec;
  border-radius: 20px;
  background: #ffffff;
}

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

.community-card-meta {
  min-width: 0;
  display: grid;
  gap: 8px;
}

.community-card-category-row,
.community-card-date-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
}

.community-card-category,
.community-card-date {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 9px;
  font-weight: 850;
  letter-spacing: 0.04em;
}

.community-card-category {
  background: #fff0f6;
  color: #b84772;
}

.community-card-date {
  background: #f2f4f5;
  color: #737a80;
}

.community-card-favorite {
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border: 1px solid #e2e6e8;
  border-radius: 50%;
  background: #ffffff;
  color: #92989e;
  font-size: 20px;
  cursor: pointer;
}

.community-card-favorite.active {
  border-color: #f0b6ca;
  background: #fff0f6;
  color: #c34c79;
}

.community-card h3 {
  margin: 16px 0 0;
  color: #202124;
  font-size: 21px;
  line-height: 1.35;
  letter-spacing: -0.025em;
}

.community-card-host {
  margin: 8px 0 0;
  color: #9aa0a6;
  font-size: 11px;
  font-weight: 700;
}

.community-card-summary {
  margin: 12px 0 0;
  color: #6f757b;
  font-size: 14px;
  line-height: 1.7;
}

.community-card-details {
  display: grid;
  gap: 8px;
  margin-top: 17px;
  padding: 14px;
  border-radius: 14px;
  background: #f7f8f9;
}

.community-card-detail {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  gap: 10px;
  font-size: 12px;
  line-height: 1.5;
}

.community-card-detail span {
  color: #9aa0a6;
  font-weight: 700;
}

.community-card-detail strong {
  color: #40454a;
  font-weight: 750;
}

.community-card-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
  padding-top: 18px;
}

.community-card-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  padding: 8px 12px;
  border: 1px solid #dce2e4;
  border-radius: 12px;
  color: #30343a;
  font-size: 12px;
  font-weight: 750;
  text-decoration: none;
}

.community-card-link.primary {
  border-color: #111318;
  background: #111318;
  color: #ffffff;
}

.community-empty {
  padding: 54px 24px;
  border: 1px dashed #d9dfe2;
  border-radius: 20px;
  background: #ffffff;
  text-align: center;
}

.community-empty strong {
  font-size: 17px;
}

.community-empty p {
  margin: 8px 0 0;
  color: #8a9096;
  font-size: 13px;
}

.hidden {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  clip-path: inset(50%);
}

@media (max-width: 760px) {
  .community-header-inner {
    min-height: 64px;
    padding: 9px 14px;
  }

  .community-main {
    padding: 14px 14px 84px;
  }

  .community-hero {
    padding: 24px 20px;
    border-radius: 22px;
  }

  .community-toolbar {
    grid-template-columns: 1fr;
  }

  .community-search {
    order: -1;
  }

  .community-list {
    grid-template-columns: 1fr;
  }

  .community-card {
    padding: 18px;
    border-radius: 18px;
  }

  .community-card h3 {
    font-size: 18px;
  }
}
