body.community-page {
    background: #ffffff;
    color: #222;
}

.community-main {
    width: min(1120px, 94%);
    margin: 28px auto 64px;
}

.community-hero {
    display: grid;
    grid-template-columns: 1.6fr 1fr;
    gap: 16px;
    margin-bottom: 18px;
}

.hero-copy {
    background: #ffffff;
    border: 1px solid #d6e6dc;
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 8px 24px rgba(10, 35, 22, 0.08);
}

.community-eyebrow {
    display: inline-block;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #137353;
    margin-bottom: 8px;
}

.community-hero h1 {
    font-size: clamp(30px, 4vw, 42px);
    color: #0b3d2e;
    margin-bottom: 10px;
    line-height: 1.15;
}

.community-hero p {
    color: #385167;
    font-size: 16px;
    line-height: 1.5;
}

.hero-badge {
    background: linear-gradient(180deg, #f0fbf4, #e6f8ef);
    border: 1px solid #cde8d8;
    border-radius: 16px;
    padding: 18px;
}

.hero-badge h2 {
    font-size: 20px;
    color: #0b3d2e;
    margin-bottom: 8px;
}

.hero-badge p {
    color: #365745;
    font-size: 14px;
}

.community-layout {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(260px, 1fr);
    gap: 16px;
    align-items: start;
}

.community-left,
.community-right {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.composer-card,
.feed-card,
.community-pinned,
.community-side-card {
    background: #ffffff;
    border: 1px solid #d6e6dc;
    border-radius: 16px;
    padding: 18px;
    box-shadow: 0 10px 26px rgba(10, 35, 22, 0.08);
}

.composer-head,
.feed-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 8px;
    gap: 10px;
}

.composer-head h2,
.feed-header h2 {
    font-size: 23px;
    color: #0b3d2e;
}

.post-access-message {
    font-size: 13px;
    color: #5f7285;
    text-align: right;
}

.composer-tip {
    font-size: 14px;
    color: #4e6476;
    margin-bottom: 12px;
}

.prompt-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}

.prompt-chip {
    font-size: 12px;
    color: #1f503d;
    background: #f2f8f4;
    border: 1px solid #d3e7da;
    border-radius: 999px;
    padding: 6px 10px;
}

.composer-label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 700;
    color: #173e31;
}

#comment-form textarea {
    width: 100%;
    min-height: 170px;
    resize: vertical;
    background: #fcfdfc;
    border: 1px solid #cfdcd3;
    border-radius: 12px;
    color: #1f2937;
    padding: 12px 14px;
    font-size: 15px;
    line-height: 1.5;
}

#comment-form textarea:focus {
    outline: none;
    border-color: #33cc66;
    box-shadow: 0 0 0 3px rgba(51, 204, 102, 0.2);
}

#comment-form textarea:disabled {
    opacity: 0.75;
    cursor: not-allowed;
}

.composer-actions {
    margin-top: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}

.comment-counter {
    font-size: 13px;
    color: #5f7285;
}

.comment-feedback {
    min-height: 22px;
    margin-top: 8px;
    font-size: 14px;
}

.comment-feedback.success {
    color: #137353;
}

.comment-feedback.error {
    color: #cc3344;
}

.community-post-btn {
    border: none;
    border-radius: 999px;
    min-width: 176px;
    padding: 12px 20px;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.2px;
    color: #ffffff;
    background: linear-gradient(135deg, #0b3d2e, #137353);
    box-shadow: 0 10px 20px rgba(11, 61, 46, 0.3);
    transition: transform 0.15s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.community-post-btn:hover {
    transform: translateY(-1px);
    filter: brightness(1.05);
    box-shadow: 0 14px 24px rgba(11, 61, 46, 0.36);
}

.community-post-btn:active {
    transform: translateY(0);
}

.community-post-btn:disabled {
    cursor: not-allowed;
    opacity: 0.65;
    transform: none;
    box-shadow: none;
}

.community-pinned {
    position: sticky;
    top: 12px;
    z-index: 10;
}

.community-pinned h2 {
    font-size: 21px;
    color: #0b3d2e;
    margin-bottom: 8px;
}

.community-pinned p {
    color: #365745;
    font-size: 14px;
    line-height: 1.55;
}

.community-side-card h3 {
    font-size: 18px;
    color: #0b3d2e;
    margin-bottom: 10px;
}

.community-side-card ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.community-side-card li {
    color: #395367;
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 8px;
    padding-left: 12px;
    position: relative;
}

.community-side-card li::before {
    content: "-";
    position: absolute;
    left: 0;
    color: #137353;
}

.comments-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.feed-loading,
.feed-empty {
    color: #5f7285;
    font-size: 14px;
}

.comment-item {
    background: #ffffff;
    border: 1px solid #d4e2d8;
    border-left: 4px solid #9adfb2;
    border-radius: 12px;
    padding: 12px;
}

.comment-item:nth-child(odd) {
    background: #fbfefc;
}

.comment-head {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.comment-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #ffffff;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.14);
    flex: 0 0 42px;
}

.comment-meta {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.comment-author {
    font-weight: 700;
    color: #0f172a;
    font-size: 14px;
}

.comment-date {
    font-size: 12px;
    color: #64748b;
}

.comment-text {
    color: #334155;
    font-size: 15px;
    white-space: pre-wrap;
    word-break: break-word;
    line-height: 1.5;
}

@media (max-width: 980px) {
    .community-hero {
        grid-template-columns: 1fr;
    }

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

    .community-pinned {
        position: static;
        top: auto;
    }
}

@media (max-width: 700px) {
    .community-main {
        width: 94%;
    }

    .hero-copy,
    .hero-badge,
    .composer-card,
    .feed-card,
    .community-pinned,
    .community-side-card {
        padding: 14px;
    }

    .composer-head,
    .feed-header {
        flex-direction: column;
    }

    .post-access-message {
        text-align: left;
    }

    .composer-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .community-post-btn {
        width: 100%;
        min-width: 0;
    }
}
