/* css/community.css
 *
 * The Community feed (Ben, 2026-10-07): Talentville's and Facebook's look --
 * white post cards, round faces, comments in grey bubbles -- in this site's
 * colours. Two columns, the feed and a narrower one beside it; the second goes
 * when the page is too narrow to give the feed a comfortable width.
 *
 * THE BREAK IS ON THE PAGE'S WIDTH, NOT THE WINDOW'S
 *
 * A container query, so the sidebar sliding in and out moves it as it should:
 * what matters is how much room this page has, which the window's width does
 * not say. See includes/community.php for the markup.
 */

#community-page-content {
    container-type: inline-size;
    container-name: community;
}

.cm-page-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.cm-layout {
    display: grid;
    grid-template-columns: minmax(0, 640px) minmax(240px, 300px);
    gap: 24px;
    align-items: start;
}

.cm-main {
    min-width: 0;
}

.cm-side {
    position: sticky;
    top: calc(var(--header-height, 50px) + 12px);
    display: flex;
    flex-direction: column;
    gap: 16px;
}

@container community (max-width: 860px) {
    .cm-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .cm-side {
        display: none;
    }
}

.cm-loading,
.cm-empty {
    text-align: center;
    padding: 40px 16px;
    color: var(--muted);
}

.cm-loading i,
.cm-empty i {
    font-size: 28px;
    display: block;
    margin-bottom: 10px;
}

.cm-end {
    text-align: center;
    color: var(--muted);
    font-size: 14px;
    margin: 18px 0 30px;
}

.cm-sentinel {
    text-align: center;
    color: var(--muted);
    padding: 20px 0 30px;
    font-size: 20px;
}

/* ---------------------------------------------------------------- faces */

.cm-avatar {
    flex: 0 0 auto;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    background: var(--panel-head-bg);
    color: var(--ink);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 16px;
}

.cm-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.cm-avatar--sm {
    width: 32px;
    height: 32px;
    font-size: 13px;
}

/* ---------------------------------------------------------- the entry box */

.cm-composer,
.cm-post,
.cm-panel,
.cm-hidden-note {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 10px;
    box-shadow: 0 1px 2px rgba(13, 13, 26, .06);
}

.cm-composer {
    display: flex;
    gap: 10px;
    padding: 14px;
    margin-bottom: 16px;
}

.cm-composer-box {
    flex: 1 1 auto;
    min-width: 0;
}

.cm-composer .tox-tinymce,
.cm-compose .tox-tinymce,
.cm-edit .tox-tinymce {
    border: 1px solid var(--border) !important;
    border-radius: 18px !important;
    background: var(--cream);
}

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

.cm-post-btn {
    background: var(--ink);
    color: var(--white);
    border: 0;
    border-radius: 6px;
    padding: 7px 22px;
    font: 600 14px var(--font-sans);
    cursor: pointer;
}

.cm-post-btn:hover {
    background: var(--gold);
    color: var(--ink);
}

.cm-post-btn:disabled {
    opacity: .5;
    cursor: default;
}

.cm-post-btn--sm {
    padding: 4px 14px;
    font-size: 13px;
}

/* --------------------------------------------------------------- a post */

.cm-post {
    margin-bottom: 16px;
    transition: opacity .25s;
}

.cm-post.is-going {
    opacity: 0;
}

.cm-head {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px 6px;
}

.cm-who {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    flex-direction: column;
    line-height: 1.25;
}

.cm-name {
    font-weight: 600;
    color: var(--ink);
    text-decoration: none;
}

a.cm-name:hover {
    text-decoration: underline;
}

.cm-when {
    color: var(--muted);
    font-size: 13px;
}

.cm-body {
    padding: 4px 16px 10px;
    font-size: 15px;
    line-height: 1.45;
    color: var(--ink);
    overflow-wrap: anywhere;
}

.cm-body p,
.cm-c-body p {
    margin: 0 0 .5em;
}

.cm-body p:last-child,
.cm-c-body p:last-child {
    margin-bottom: 0;
}

.cm-folded {
    max-height: 9.5em;
    overflow: hidden;
    -webkit-mask-image: linear-gradient(to bottom, #000 70%, transparent);
    mask-image: linear-gradient(to bottom, #000 70%, transparent);
}

.cm-c-body.cm-folded {
    max-height: 7em;
}

/* While sliding open or shut, the text is clipped to the moving height. */
.cm-body[data-sliding],
.cm-c-body[data-sliding] {
    overflow: hidden;
}

/* Brought back into view by Show less: it stops below the site header, not
 * under it. */
.cm-post,
.cm-comment {
    scroll-margin-top: calc(var(--header-height, 50px) + 12px);
}

.cm-seemore {
    background: none;
    border: 0;
    padding: 0 16px 10px;
    color: var(--muted);
    font: 600 14px var(--font-sans);
    cursor: pointer;
}

.cm-bubble .cm-seemore {
    padding: 2px 0 0;
}

.cm-seemore:hover {
    text-decoration: underline;
}

.cm-link {
    color: var(--color-blue);
    text-decoration: underline;
    overflow-wrap: anywhere;
}

/* The post's options: the three dots, and what they open. */
.cm-menu {
    position: relative;
}

.cm-menu-btn {
    background: none;
    border: 0;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    color: var(--muted);
    cursor: pointer;
    font-size: 17px;
}

.cm-menu-btn:hover,
.cm-menu.open .cm-menu-btn {
    background: var(--gold-tint);
    color: var(--ink);
}

.cm-menu-list {
    display: none;
    position: absolute;
    right: 0;
    top: 36px;
    z-index: 20;
    min-width: 210px;
    list-style: none;
    margin: 0;
    padding: 6px 0;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 8px;
    box-shadow: 0 6px 18px rgba(13, 13, 26, .14);
}

.cm-menu.open .cm-menu-list {
    display: block;
}

.cm-menu-list button {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    background: none;
    border: 0;
    padding: 8px 14px;
    text-align: left;
    font: 14px var(--font-sans);
    color: var(--ink);
    cursor: pointer;
}

.cm-menu-list button i {
    width: 16px;
    color: var(--muted);
}

.cm-menu-list button:hover {
    background: var(--gold-tint);
}

/* Comment, and the count that folds the comments. */
.cm-bar {
    display: flex;
    align-items: center;
    gap: 4px;
    margin: 0 14px;
    padding: 4px 0;
    border-top: 1px solid var(--border);
}

.cm-act {
    background: none;
    border: 0;
    border-radius: 6px;
    padding: 6px 12px;
    color: var(--muted);
    font: 600 14px var(--font-sans);
    cursor: pointer;
}

.cm-act:hover {
    background: var(--gold-tint);
    color: var(--ink);
}

.cm-count {
    margin-left: auto;
    background: none;
    border: 0;
    color: var(--muted);
    font: 14px var(--font-sans);
    cursor: pointer;
}

.cm-count:hover {
    text-decoration: underline;
}

/* ------------------------------------------- pictures, previews, post types */

/* A post of pictures alone has no words; its empty text takes no room. */
.cm-body:empty {
    display: none;
}

.cm-who-sub {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

/* "Bumped", beside the time, for Staff only. */
.cm-bumped {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    font-weight: 600;
    color: var(--primary-purple);
}

.cm-kind {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 1px 8px;
    border-radius: 999px;
    background: var(--panel-head-bg);
    color: #7a5d12;
    font-size: 12px;
    font-weight: 600;
}

/* The entry box's tools: Photo, the post type, and the pictures waiting. */
/* One row: Photo, the post type, B I U, then a gap taking what room is left,
 * then the character count and Post. */
.cm-foot-gap {
    flex: 1 1 auto;
}

.cm-fmt {
    display: inline-flex;
    gap: 2px;
    flex: 0 0 auto;
}

.cm-fmt button {
    width: 28px;
    height: 28px;
    border: 0;
    border-radius: 6px;
    background: none;
    color: var(--muted);
    font: 15px var(--font-sans);
    cursor: pointer;
}

.cm-fmt button:hover {
    background: var(--gold-tint);
    color: var(--ink);
}

/* A phone's width: the row wraps rather than pushing Post out of the card --
 * the tools on one line, Post with its count on the next, at the right. The
 * post type menu gives up width first. */
@container community (max-width: 560px) {
    .cm-composer-foot {
        flex-wrap: wrap;
        row-gap: 8px;
    }

    .cm-kind-pick {
        flex: 1 1 120px;
        min-width: 0;
    }

    .cm-foot-gap {
        flex-basis: 100%;
        height: 0;
    }

    .cm-composer-foot .cm-chars {
        margin-left: auto;
    }

    .cm-composer-foot .cm-chars[hidden] + .cm-post-btn {
        margin-left: auto;
    }
}

/* The style the cursor is in: on while typing in bold, say. */
.cm-fmt button[aria-pressed="true"] {
    background: var(--panel-head-bg);
    color: var(--ink);
}

.cm-composer-foot .cm-post-btn {
    flex: 0 0 auto;
}

/* The character count, once a writer nears the limit. */
.cm-chars {
    flex: 0 0 auto;
    font-size: 12px;
    color: var(--muted);
    white-space: nowrap;
}

.cm-chars[hidden] {
    display: none;
}

.cm-chars.is-over {
    color: var(--danger);
    font-weight: 600;
}

/* Under a comment box, on a line of its own beneath the entry. */
.cm-compose {
    flex-wrap: wrap;
}

.cm-chars--under {
    flex-basis: 100%;
    text-align: right;
    padding: 0 40px 0 0;
}

.cm-tool {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 10px;
    border-radius: 6px;
    color: var(--muted);
    font: 600 13px var(--font-sans);
    cursor: pointer;
}

.cm-tool:hover {
    background: var(--gold-tint);
    color: var(--ink);
}

.cm-tool i {
    color: #1d9e43;
    font-size: 16px;
}

.cm-kind-pick {
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 4px 8px;
    font: 13px var(--font-sans);
    color: var(--ink);
    background: var(--white);
}

.cm-attach {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.cm-attach:not(:empty) {
    margin-top: 8px;
}

.cm-thumb {
    position: relative;
    width: 84px;
    height: 84px;
    border-radius: 8px;
    overflow: hidden;
    background: var(--cream);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--muted);
}

.cm-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cm-thumb-x,
.cm-card-x {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 0;
    background: rgba(13, 13, 26, .65);
    color: var(--white);
    font-size: 12px;
    cursor: pointer;
    z-index: 2;
}

.cm-preview:not(:empty) {
    margin-top: 8px;
}

/* A post's pictures: one fills the width, more sit in a grid. */
.cm-media {
    display: grid;
    gap: 3px;
    margin: 0 0 8px;
}

.cm-media--2,
.cm-media--4 {
    grid-template-columns: 1fr 1fr;
}

.cm-media--3 {
    grid-template-columns: 2fr 1fr;
    grid-template-rows: 1fr 1fr;
}

.cm-media--3 .cm-photo-wrap:first-child {
    grid-row: span 2;
}

/* Each picture and, for its writer or Staff, the x that takes it off. */
.cm-photo-wrap {
    position: relative;
    min-width: 0;
    overflow: hidden;
}

.cm-photo {
    display: block;
    width: 100%;
    height: 100%;
    padding: 0;
    border: 0;
    background: var(--cream);
    cursor: zoom-in;
    overflow: hidden;
}

.cm-photo-x {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 0;
    background: rgba(13, 13, 26, .65);
    color: var(--white);
    font-size: 13px;
    cursor: pointer;
    z-index: 2;
}

.cm-photo-x:hover {
    background: var(--danger);
}

.cm-photo img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cm-media--1 .cm-photo img {
    height: auto;
    max-height: 560px;
    object-fit: contain;
    background: var(--cream);
}

.cm-media--2 .cm-photo-wrap,
.cm-media--4 .cm-photo-wrap {
    aspect-ratio: 1 / 1;
}

.cm-media--3 .cm-photo-wrap {
    min-height: 150px;
}

.cm-photo-pop {
    padding: 10px;
}

.cm-photo-pop .swal2-image {
    max-width: 90vw;
    max-height: 82vh;
    margin: 0;
}

/* The link preview card, in a post and in the entry box. */
.cm-card {
    position: relative;
    margin: 0 14px 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
    overflow: hidden;
    background: #f7f8fa;
}

.cm-preview .cm-card {
    margin: 0;
}

.cm-card--loading {
    padding: 14px;
    color: var(--muted);
    font-size: 13px;
}

.cm-card-link {
    display: flex;
    color: inherit;
    text-decoration: none;
}

/* A preview's picture: 150px across at most, whatever size the picture is
 * (Ben, 2026-10-07). width and min-width as well as flex-basis, because a flex
 * item will not shrink below its content's own width unless told -- which is
 * how a 1000px poster pushed its column wide open. */
.cm-card-img,
.cm-card-poster {
    flex: 0 0 150px;
    width: 150px;
    max-width: 150px;
    min-width: 0;
    background: var(--cream);
    overflow: hidden;
}

.cm-card-img img,
.cm-card-poster img {
    display: block;
    width: 100%;
    max-width: 100%;
    height: 100%;
    min-height: 110px;
    object-fit: cover;
}

/* The FAQ's and the Editor Tutorial's tile when there is no picture (Ben,
   2026-10-07): a question mark or an open book, square, beside the text. */
.cm-card-icon {
    flex: 0 0 auto;
    width: 72px;
    height: 72px;
    margin: 14px 0 14px 14px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 34px;
    align-self: flex-start;
}

/* A tutorial page's first picture is a screenshot or a logo, not a photo: the
   whole of it, rather than a crop that cuts the middle out. */
.cm-card--tutorial .cm-card-img {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    padding: 8px;
    box-sizing: border-box;
}

.cm-card--tutorial .cm-card-img img {
    height: auto;
    min-height: 0;
    max-height: 140px;
    object-fit: contain;
}

.cm-card-icon--faq {
    background: var(--primary-dim);
    color: var(--primary-purple);
}

.cm-card-icon--tutorial {
    background: var(--panel-head-bg);
    color: var(--gold);
}

.cm-card-text {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
    padding: 10px 14px;
}

.cm-card-site {
    font-size: 11px;
    letter-spacing: .04em;
    color: var(--muted);
}

.cm-card-title {
    font-weight: 600;
    font-size: 15px;
    color: var(--ink);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Five lines of the page's own description -- two cut most of them off at the
 * first sentence (Ben, 2026-10-07). */
.cm-card-desc {
    font-size: 13px;
    line-height: 1.45;
    color: var(--muted);
    display: -webkit-box;
    -webkit-line-clamp: 5;
    line-clamp: 5;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* A card for one of our own pages: a screenplay's poster, a member's photo. */
/* A poster is tall: a little more height than a web page's picture. */
.cm-card-poster img {
    min-height: 180px;
}

.cm-card-face {
    flex: 0 0 auto;
    width: 72px;
    height: 72px;
    margin: 14px 0 14px 14px;
    border-radius: 10px;
    overflow: hidden;
    background: var(--panel-head-bg);
    color: var(--ink);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    font-weight: 600;
}

/* A member's photo (Ben, 2026-10-07): the whole picture at its own shape,
   inside 120px either way, with rounded corners -- not filled, not cropped,
   not a circle. The box shrinks to the picture, so nothing shows behind it. */
.cm-card-face--photo {
    width: auto;
    height: auto;
    max-width: 120px;
    max-height: 120px;
    background: none;
    border-radius: 0;
    align-self: flex-start;
}

.cm-card-face--photo img {
    display: block;
    width: auto;
    height: auto;
    max-width: 120px;
    max-height: 120px;
    border-radius: 10px;
}

.cm-card-title--script {
    font-family: 'Playfair Display', Georgia, serif;
    font-weight: 700;
    font-size: 17px;
}

.cm-card-episode {
    font-size: 13px;
    color: var(--ink);
}

.cm-card-facts {
    font-size: 12px;
    color: var(--muted);
}

.cm-card-logline {
    font-size: 14px;
    font-style: italic;
    color: var(--ink);
    line-height: 1.4;
}

.cm-card-link:hover .cm-card-title {
    text-decoration: underline;
}

/* A narrow feed: the picture stays beside the words -- never stacked above
 * them at full width -- and smaller still. */
@container community (max-width: 520px) {
    .cm-card-img,
    .cm-card-poster {
        flex-basis: 96px;
        width: 96px;
        max-width: 96px;
    }

    .cm-card-img img {
        min-height: 90px;
    }

    .cm-card-poster img {
        min-height: 130px;
    }
}

/* A YouTube or Vimeo card: the thumbnail across the top with a play button,
 * the title under it. Pressing play puts the player in the same 16:9 box. */
.cm-video .cm-card-x {
    z-index: 3;
}

.cm-video-box {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #000;
}

.cm-video-play {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    padding: 0;
    border: 0;
    background: #000;
    cursor: pointer;
}

.cm-video-play img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.cm-video-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 64px;
    height: 64px;
    margin: -32px 0 0 -32px;
    border-radius: 50%;
    background: rgba(13, 13, 26, .72);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    padding-left: 4px;
    transition: background .15s, transform .15s;
}

.cm-video-play:hover .cm-video-icon {
    background: #d6336c;
    transform: scale(1.06);
}

.cm-video-frame {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* The "Show" dropdown over the list: one line however many types there are. */
.cm-filterbar {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    align-items: center;
    gap: 8px;
    margin: 0 0 12px;
}

.cm-filter-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font: 600 13px var(--font-sans);
    color: var(--muted);
}

.cm-filter-label i {
    color: var(--gold);
}

.cm-kind-filter,
.cm-who-filter {
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 5px 10px;
    font: 14px var(--font-sans);
    color: var(--ink);
    background: var(--white);
    cursor: pointer;
}

.cm-posts.is-loading {
    opacity: .5;
    transition: opacity .15s;
}

/* ------------------------------------------- a discussion on another page */

/* A script's summary card, a blog post's comments: the same thread, drawn
 * flat inside the page's own card rather than as cards within a card. */
.cm-embed {
    container-type: inline-size;
    container-name: community;
    padding: 6px 4px 4px;
}

.cm-embed .cm-composer,
.cm-embed .cm-post,
.cm-embed .cm-hidden-note {
    border: 0;
    border-radius: 0;
    box-shadow: none;
    margin: 0;
}

.cm-embed .cm-composer {
    padding: 8px 8px 14px;
}

.cm-embed .cm-post,
.cm-embed .cm-hidden-note {
    border-top: 1px solid var(--border);
}

.cm-embed .cm-empty {
    padding: 18px 16px;
}

.cm-embed .cm-empty i {
    display: none;
}

.cm-embed .cm-end {
    display: none;
}

.blog-comments {
    margin: 32px 0 8px;
    padding-top: 18px;
    border-top: 1px solid var(--border);
}

.blog-comments-title {
    font: 600 20px var(--font-sans);
    margin: 0 0 12px;
    color: var(--ink);
}

.blog-comments .cm-embed {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 10px;
}

.blog-comments-signin {
    margin: 0;
    padding: 14px 16px;
    background: var(--gold-tint);
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--ink);
}

/* ------------------------------------------------------------------ likes */

.cm-like.is-liked,
.cm-like.is-liked:hover {
    color: #d6336c;
}

/* The heart and its number: on the bar, it sits on the right before the
 * comment count; on a comment, it hangs off the bubble's corner. */
.cm-likes {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: none;
    border: 0;
    padding: 0;
    color: var(--muted);
    font: 14px var(--font-sans);
    cursor: pointer;
}

.cm-likes[hidden] {
    display: none;
}

.cm-likes i {
    color: #d6336c;
}

.cm-likes:hover .cm-likes-n {
    text-decoration: underline;
}

.cm-bar .cm-likes {
    margin-left: auto;
}

.cm-bar .cm-likes:not([hidden]) + .cm-count {
    margin-left: 14px;
}

.cm-bubble {
    position: relative;
}

.cm-likes--comment {
    position: absolute;
    right: -10px;
    bottom: -10px;
    background: var(--white);
    border-radius: 999px;
    padding: 1px 6px;
    font-size: 12px;
    box-shadow: 0 1px 3px rgba(13, 13, 26, .18);
}

/* Room under a bubble for the heart hanging off it. */
.cm-bubble:has(.cm-likes--comment:not([hidden])) + .cm-c-meta {
    padding-top: 6px;
}

/* -------------------------------------------------------- mentions, live */

.cm-mention {
    color: var(--color-blue);
    font-weight: 600;
    text-decoration: none;
}

a.cm-mention:hover {
    text-decoration: underline;
}

/* "3 new posts": pinned under the header while the reader scrolls, so it is
 * there whenever they look up. */
.cm-newbar {
    position: sticky;
    top: calc(var(--header-height, 50px) + 8px);
    z-index: 15;
    display: block;
    margin: 0 auto 12px;
    background: var(--ink);
    color: var(--white);
    border: 0;
    border-radius: 999px;
    padding: 7px 18px;
    font: 600 14px var(--font-sans);
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(13, 13, 26, .25);
}

.cm-newbar:hover {
    background: var(--gold);
    color: var(--ink);
}

/* ------------------------------------------------------------- comments */

.cm-comments {
    padding: 2px 14px 10px;
}

.cm-comments.is-folded .cm-comment-list {
    display: none;
}

.cm-comments:empty,
.cm-comments.is-folded:not(:has(.cm-compose)) {
    padding-bottom: 4px;
}

.cm-link-btn {
    background: none;
    border: 0;
    padding: 0;
    color: var(--muted);
    font: 600 13px var(--font-sans);
    cursor: pointer;
}

.cm-link-btn:hover {
    text-decoration: underline;
    color: var(--ink);
}

.cm-viewall {
    margin: 6px 0 4px;
    font-size: 14px;
}

.cm-comment {
    display: flex;
    gap: 8px;
    margin-top: 8px;
}

.cm-c-main {
    flex: 1 1 auto;
    min-width: 0;
}

.cm-bubble {
    display: inline-block;
    max-width: 100%;
    background: #f0f2f5;
    border-radius: 16px;
    padding: 7px 12px 8px;
    line-height: 1.35;
}

.cm-bubble .cm-name {
    font-size: 13px;
}

.cm-c-body {
    font-size: 14px;
    color: var(--ink);
    overflow-wrap: anywhere;
}

.cm-c-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    padding: 2px 12px 0;
    font-size: 12px;
}

.cm-c-meta .cm-when {
    font-size: 12px;
}

.cm-c-meta .cm-link-btn {
    font-size: 12px;
}

.cm-replies {
    margin-top: 2px;
}

.cm-replies.is-folded .cm-reply-list {
    display: none;
}

.cm-replies-toggle {
    margin: 4px 0 0 12px;
}

.cm-reply {
    margin-top: 6px;
}

/* A comment or reply box, opened where it is wanted. */
.cm-compose {
    display: flex;
    gap: 8px;
    margin-top: 8px;
}

.cm-compose-box {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    align-items: flex-end;
    gap: 4px;
}

.cm-compose-box .tox-tinymce {
    flex: 1 1 auto;
    min-width: 0;
}

.cm-send {
    flex: 0 0 auto;
    margin-bottom: 6px;
    background: none;
    border: 0;
    color: var(--muted);
    font-size: 16px;
    cursor: pointer;
    padding: 4px;
}

.cm-send:hover {
    color: var(--gold);
}

/* Edit, in place of the text. */
.cm-edit {
    padding: 4px 14px 10px;
}

.cm-bubble .cm-edit {
    padding: 4px 0 2px;
    min-width: min(420px, 70vw);
}

.cm-edit-foot {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 14px;
    margin-top: 6px;
}

/* What stays where a hidden post was, with its Undo. */
.cm-hidden-note {
    padding: 12px 16px;
    margin-bottom: 16px;
    color: var(--muted);
    font-size: 14px;
}

.cm-hidden-note .cm-link-btn {
    font-size: 14px;
    color: var(--color-blue);
}

.cm-hidden-link {
    font-size: 14px;
}

/* ---------------------------------------------------- the right column */

.cm-panel {
    padding: 14px 16px;
}

.cm-panel-head {
    margin: 0 0 10px;
    font: 600 16px var(--font-sans);
    color: var(--ink);
}

.cm-panel-head i {
    color: var(--gold);
    margin-right: 6px;
}

.cm-side-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.cm-side-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 0;
}

.cm-side-row + .cm-side-row {
    border-top: 1px solid var(--border);
}

.cm-side-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
    line-height: 1.3;
}

.cm-side-name,
.cm-review-title {
    font-weight: 600;
    font-size: 14px;
    color: var(--ink);
    text-decoration: none;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

a.cm-side-name:hover {
    text-decoration: underline;
}

.cm-review-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-weight: 700;
}

.cm-side-sub {
    font-size: 12px;
    color: var(--muted);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cm-side-empty {
    margin: 0;
    color: var(--muted);
    font-size: 14px;
}

.cm-review {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    min-width: 0;
    background: none;
    border: 0;
    padding: 0;
    text-align: left;
    font-family: var(--font-sans);
    cursor: pointer;
}

.cm-review:hover .cm-review-title {
    text-decoration: underline;
}

.cm-chip {
    flex: 0 0 auto;
    box-sizing: border-box;
    width: 70px;
    text-align: center;
    border-radius: 999px;
    padding: 2px 8px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .02em;
    text-transform: uppercase;
}

.cm-chip--ai {
    background: #ece8fd;
    color: #4b2fc0;
}

.cm-chip--analyst {
    background: var(--panel-head-bg);
    color: #7a5d12;
}

.cm-chip--member {
    background: var(--shared-tint);
    color: #1b6b3a;
}

.cm-panel-links {
    display: flex;
    gap: 16px;
}

.cm-panel-more {
    display: inline-block;
    margin-top: 8px;
    font-size: 13px;
    font-weight: 600;
    color: var(--color-blue);
}

/* The Hidden members dialog. */
.cm-hidden-dialog {
    text-align: left;
}

.cm-hidden-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.cm-hidden-list .cm-side-text {
    flex: 1 1 auto;
}

.cm-unhide {
    background: none;
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 4px 10px;
    font: 600 13px var(--font-sans);
    cursor: pointer;
}

.cm-unhide:hover {
    background: var(--gold-tint);
}

@media (max-width: 600px) {
    .cm-composer {
        padding: 10px;
    }
}

/* The bullhorn's dialog (Ben, 2026-10-07): a message box over the card as other
   members will see it, or the list of what to do first. See
   includes/communitypromote.php. Left-aligned inside SweetAlert's centred box. */
.cm-promote-pop .swal2-html-container {
    text-align: left;
    margin: 12px 18px 4px;
}

.cm-promote-msg {
    width: 100%;
    box-sizing: border-box;
    min-height: 74px;
    padding: 9px 11px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font: 15px/1.45 var(--font-sans);
    color: var(--text-dark);
    resize: vertical;
}

.cm-promote-msg:focus {
    outline: none;
    border-color: var(--primary-purple);
}

.cm-promote-card {
    margin-top: 12px;
}

/* A preview, not a way off the page: the card's own link waits for the post. */
.cm-promote-card .cm-card {
    pointer-events: none;
}

.cm-promote-lead {
    margin: 0 0 8px;
    color: var(--text-dark);
}

.cm-promote-missing {
    margin: 0;
    padding-left: 20px;
    list-style: disc;
    color: var(--text-dark);
}

.cm-promote-missing li + li {
    margin-top: 4px;
}

.cm-promote-missing + .cm-promote-lead {
    margin-top: 12px;
}
