/* 커뮤니티와 인증 화면은 기존 공통 토큰과 기본 문서 규칙을 함께 사용합니다. */
:root {
    --community-footer-min-height: 144px;
    --community-footer-padding: 24px;
}
@media (max-width: 760px) {
    :root {
        --community-footer-min-height: 176px;
    }
}
html {
    color-scheme: light;
}
/* 공통 화면 모드는 운영체제 설정을 따르며 직접 선택한 모드가 우선합니다. */
html.community-surface {
    color-scheme: light dark;
}
html[data-theme="light"] {
    color-scheme: light;
}
html[data-theme="dark"] {
    color-scheme: dark;
}
.community-surface body {
    background: var(--community-bg);
    color: var(--community-text);
}
.community-surface :focus-visible {
    outline: 2px solid var(--community-accent);
    outline-offset: 2px;
}
body {
    margin: 0;
    color: var(--ref-ink);
    background: var(--k-bg-white);
    font-family: var(--k-font-primary), sans-serif;
}
/* 커뮤니티와 인증 화면의 서비스명·저작권·연결 메뉴를 함께 구성합니다. */
.site-footer {
    box-sizing: border-box;
    display: flex;
    flex: 0 0 auto;
    flex-direction: column;
    justify-content: center;
    gap: 16px;
    width: 100%;
    max-width: 1472px;
    min-height: var(--community-footer-min-height);
    margin: 0 auto;
    padding: var(--community-footer-padding) 48px;
    border-top: 1px solid var(--community-line);
    color: var(--community-text);
    font: 16px/1.65 "Pretendard", Arial, "Malgun Gothic", sans-serif;
}
.site-footer a {
    color: inherit;
    text-decoration: none;
}
.site-footer .footer-top,
.site-footer .footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}
.site-footer .footer-brand {
    font-size: 13px;
    font-weight: 600;
    letter-spacing: -.05em;
}
.site-footer .footer-bottom {
    color: var(--community-muted);
    font: 12px/1.6 var(--k-font-primary), sans-serif;
}
.site-footer .footer-bottom a {
    color: inherit;
}
.site-footer .footer-bottom nav {
    display: flex;
    gap: 20px;
    font: inherit;
}
@media (max-width: 1023.98px) {
    .site-footer {
        padding-right: 32px;
        padding-left: 32px;
    }
    .site-footer nav a {
        display: inline-flex;
        align-items: center;
        min-width: 44px;
        min-height: 44px;
    }
}
@media (max-width: 720.98px) {
    .site-footer {
        padding-right: 20px;
        padding-left: 20px;
    }
    .site-footer .footer-top,
    .site-footer .footer-bottom {
        display: block;
    }
    .site-footer .footer-brand {
        display: inline-block;
        font-size: 12px;
    }
    .site-footer .footer-top {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
    }
    .site-footer .footer-bottom nav {
        flex-wrap: wrap;
        gap: 18px;
        margin-top: 16px;
    }
}
[hidden] {
    display: none !important;
}
.community-error {
    max-width: 640px;
    margin: 80px auto;
    padding: 24px;
}
.community-error a {
    display: inline-block;
    margin: 12px 20px 12px 0;
    color: inherit;
}

/* 샘플 메인은 기존 단색 지면과 구분선으로 게시글 목록을 구성합니다. */
.community-page {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}
.community-header,
.community-main {
    box-sizing: border-box;
    width: 100%;
    max-width: 1120px;
    margin: 0 auto;
    padding-right: 48px;
    padding-left: 48px;
}
.community-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 80px;
    border-bottom: 1px solid var(--ref-ink);
}
.community-header a {
    color: inherit;
    text-decoration: none;
}
.community-brand {
    flex-shrink: 0;
    font-size: 20px;
    font-weight: 800;
    letter-spacing: -.05em;
}
.community-account {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 14px;
}
.community-member {
    max-width: 160px;
    overflow-wrap: anywhere;
}
.community-login,
.community-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    min-height: 44px;
    white-space: nowrap;
}
.community-button {
    padding: 10px 16px;
    border: 1px solid var(--ref-ink);
    border-radius: 0;
    background: var(--ref-ink);
    color: var(--k-bg-white);
    font: inherit;
    cursor: pointer;
}
.community-header .community-button {
    color: var(--k-bg-white);
}
.community-button:disabled {
    opacity: .6;
    cursor: wait;
}
.community-page a:focus-visible,
.community-button:focus-visible {
    outline: 2px solid var(--ref-ink);
    outline-offset: 4px;
}
.community-main {
    flex: 1;
    padding-top: 64px;
    padding-bottom: 56px;
}
.community-intro {
    margin-bottom: 56px;
}
.community-caption,
.community-category,
.community-author,
.community-sample-note {
    color: var(--k-text-gray);
    font-size: 13px;
}
.community-intro h1 {
    margin: 12px 0 16px;
    font-size: clamp(28px, 4vw, 40px);
    letter-spacing: -.05em;
}
.community-intro > p:last-child {
    color: var(--k-text-gray);
    line-height: 1.7;
}
.community-list-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--ref-ink);
}
.community-list-heading h2 {
    margin: 0;
    font-size: 20px;
}
.community-posts {
    margin: 0;
    padding: 0;
    list-style: none;
}
.community-post {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 24px 0;
    border-bottom: 1px solid var(--k-color-gray-e5);
}
.community-post h3 {
    margin: 8px 0;
    font-size: 17px;
    line-height: 1.6;
}
.community-post p {
    margin: 0;
    color: var(--k-text-gray);
    font-size: 14px;
    line-height: 1.7;
}
.community-author {
    flex-shrink: 0;
}
.community-message {
    margin-bottom: 24px;
    color: var(--k-text-gray);
}
.community-sample-note {
    margin: 24px 0 0;
    line-height: 1.7;
}
.community-page .site-footer {
    max-width: 1120px;
}
@media (max-width: 760px) {
    .community-header,
    .community-main {
        padding-right: 20px;
        padding-left: 20px;
    }
    .community-header {
        flex-wrap: wrap;
        gap: 8px 16px;
        padding-top: 12px;
        padding-bottom: 12px;
    }
    .community-brand {
        font-size: 18px;
    }
    .community-account {
        flex-wrap: wrap;
        gap: 12px;
        margin-left: auto;
        font-size: 13px;
    }
    .community-main {
        padding-top: 40px;
        padding-bottom: 40px;
    }
    .community-intro {
        margin-bottom: 40px;
    }
    .community-post {
        align-items: flex-start;
        flex-direction: column;
        gap: 12px;
    }
    .community-page .site-footer {
        padding-right: 20px;
        padding-left: 20px;
    }
}
