/* Community media: local light upload controls; keep the surrounding theme. */
.cm-upload{min-width:0;margin:.5rem 0;color:#172d25;background:#f3f0e8;border:1px solid #dcd7c9;border-radius:12px;color-scheme:light}
.cm-upload>summary{cursor:pointer;padding:.65rem .85rem;font-weight:750;color:#172d25;list-style-position:inside}
.cm-upload__fields{display:grid;gap:.65rem;padding:0 .85rem .85rem;min-width:0}
.cm-upload__fields :is(label,small){color:#172d25;line-height:1.5}
.cm-upload__fields small{color:#536459;font-size:.78rem}
.cm-upload .cm-upload__fields input[type=file]{display:block;width:100%;min-width:0;max-width:100%;box-sizing:border-box;color:#172d25;background:#fffcf6;border:1px solid #abb4a6;border-radius:8px;padding:.55rem;font:inherit}
.cm-upload input::file-selector-button{background:#f5f4ed;color:#19362b;border:1px solid #bdc6b5;border-radius:.45rem;padding:.35rem .55rem;margin-right:.45rem;cursor:pointer}
.cm-upload__fields .cm-upload__rights{display:flex;gap:.5rem;align-items:flex-start;font-size:.82rem;font-weight:400;overflow-wrap:anywhere}
.cm-upload__rights input[type=checkbox]{flex-shrink:0;accent-color:#627e00;margin-top:.25rem;width:1rem;height:1rem}
.cm-upload :is(summary,input):focus-visible,.cm-gallery a:focus-visible{outline:2px solid #698400;outline-offset:3px}
.cm-upload .community-error{color:#a12f2b}
.cm-gallery{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:4px;overflow:hidden;border-radius:12px;margin:.75rem 0;min-width:0;background:#161916}
.cm-gallery--single{grid-template-columns:minmax(0,1fr)}
.cm-gallery a{display:block;min-width:0;overflow:hidden}
.cm-gallery img{display:block;width:100%;height:auto;aspect-ratio:4/3;object-fit:cover;background:#1c1e1c}
.cm-gallery--single img{aspect-ratio:auto;max-height:520px;object-fit:contain}
.cm-gallery video{display:block;width:100%;aspect-ratio:16/9;max-height:520px;object-fit:contain;background:#111}
.cm-gallery--small{max-width:420px;border-radius:8px}
.cm-gallery--small img{max-height:240px}
.cm-gallery__more{display:inline-block;font-size:.85rem;text-decoration:underline;text-underline-offset:3px}
@media(max-width:640px){.cm-gallery{border-radius:9px}.cm-gallery img{aspect-ratio:1/1}.cm-gallery--single img{aspect-ratio:auto;max-height:400px}.cm-gallery--small img{max-height:200px}.cm-upload .cm-upload__fields input[type=file]{font-size:.8rem}}

/* Homepage: a single real photo per Community card; no video download. */
.home-community .community-card .cm-home-preview {
    display:block;position:relative;min-width:0;overflow:hidden;
    margin:.15rem 0 .35rem;border-radius:10px;border:1px solid #d2dfce;
    background:#f1f6ee;color:#19271d;text-decoration:none;
}
.home-community .cm-home-preview img {
    display:block;width:100%;height:auto;aspect-ratio:4/3;
    object-fit:contain;background:#f1f6ee;
}
.home-community .cm-home-preview__count {
    position:absolute;right:.5rem;bottom:.5rem;padding:.3rem .55rem;
    border-radius:999px;background:#172d25;color:#fff;font-size:.75rem;font-weight:750;
}
.home-community .cm-home-preview--video {padding:.8rem 1rem;font-size:.85rem;font-weight:750}
.home-community .cm-home-preview:focus-visible {outline:2px solid #698400;outline-offset:3px}
