.cf-community { --cf-border: #2b3449; --cf-muted: #a6b2c8; --cf-panel: #12192d; max-width: 1400px; margin: auto; padding: 20px 8px 48px; color: #f8fafc; }
.cf-community * { box-sizing: border-box; }
.cf-pagination { margin-top: 24px; }
.cf-affiliation-fields { border: 1px solid var(--cf-border); border-radius: 10px; padding: 18px; margin: 22px 0; }
.cf-affiliation-fields legend { float: none; width: auto; font-size: 1.1rem; padding: 0 8px; }
.cf-affiliation-fields small { color: var(--cf-muted); font-size: .8rem; }
.cf-affiliation { border-top: 1px solid var(--cf-border); margin-top: 22px; padding-top: 22px; }
.cf-moderation-photo { display: block; width: 100%; max-width: 600px; max-height: 600px; object-fit: contain; margin: 18px 0; }
.cf-community h1, .cf-community h2, .cf-community h3, .cf-community p { margin: 0; }
.cf-community h1 { font-size: clamp(2rem, 3.3vw, 3rem); font-weight: 700; line-height: 1.15; }
.cf-community h2 { font-size: 1.5rem; font-weight: 650; }
.cf-community h3 { font-size: 1.2rem; font-weight: 650; }
.cf-community a { text-decoration: none; color: #c4b5fd; }
.cf-community button, .cf-community input, .cf-community textarea, .cf-community select { font: inherit; }
.cf-community button, .cf-community a { -webkit-tap-highlight-color: transparent; }
.cf-community :is(a,button,input,textarea,select):focus-visible { outline: 2px solid #c4b5fd; outline-offset: 4px; }
.cf-preview-notice { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border: 1px solid #34324c; border-radius: 8px; background: #17172a; color: #b6bdd2; font-size: .8rem; line-height: 1.5; margin-bottom: 24px; }
.cf-preview-notice i { color: #b9a0ff; }
.cf-page-heading { display: flex; justify-content: space-between; align-items: start; gap: 24px; margin: 0 0 24px; }
.cf-page-heading p { margin-top: 8px; color: var(--cf-muted); font-size: 1.1rem; }
.cf-actions { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.cf-community .cf-button { display: inline-flex; justify-content: center; align-items: center; gap: 9px; min-height: 42px; padding: 9px 17px; border: 1px solid #77839c; border-radius: 8px; background: transparent; color: #f8fafc; font-weight: 550; cursor: pointer; white-space: nowrap; }
.cf-community .cf-primary { background: #7c3aed; border-color: #8b5cf6; }
.cf-community .cf-button:hover { background: #27223e; border-color: #c4b5fd; }
.cf-community .cf-primary:hover { background: #6d28d9; }
.cf-community .cf-button[aria-pressed=true] { color: #ddd1ff; border-color: #a78bfa; }
.cf-community .cf-button:disabled { opacity: .5; cursor: not-allowed; }
.cf-community .cf-small { padding: 6px 13px; min-height: 36px; font-size: .9rem; }
.cf-tabs { display: flex; gap: 28px; border-bottom: 1px solid var(--cf-border); }
.cf-tabs a { color: var(--cf-muted); padding: 14px 12px; font-weight: 600; border-bottom: 3px solid transparent; }
.cf-tabs a.active { color: white; border-bottom-color: #a78bfa; }
.cf-tabs a:hover { color: #c4b5fd; }
.cf-feed-label { color: var(--cf-muted); margin: 18px 0 !important; font-size: .95rem; }
.cf-feed-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.cf-post-card { overflow: hidden; border: 1px solid var(--cf-border); border-radius: 12px; background: var(--cf-panel); display: flex; flex-direction: column; }
.cf-card-author { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 17px; }
.cf-community .cf-author { display: flex; align-items: center; gap: 12px; color: #f8fafc; min-width: 0; }
.cf-author strong { font-size: 1.1rem; display: block; }
.cf-author small { display: block; color: var(--cf-muted); font-size: .85rem; margin-top: 3px; }
.cf-avatar { background: #28223e; border: 1px solid #77648e; color: #d5c4ff; border-radius: 50%; width: 46px; height: 46px; flex: 0 0 46px; display: inline-flex; justify-content: center; align-items: center; font-size: 1.2rem; }
.cf-post-photo { width: 100%; height: auto; object-fit: contain; display: block; background: #0b1020; }
.cf-photo-link { overflow: hidden; display: block; background: #0c1020; }
.cf-photo-link img { transition: transform .2s; }
.cf-photo-link:hover img { transform: scale(1.015); }
.cf-card-body { display: flex; flex-direction: column; flex: 1; padding: 17px; }
.cf-community .cf-title-link { color: white; }
.cf-card-body h2 { font-size: 1.25rem; line-height: 1.3; }
.cf-card-body p { color: var(--cf-muted); margin-top: 8px; line-height: 1.5; }
.cf-chip-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0; }
.cf-community .cf-chip { display: inline-flex; align-items: center; gap: 8px; padding: 4px 10px; background: #26253e; border: 1px solid #3d3b59; border-radius: 8px; font-size: .8rem; color: #d6d5e8; }
.cf-card-footer { border-top: 1px solid var(--cf-border); padding-top: 12px; display: flex; gap: 28px; margin-top: auto; }
.cf-community .cf-text-button { display: inline-flex; align-items: center; gap: 8px; padding: 5px 0; border: 0; background: none; color: #d9e1f1; cursor: pointer; }
.cf-text-button[aria-pressed=true], .cf-text-button:hover { color: #c4b5fd !important; }
.cf-back { display: inline-flex; gap: 10px; align-items: center; margin: 0 0 22px; }
.cf-detail-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px; align-items: start; }
.cf-detail-photo { width: 100%; height: auto; object-fit: contain; border-radius: 12px; background: #0b1020; }
.cf-community .cf-post-title { font-size: 1.9rem; margin: 18px 0 10px; }
.cf-caption { color: var(--cf-muted); line-height: 1.6; margin-bottom: 20px !important; white-space: pre-wrap; overflow-wrap: anywhere; }
.cf-creator-panel { background: var(--cf-panel); border: 1px solid var(--cf-border); padding: 20px; border-radius: 12px; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: start; gap: 12px; }
.cf-profile-link { display: block; flex-basis: 100%; padding-left: 58px; font-size: .9rem; }
.cf-post-info > section { margin-top: 28px; }
.cf-subtitle { color: var(--cf-muted); margin: 6px 0 18px !important; }
.cf-table-wrap { border: 1px solid var(--cf-border); border-radius: 10px; overflow-x: auto; background: var(--cf-panel); }
.cf-paint-table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.cf-paint-table th { text-align: left; background: #20283e; font-weight: 500; }
.cf-paint-table :is(th,td) { padding: 12px; border-bottom: 1px solid var(--cf-border); }
.cf-paint-table tr:last-child td { border-bottom: 0; }
.cf-swatch { display: inline-block; width: 24px; height: 24px; border: 1px solid #b8c0ce; border-radius: 50%; flex-shrink: 0; vertical-align: middle; margin-right: 10px; }
.cf-large-swatch { width: 48px; height: 48px; margin-right: 0; }
.cf-recipe { border: 1px solid var(--cf-border); background: var(--cf-panel); border-radius: 12px; padding: 18px; margin: 16px 0; scroll-margin-top: 90px; }
.cf-recipe header { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.cf-recipe-title { display: flex; gap: 12px; align-items: center; }
.cf-recipe-title .cf-chip { margin-top: 5px; }
.cf-ingredients { margin: 18px 0 12px; }
.cf-ingredients > div { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-top: 1px solid var(--cf-border); }
.cf-ingredients dt { font-weight: 400; }
.cf-ingredients dd { margin: 0; white-space: nowrap; }
.cf-recipe p { color: #bdc5d6; font-size: .9rem; line-height: 1.6; }
.cf-recipe-credit { display: flex; flex-wrap: wrap; gap: 5px; font-size: .8rem; color: var(--cf-muted); margin-top: 16px; }
.cf-recipe-credit a:last-child { margin-left: auto; }
.cf-inline-panel, .cf-editor-panel, .cf-about { border: 1px solid var(--cf-border); background: var(--cf-panel); border-radius: 12px; padding: 24px; margin: 20px 0; }
.cf-inline-panel p, .cf-editor-panel > p, .cf-about p { color: var(--cf-muted); line-height: 1.6; margin: 12px 0; }
.cf-empty { text-align: center; padding: 48px 24px; background: var(--cf-panel); border: 1px solid var(--cf-border); border-radius: 12px; margin: 20px 0; }
.cf-empty > i { color: #c4b5fd; font-size: 2rem; margin-bottom: 20px; }
.cf-empty p { color: var(--cf-muted); line-height: 1.6; max-width: 480px; margin: 12px auto 22px; }
.cf-end-note { text-align: center; color: var(--cf-muted); margin: 28px 0 !important; font-size: .9rem; }
.cf-profile-hero { border: 1px solid var(--cf-border); border-radius: 16px; overflow: hidden; background: var(--cf-panel); }
.cf-profile-cover { height: 112px; background: #252039; border-bottom: 1px solid #514369; padding: 24px; color: #b7a4d7; text-align: right; font-size: .7rem; font-weight: 650; letter-spacing: .2em; }
.cf-profile-content { padding: 0 28px 28px; }
.cf-profile-avatar { width: 88px; height: 88px; font-size: 2rem; border: 5px solid var(--cf-panel); margin-top: -44px; position: relative; }
.cf-profile-actions { float: right; display: flex; gap: 10px; padding-top: 20px; }
.cf-profile-content h1 { margin-top: 12px; font-size: 2rem; overflow-wrap: anywhere; }
.cf-handle { color: #b8a0fa; margin: 6px 0 !important; }
.cf-tagline { color: var(--cf-muted); margin: 12px 0 !important; overflow-wrap: anywhere; }
.cf-profile-layout { display: grid; grid-template-columns: minmax(220px, .4fr) minmax(0, 1fr); gap: 28px; margin-top: 28px; }
.cf-about { margin-top: 0; align-self: start; overflow-wrap: anywhere; }
.cf-about h2 { font-size: 1.1rem; }
.cf-about p { white-space: pre-wrap; }
.cf-about hr { border-color: var(--cf-border); margin: 24px 0; }
.cf-profile-posts { grid-template-columns: 1fr; }
.cf-section-heading { margin: 0 0 18px !important; }
.cf-community .cf-muted { color: var(--cf-muted); font-size: .85rem; line-height: 1.6; }
.cf-status { padding: 12px; border: 1px solid #365947; border-radius: 8px; color: #b2e2c6; margin: 16px 0 !important; }
.cf-error, .cf-community .validation-errors { color: #fda4af; margin: 16px 0; }
.cf-community label { display: block; font-size: .9rem; color: #d5dded; margin: 16px 0; }
.cf-community :is(input:not([type=checkbox]),textarea,select) { display: block; width: 100%; margin-top: 8px; color: #f8fafc; background: #0b1120; border: 1px solid #52617c; border-radius: 7px; padding: 11px 12px; }
.cf-community input[type=checkbox] { width: 18px; height: 18px; accent-color: #8b5cf6; flex: 0 0 18px; }
.cf-community textarea { resize: vertical; min-height: 100px; }
.cf-community .invalid { border-color: #fb7185 !important; }
.cf-form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.cf-draft-row { display: flex; gap: 20px; padding: 20px; border: 1px solid var(--cf-border); border-radius: 12px; margin-bottom: 16px; }
.cf-draft-row img { width: 130px; height: 140px; object-fit: cover; border-radius: 8px; }
.cf-draft-row h2 { font-size: 1.15rem; margin: 8px 0; }
.cf-draft-row p { overflow-wrap: anywhere; margin: 8px 0; }
.cf-composer-grid { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 28px; align-items: start; }
.cf-composer-grid .cf-editor-panel { margin-top: 0; }
.cf-editor-panel h2 small { color: var(--cf-muted); font-size: .8rem; font-weight: 400; margin-left: 6px; }
.cf-upload-preview { width: 100%; max-height: 400px; object-fit: contain; border-radius: 10px; margin-top: 20px; background: #080e1b; }
.cf-paint-input { padding-bottom: 18px; margin-bottom: 18px; border-bottom: 1px solid var(--cf-border); }
.cf-community .cf-recipe-choice { display: flex; align-items: center; gap: 10px; padding: 14px 12px; border: 1px solid var(--cf-border); border-radius: 8px; cursor: pointer; }
.cf-recipe-choice small { display: block; color: var(--cf-muted); margin-top: 5px; }
.cf-review-panel { display: flex; gap: 14px; padding: 18px; background: #1b1b31; border: 1px solid #403859; border-radius: 12px; margin-bottom: 20px; }
.cf-review-panel > i { color: #bca3ff; font-size: 1.4rem; }
.cf-review-panel h2 { font-size: 1.05rem; }
.cf-review-panel p { color: var(--cf-muted); font-size: .85rem; margin-top: 8px; line-height: 1.6; }
@media (max-width: 1000px) { .cf-detail-grid, .cf-composer-grid { grid-template-columns: 1fr; } .cf-detail-photo { max-height: 650px; object-fit: contain; } .cf-profile-layout { grid-template-columns: 1fr; gap: 0; } }
@media (max-width: 720px) {
    .cf-community { padding: 12px 0 32px; }
    .cf-page-heading { flex-direction: column; gap: 18px; }
    .cf-feed-grid { grid-template-columns: 1fr; }
    .cf-page-heading .cf-actions { width: 100%; }
    .cf-page-heading .cf-actions .cf-button { flex: 1; }
    .cf-profile-content { padding: 0 18px 20px; }
    .cf-profile-actions { float: none; padding-top: 16px; flex-wrap: wrap; }
    .cf-form-grid { grid-template-columns: 1fr; gap: 0; }
    .cf-profile-cover { height: 90px; }
    .cf-editor-panel { padding: 18px; }
    .cf-draft-row { flex-direction: column; }
    .cf-draft-row img { width: 100%; height: 220px; }
    .cf-card-author { padding: 12px; }
    .cf-author strong { font-size: 1rem; }
    .cf-author small { font-size: .8rem; }
}
@media (prefers-reduced-motion: reduce) { .cf-photo-link img { transition: none; } }
.cf-avatar { object-fit: cover; }
.cf-avatar-editor { display: grid; gap: .75rem; padding: 1rem; max-width: 34rem; }
.cf-avatar-editor input[type=file] { display: block; max-width: 100%; margin-top: .5rem; }
.cf-avatar-editor p { font-size: .85rem; color: var(--mud-palette-text-secondary); }
.cf-team-member { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; padding: 1rem; border-bottom: 1px solid #33334a; }
.add-paints-dialog .mud-dialog-actions { position: sticky; bottom: 0; z-index: 2; background: var(--mud-palette-surface); flex-wrap: wrap; border-top: 1px solid #45415e; }
.add-paints-dialog summary { cursor: pointer; padding: 10px 0; color: #c4b5fd; }
@media (max-width: 600px) { .add-paints-dialog .mud-dialog-actions .unit-paint-dialog-tip { display: none; } .add-paints-dialog .paint-browser-list { max-height: 45dvh; overflow-y: auto; } .add-paints-dialog .add-paints-layout { min-height: 0; } }
@media (max-width: 600px) { .add-paints-dialog .mud-dialog-actions { display: grid; grid-template-columns: auto 1fr; gap: 6px; } .add-paints-dialog .mud-dialog-actions .mud-spacer { display: none; } .add-paints-dialog .quick-save-set { grid-column: 1 / -1; } .add-paints-dialog .paint-browser-row button { min-height: 44px; } }

.cf-community .cf-affiliation { display: grid; gap: 16px; }
.cf-community .cf-affiliation .cf-button { justify-self: start; }
.cf-community .cf-team-intro { margin: 24px 0; }

.cf-post-paints { display:grid; gap:12px; margin:18px 0; }
.cf-post-paint { padding:14px; border:1px solid #38445c; border-radius:12px; background:#151d2c; }
.cf-post-paint-heading { display:flex; align-items:center; gap:12px; }
.cf-post-paint-heading > div { flex:1; min-width:0; overflow-wrap:anywhere; }
.cf-post-paint-heading small { display:block; color:#aab7cd; }
.cf-post-paint-heading button { min-width:44px; min-height:44px; }
.cf-community .cf-post-paint label { margin:10px 0 0; font-size:.8rem; }

.cf-post-paint-actions { display:flex; align-items:center; flex-wrap:wrap; gap:16px; margin-top:16px; }

@media(max-width:600px){ .paint-shopping-dialog .mud-dialog-content { padding:16px; min-width:0; } .paint-shopping-dialog .mud-dialog-title { padding:20px 16px 12px; } }

/* Logged-out community introduction; real public posts remain browseable below. */
.cf-community-preview { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(24px, 4vw, 56px); align-items: center; padding: clamp(24px, 4vw, 48px); margin-bottom: 24px; border: 1px solid #494064; border-radius: 16px; background: radial-gradient(ellipse at 0 0, #7c3aed24, transparent 65%), #12192d; }
.cf-preview-eyebrow { display: block; margin-bottom: 16px; color: #c4b5fd; font-size: .76rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.cf-preview-copy > p { color: #b8c5d8; line-height: 1.7; margin: 20px 0 24px; }
.cf-preview-features { display: grid; gap: 24px; }
.cf-preview-features article { display: flex; align-items: flex-start; gap: 16px; }
.cf-preview-features article > i { color: #c4b5fd; font-size: 1.15rem; width: 24px; flex-shrink: 0; padding-top: 4px; }
.cf-preview-features h2 { font-size: 1.05rem; }
.cf-preview-features p { color: #a6b2c8; font-size: .9rem; line-height: 1.6; margin-top: 7px; }
@media (max-width: 760px) { .cf-community-preview { grid-template-columns: 1fr; } }

.cf-accessories { border: 1px solid #34354c; border-radius: 12px; padding: 16px; margin: 20px 0; }
.cf-accessory-row { display: flex; flex-wrap: wrap; align-items: end; gap: 12px; margin-bottom: 16px; }
.cf-accessory-row label { flex: 1 1 170px; min-width: 0; }
.cf-accessory-row select { width: 100%; padding: 10px; background: #151827; color: #f3f0ff; border: 1px solid #50506c; border-radius: 8px; }
