/* 커뮤니티 공통: 상단 메뉴, 로그인, 페이지 틀, 구역 카드, 버튼(모든 페이지). 기능별 스타일은 features/<기능>.css */

:root {
  --nav-h: 40px;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.auth-slot:empty {
  display: none;
}

.auth-link {
  display: inline-flex;
  align-items: center;
  max-width: 140px;
  min-height: 32px;
  padding: 4px 12px;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.auth-login {
  border-color: transparent;
  background: #5865f2;
  color: #ffffff;
}

.site-nav {
  display: flex;
  gap: 4px;
  min-height: var(--nav-h);
  align-items: center;
  overflow-x: auto;
  scrollbar-width: none;
}

.site-nav::-webkit-scrollbar {
  display: none;
}

.site-nav a {
  flex: none;
  padding: 6px 12px;
  border-radius: 999px;
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
}

.site-nav a:hover {
  background: var(--surface-2);
  color: var(--text);
}

.site-nav a[aria-current="page"] {
  background: var(--surface-2);
  color: var(--text);
}

.new-items {
  top: calc(var(--header-h) + var(--nav-h) + 10px);
}

/* 좌우 여백은 .wrap(16px)이 준다: padding 단축 속성으로 덮지 않는다 */
.page-main {
  padding-top: 16px;
  padding-bottom: 32px;
}

.page-title {
  margin: 0 0 4px;
  font-size: 22px;
  letter-spacing: -0.01em;
}

.page-lead {
  margin: 0 0 16px;
  color: var(--text-muted);
  font-size: 14px;
}

.panel {
  margin: 0 0 12px;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.panel-title {
  margin: 0 0 8px;
  font-size: 16px;
}

.panel-note {
  margin: 4px 0 0;
  color: var(--text-muted);
  font-size: 13px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 36px;
  padding: 6px 14px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}

.button-primary {
  border-color: transparent;
  background: var(--accent);
  color: var(--accent-contrast);
}

.button-danger {
  border-color: color-mix(in srgb, var(--error) 40%, var(--border));
  color: var(--error-text);
}

.button[disabled],
.button[aria-busy="true"] {
  opacity: 0.6;
  cursor: not-allowed;
}

.text-input {
  width: 100%;
  min-height: 40px;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  color: var(--text);
  font-size: 15px;
}

.policy h2 {
  margin: 20px 0 6px;
  font-size: 16px;
}

.policy p,
.policy li {
  font-size: 14px;
  line-height: 1.7;
}

.empty-state {
  padding: 24px 0;
  color: var(--text-muted);
  text-align: center;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

/* 카드 아래 행동 줄(반응·판매자 연락 등 기능이 함께 쓴다): 없으면 만들고 있으면 이어 붙인다 */
.card-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
}

.card-actions:empty {
  display: none;
}
