/* pages.css — 주보로그 새 화면: 소개 · 첫 설정 · 그룹 바 · 그룹 고르기 칸 · 그룹 설정 (색은 theme.css 토큰만) */

.site-credit { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 12px; }
.site-credit a { color: var(--text-tertiary); text-decoration: underline; }

.narrow-page { max-width: 560px; margin: 0 auto; padding: 24px 16px 40px; display: flex; flex-direction: column; gap: 16px; }
.narrow-page .page-title { font-size: 24px; margin: 0; }

.intro { max-width: 560px; margin: 0 auto; padding: 56px 16px 40px; display: flex; flex-direction: column; gap: 18px; }
.intro-title { font-size: 34px; margin: 0; letter-spacing: -0.02em; }
.intro-sub { margin: 0; color: var(--text-secondary); font-size: 17px; }
.intro-points { list-style: none; margin: 8px 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.intro-points li { background: var(--fill-1); border-radius: var(--radius-md); padding: 14px 16px; display: flex; flex-direction: column; gap: 4px; }
.intro-points span { color: var(--text-secondary); font-size: 14px; line-height: 1.5; }
.intro-cta { padding: 14px; font-size: 16px; }

.group-bar { max-width: 960px; margin: 0 auto 16px; padding: 0; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.group-name { font-size: 22px; margin: 0; }

.notice-box { max-width: 960px; margin: 0 auto 20px; padding: 14px 16px; border-radius: var(--radius-md); background: rgba(var(--glow-rgb), 0.08);
  display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.notice-box p { margin: 0; color: var(--text-secondary); font-size: 14px; }


.char-check-list { display: flex; flex-direction: column; gap: 6px; margin-bottom: 8px; }
.char-check { display: grid; grid-template-columns: auto auto 1fr; align-items: center; gap: 8px; padding: 8px 10px; border-radius: 10px; background: var(--fill-1); cursor: pointer; }
.char-check span { color: var(--text-tertiary); font-size: 13px; min-width: 0; overflow-wrap: anywhere; }

.inline-row { display: flex; gap: 8px; align-items: center; }
.inline-row .text-input { flex: 1; min-width: 0; }

.danger-zone { opacity: 0.8; }
.privacy section h2 { font-size: 16px; margin: 0 0 4px; }
.privacy section p { margin: 0; color: var(--text-secondary); line-height: 1.6; }

/* 숨긴 칸은 레이아웃 규칙(display: flex 등)보다 우선해서 숨긴다 */
[hidden] { display: none !important; }
/* 구글 버튼은 iframe 이라 다크 모드에서 흰 사각형이 생긴다 → 버튼 칸만 라이트로 그리게 한다 */
.google-slot { min-height: 44px; display: flex; justify-content: center; color-scheme: light; }
.intro-why { margin: 0; font-size: 13px; line-height: 1.6; color: var(--text-secondary); text-align: center; }
.login-box { display: flex; flex-direction: column; align-items: center; gap: 10px; }
.login-fallback { font-size: 13px; }

/* 처리방침 · 출처 줄은 내용이 짧아도 항상 화면 맨 아래 (정혁님 11-13) */
body { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }
#app { flex: 1 0 auto; width: 100%; box-sizing: border-box; }
.site-credit { flex-shrink: 0; }

/* 구글 버튼 가운데 (버튼은 구글이 그리는 iframe 이라 감싼 칸을 가운데로) */
.google-slot { width: 100%; }
.google-slot > div { margin: 0 auto; }
.login-box { width: 100%; max-width: 400px; margin: 0 auto; }
/* 초대 화면은 가운데 정렬 (구글 버튼과 줄 맞추기) */
.join-page { text-align: center; align-items: center; }
.join-page .page-title { text-align: center; }
/* 첫 화면도 전부 가운데 정렬 (정혁님 11-13) */
.intro { text-align: center; align-items: center; }
.intro-points { width: 100%; }
.intro-points li { align-items: center; }
.intro .form-hint { text-align: center; }

/* 한글은 낱말 중간에서 줄을 바꾸지 않고(전/리품, 순/위 방지), 마지막 줄에 한두 글자만 남지 않게 (정혁님 11-13) */
body { word-break: keep-all; overflow-wrap: break-word; }
p, li, span, h1, h2, strong { text-wrap: pretty; }
.intro-points span, .intro-why, .intro-sub, .notice-box p, .form-hint { text-wrap: balance; }

/* 첫 화면 · 초대 화면은 남는 높이의 가운데에 (위에 붙어 보인다는 지적, 정혁님 11-13). 다른 화면은 그대로 */
#app:has(> .intro), #app:has(> .join-page) { display: flex; flex-direction: column; justify-content: center; }
.intro, .join-page { padding-top: 24px; padding-bottom: 48px; }
/* 그룹 나가기: 설정 화면 맨 아래 가운데에 버튼만 */
.settings-leave { display: flex; justify-content: center; margin-top: 16px; }
/* 짧은 설정 줄(비밀번호 · 그룹 이름): 이름 · 설명 왼쪽, 조작 오른쪽. PC 에선 두 줄을 한 줄에 나란히, 폰에선 위아래. 입력칸을 열면 그 줄만 위아래로 */
.setting-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 0 32px; border-top: 1px solid var(--border-subtle); }
.setting-pair > .setting-row { border-top: none; }
.setting-row.setting-row-compact { grid-template-columns: minmax(0, 1fr) auto; align-items: center; }
.setting-row-compact:has(.text-input:not([hidden] *)) { grid-template-columns: minmax(0, 1fr); }
.setting-row-compact .setting-inline { flex-wrap: nowrap; justify-content: flex-end; }
@media (max-width: 640px) {
  .setting-pair { grid-template-columns: minmax(0, 1fr); }
  .setting-pair > .setting-row + .setting-row { border-top: 1px solid var(--border-subtle); }
}
