/* «مجتمع المصارعة» (pages/community.njk, assets/community.js): the site's own colours and type, a chat app's layout.
   Rooms on the right, the room on the left (one at a time on a phone). Light and dark (html.arw-dark). */
.cm-body{ --cm-mine:#0e9594; --cm-mine-ink:#fff; --cm-bubble:var(--card); --cm-head-h:72px; --cm-r:9px;
  /* the bubble's tail, pointing right or left (drawn in the bubble's own colour) */
  --cm-tail-r:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 13'%3E%3Cpath d='M0 13h8.3c1.3 0 2-1.5 1.2-2.6L2 0H0z'/%3E%3C/svg%3E");
  --cm-tail-l:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 13'%3E%3Cpath d='M10 13H1.7C.4 13-.3 11.5.5 10.4L8 0h2z'/%3E%3C/svg%3E"); }
html.arw-dark .cm-body{ --cm-mine:#13807f; --cm-bubble:color-mix(in srgb, #fff 7%, var(--card)); }
.cm-page [hidden]{ display:none !important; }
.cm-page{ display:block; max-width:1440px; margin:0 auto; padding:18px 20px 28px; }
.cm-app{ display:grid; grid-template-columns:340px minmax(0,1fr); height:calc(100dvh - var(--cm-top, 76px) - 40px); min-height:440px; background:var(--card); border:1px solid var(--line); border-radius:22px; overflow:hidden; box-shadow:0 18px 44px -28px rgba(0,0,0,.28); }

/* ── the rooms ───────────────────────────────────────────────────────────── */
.cm-side{ display:flex; flex-direction:column; min-height:0; border-inline-end:1px solid var(--line); background:linear-gradient(-180deg, color-mix(in srgb, var(--teal) 6%, var(--card)), var(--card) 180px); }
.cm-side-head{ padding:22px 20px 14px; }
.cm-title{ display:flex; align-items:center; gap:10px; margin:0; font:900 23px/1.3 'Cairo',sans-serif; color:var(--ink); }
.cm-live-dot{ width:10px; height:10px; border-radius:50%; background:#22c55e; box-shadow:0 0 0 0 rgba(34,197,94,.6); animation:cm-live 2s ease-out infinite; flex:none; }
@keyframes cm-live{ 0%{ box-shadow:0 0 0 0 rgba(34,197,94,.55); } 80%,100%{ box-shadow:0 0 0 9px rgba(34,197,94,0); } }
.cm-sub{ margin:6px 0 0; color:var(--muted); font-size:14px; line-height:1.7; }
.cm-total{ display:inline-flex; align-items:center; gap:6px; margin-top:10px; padding:4px 12px; border-radius:999px; background:rgba(34,197,94,.12); color:#15803d; font:800 12.5px 'Cairo',sans-serif; }
html.arw-dark .cm-total{ color:#4ade80; }
.cm-rooms{ flex:1; min-height:0; overflow-y:auto; padding:4px 10px 10px; display:flex; flex-direction:column; gap:3px; scrollbar-width:thin; }
.cm-room{ position:relative; display:grid; grid-template-columns:48px minmax(0,1fr) auto; gap:12px; align-items:center; width:100%; padding:10px 10px; border:0; border-radius:16px; background:transparent; color:var(--ink); text-align:start; cursor:pointer; font:inherit; transition:background .18s ease, transform .18s ease; }
.cm-room:hover{ background:color-mix(in srgb, var(--ink) 5%, transparent); }
.cm-room.is-on{ background:color-mix(in srgb, hsl(var(--h) 60% 45%) 13%, var(--card)); }
.cm-room.is-on::before{ content:""; position:absolute; inset-inline-start:0; top:14px; bottom:14px; width:4px; border-radius:4px; background:hsl(var(--h) 62% 45%); }
.cm-mark{ display:flex; align-items:center; justify-content:center; width:48px; height:48px; border-radius:15px; background:linear-gradient(-135deg, hsl(var(--h) 60% 50%), hsl(var(--h) 62% 31%)); color:#fff; font:900 12.5px/1 'Cairo',sans-serif; letter-spacing:.3px; flex:none; box-shadow:0 6px 14px -8px hsl(var(--h) 60% 35%); overflow:hidden; }
.cm-mark-logo{ background:#0f5f5e; padding:0; }
.cm-mark-logo img{ width:100%; height:100%; object-fit:cover; display:block; }
.cm-room-tx{ min-width:0; display:flex; flex-direction:column; gap:1px; }
.cm-room-tx b{ font:800 15px/1.4 'Cairo',sans-serif; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.cm-room-last{ color:var(--muted); font-size:13px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.cm-room.has-new .cm-room-last{ color:var(--ink); font-weight:700; }
.cm-room-meta{ display:flex; flex-direction:column; align-items:flex-end; gap:6px; }
.cm-room-on{ display:inline-flex; align-items:center; gap:5px; font:800 11.5px 'Cairo',sans-serif; color:#16a34a; font-style:normal; white-space:nowrap; }
.cm-room-on::before{ content:""; width:7px; height:7px; border-radius:50%; background:#22c55e; }
.cm-room-new{ width:10px; height:10px; border-radius:50%; background:var(--coral); box-shadow:0 0 0 3px color-mix(in srgb, var(--coral) 25%, transparent); font-style:normal; }
.cm-room-new.is-n{ width:auto; height:20px; min-width:20px; padding:0 6px; border-radius:999px; box-shadow:none; color:#fff; font:900 11px/20px 'Cairo',sans-serif; text-align:center; }
.cm-draft{ color:var(--coral); font-weight:800; }
.cm-rules-link{ margin:6px 20px 16px; align-self:flex-start; color:var(--muted); font:700 13px 'Tajawal',sans-serif; text-decoration:none; border-bottom:1px dashed currentColor; }
.cm-rules-link:hover{ color:var(--teal); }

/* ── the room ────────────────────────────────────────────────────────────── */
.cm-chat{ position:relative; display:flex; flex-direction:column; min-width:0; min-height:0; background:var(--bg);
  background-image:radial-gradient(color-mix(in srgb, var(--ink) 6%, transparent) 1px, transparent 1.2px); background-size:22px 22px; }
.cm-empty{ margin:auto; text-align:center; padding:30px; color:var(--muted); max-width:380px; }
.cm-empty-art{ width:84px; height:84px; margin:0 auto 16px; border-radius:26px; display:flex; align-items:center; justify-content:center; background:var(--teal-soft); color:var(--teal); }
.cm-empty h2{ margin:0 0 6px; font:900 21px 'Cairo',sans-serif; color:var(--ink); }
.cm-empty p{ margin:0; font-size:15px; }
.cm-chat.is-open .cm-empty{ display:none; }
.cm-head{ position:relative; display:flex; align-items:center; gap:12px; min-height:var(--cm-head-h); padding:10px 18px; background:color-mix(in srgb, var(--card) 92%, transparent); backdrop-filter:blur(10px); border-bottom:1px solid var(--line); z-index:7; }
.cm-head[hidden]{ display:none; }
.cm-head .cm-mark{ width:44px; height:44px; border-radius:14px; }
.cm-back{ display:none; width:40px; height:40px; border:0; border-radius:50%; background:transparent; color:var(--ink); cursor:pointer; align-items:center; justify-content:center; flex:none; }
.cm-back:hover{ background:color-mix(in srgb, var(--ink) 7%, transparent); }
.cm-head-tx{ min-width:0; flex:1; display:flex; flex-direction:column; }
.cm-head-name{ font:900 17px/1.35 'Cairo',sans-serif; color:var(--ink); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.cm-head-status{ color:var(--muted); font-size:13px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.cm-head-status.is-live{ color:#16a34a; }
.cm-head-status.is-typing{ color:var(--teal); font-weight:800; }
.cm-sound .cm-i-off, .cm-sound.is-off .cm-i-on{ display:none; }
.cm-sound.is-off .cm-i-off{ display:block; }
.cm-sound.is-off{ color:var(--coral); }
html.arw-dark .cm-head-status.is-live{ color:#4ade80; }
.cm-people-btn{ display:inline-flex; align-items:center; gap:8px; padding:5px 6px 5px 12px; border:1px solid var(--line); border-radius:999px; background:var(--card); color:var(--ink); cursor:pointer; font:800 13px 'Cairo',sans-serif; flex:none; }
.cm-people-btn:hover{ border-color:var(--teal); }
.cm-stack{ display:inline-flex; flex-direction:row-reverse; }
.cm-stack .cm-av{ width:28px; height:28px; font-size:12px; border:2px solid var(--card); margin-inline-start:-9px; }
.cm-stack .cm-av:last-child{ margin-inline-start:0; }
.cm-pinned{ display:flex; align-items:center; gap:8px; padding:8px 18px; background:color-mix(in srgb, var(--gold) 14%, var(--card)); border-bottom:1px solid var(--line); color:var(--ink); font-size:13.5px; z-index:2; }
.cm-pinned[hidden]{ display:none; }
.cm-pinned svg{ color:#c47f0c; flex:none; }
.cm-pinned-tx{ flex:1; min-width:0; text-align:start; border:0; background:none; color:inherit; font:inherit; cursor:pointer; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; padding:2px 0; }
.cm-pinned-tx b{ font-family:'Cairo',sans-serif; margin-inline-end:6px; }
.cm-pinned-x{ border:0; background:none; color:var(--muted); font-size:20px; line-height:1; cursor:pointer; padding:0 4px; }
.cm-scroll{ flex:1; min-height:0; overflow-y:auto; overflow-x:hidden; overscroll-behavior:contain; padding:14px 18px 8px; scrollbar-width:thin; outline:none; }
.cm-more-wrap{ display:flex; justify-content:center; }
.cm-more{ margin:4px auto 10px; padding:6px 16px; border:1px solid var(--line); border-radius:999px; background:var(--card); color:var(--muted); font:800 12.5px 'Cairo',sans-serif; cursor:pointer; }
.cm-more:hover{ color:var(--teal); border-color:var(--teal); }
.cm-list{ display:flex; flex-direction:column; gap:2px; }

/* a day's line */
.cm-day{ align-self:center; margin:14px 0 8px; padding:4px 14px; border-radius:999px; background:color-mix(in srgb, var(--card) 85%, transparent); border:1px solid var(--line); color:var(--muted); font:800 12px 'Cairo',sans-serif; backdrop-filter:blur(6px); }
.cm-sys{ align-self:center; margin:8px 0; color:var(--muted); font-size:12.5px; }

/* a message */
.cm-msg{ position:relative; display:grid; grid-template-columns:38px minmax(0,auto); gap:10px; align-items:end; max-width:min(78%, 640px); margin-top:8px; align-self:flex-start; }
.cm-msg.is-cont{ margin-top:7px; }
.cm-msg.is-cont .cm-av{ visibility:hidden; }
/* the picture by the last of a run, where the tail is (Messenger's); a browser without :has keeps it by the first */
.cm-msg:has(+ .cm-msg.is-cont) > .cm-av{ visibility:hidden; }
.cm-msg.is-cont:not(:has(+ .cm-msg.is-cont)) > .cm-av{ visibility:visible; }
.cm-msg.is-mine{ align-self:flex-end; grid-template-columns:minmax(0,auto); }
.cm-msg.is-mine > .cm-av{ display:none; }
.cm-av{ width:38px; height:38px; border-radius:50%; display:flex; align-items:center; justify-content:center; background:var(--c, var(--teal)); color:#fff; font:900 15px 'Cairo',sans-serif; overflow:hidden; flex:none; }
.cm-av img{ width:100%; height:100%; object-fit:cover; display:block; }
.cm-av.is-official{ background:#0f5f5e; }
.cm-bwrap{ min-width:0; display:flex; flex-direction:column; align-items:flex-start; }
.cm-msg.is-mine .cm-bwrap{ align-items:flex-end; }
.cm-bubble{ position:relative; min-width:52px; max-width:100%; padding:6px 10px 5px; border-radius:var(--cm-r); background:var(--cm-bubble); color:var(--ink); box-shadow:0 1px 1px rgba(0,0,0,.08), 0 2px 10px -6px rgba(0,0,0,.18); border:1px solid transparent; }
.cm-msg.is-mine .cm-bubble{ background:var(--cm-mine); color:var(--cm-mine-ink); border-color:transparent; }
/* each message of a run stands on its own: round all round, a clear space between them (owner 2026-10-15: «لازم يكون في فاصل بين كل رسالة ورسالة») */
.cm-msg.is-gold:not(.is-mine) .cm-bubble{ background:color-mix(in srgb, #ffd25a 15%, var(--card)); }
/* the tail (owner 2026-10-15: «السهم ال بيكون جاي من الجنب … من تحت … من اخر رسالة»): from the bottom corner of the
   last message of a run, toward its side */
.cm-msg:not(:has(+ .cm-msg.is-cont)):not(.is-big):not(.is-sticker) .cm-bubble{ border-end-start-radius:0; }
.cm-msg.is-mine:not(:has(+ .cm-msg.is-cont)):not(.is-big):not(.is-sticker) .cm-bubble{ border-end-start-radius:var(--cm-r); border-end-end-radius:0; }
.cm-msg:not(:has(+ .cm-msg.is-cont)):not(.is-big):not(.is-sticker) .cm-bubble::before{ content:""; position:absolute; bottom:-1px; inset-inline-start:-9px; width:10px; height:13px; background:inherit; -webkit-mask:var(--cm-tail-r) 0 0/100% 100% no-repeat; mask:var(--cm-tail-r) 0 0/100% 100% no-repeat; pointer-events:none; }
.cm-msg.is-mine:not(:has(+ .cm-msg.is-cont)):not(.is-big):not(.is-sticker) .cm-bubble::before{ inset-inline-start:auto; inset-inline-end:-9px; -webkit-mask-image:var(--cm-tail-l); mask-image:var(--cm-tail-l); }
html[dir="ltr"] .cm-msg:not(:has(+ .cm-msg.is-cont)):not(.is-big):not(.is-sticker) .cm-bubble::before{ -webkit-mask-image:var(--cm-tail-l); mask-image:var(--cm-tail-l); }
html[dir="ltr"] .cm-msg.is-mine:not(:has(+ .cm-msg.is-cont)):not(.is-big):not(.is-sticker) .cm-bubble::before{ -webkit-mask-image:var(--cm-tail-r); mask-image:var(--cm-tail-r); }
/* a new one slides in from its side; mine rises from the box */
.cm-msg.is-new > .cm-bwrap{ animation:cm-msg-in .42s cubic-bezier(.3,1.32,.5,1); transform-origin:0% 100%; }
.cm-msg.is-mine.is-new > .cm-bwrap{ animation-name:cm-mine-in; transform-origin:100% 100%; }
html[dir="ltr"] .cm-msg.is-new > .cm-bwrap{ transform-origin:100% 100%; }
html[dir="ltr"] .cm-msg.is-mine.is-new > .cm-bwrap{ transform-origin:0% 100%; }
.cm-msg.is-new > .cm-av{ animation:cm-fade .3s ease; }
@keyframes cm-msg-in{ from{ opacity:0; transform:translateY(10px) scale(.9); } }
@keyframes cm-mine-in{ from{ opacity:0; transform:translateY(22px) scale(.88); } }
.cm-msg.mentions-me .cm-bubble{ box-shadow:0 0 0 2px color-mix(in srgb, var(--gold) 70%, transparent), 0 4px 14px -10px rgba(0,0,0,.2); }
.cm-msg.is-pending .cm-bubble{ opacity:.82; }
.cm-msg.is-failed{ cursor:pointer; }
.cm-msg.is-failed .cm-bubble{ box-shadow:0 0 0 2px var(--coral); }
.cm-msg.is-failed .cm-tick{ color:#fff; }
.cm-msg:not(.is-mine).is-failed .cm-tick, .cm-msg.is-sticker.is-failed .cm-tick, .cm-msg.is-big.is-failed .cm-tick{ color:var(--coral); }
.cm-msg.is-failed .cm-meta::after{ content:"لم ترسل، اضغط لإعادة الإرسال"; font-weight:800; }
.cm-tick{ display:inline-flex; align-items:center; }
.cm-tick svg{ display:block; }
.cm-edited{ font-style:italic; opacity:.85; }
.cm-unread{ align-self:stretch; display:flex; align-items:center; gap:10px; margin:14px 0 6px; color:var(--coral); font:900 12px 'Cairo',sans-serif; }
.cm-unread::before, .cm-unread::after{ content:""; flex:1; height:1px; background:color-mix(in srgb, var(--coral) 40%, transparent); }
.cm-msg.is-flash .cm-bubble{ animation:cm-flash 1.4s ease; }
@keyframes cm-flash{ 0%,30%{ box-shadow:0 0 0 4px color-mix(in srgb, var(--gold) 70%, transparent); } 100%{ box-shadow:0 1px 2px rgba(0,0,0,.06); } }
.cm-name{ display:flex; align-items:center; gap:4px; margin-bottom:2px; font:900 13px/1.5 'Cairo',sans-serif; color:hsl(var(--nh, 177) 55% 38%); }
html.arw-dark .cm-name{ color:hsl(var(--nh, 177) 65% 66%); }
.cm-msg.is-gold .cm-name{ color:#b5780a; }
html.arw-dark .cm-msg.is-gold .cm-name{ color:#f2bd4b; }
.cm-name svg{ width:15px; height:15px; flex:none; }
.cm-text{ margin:0; font-size:15px; line-height:1.65; white-space:pre-wrap; overflow-wrap:anywhere; unicode-bidi:plaintext; }
.cm-text a{ color:inherit; text-decoration:underline; text-underline-offset:3px; }
.cm-msg:not(.is-mine) .cm-text a{ color:var(--teal); }
.cm-text .cm-mention{ font-weight:800; color:var(--teal); }
.cm-msg.is-mine .cm-text .cm-mention{ color:#fff; text-decoration:underline; text-decoration-thickness:2px; }
.cm-big{ font-size:38px; line-height:1.3; }
.cm-msg.is-big .cm-bubble{ background:transparent !important; box-shadow:none !important; border-color:transparent !important; padding:0 4px; }
.cm-msg.is-big .cm-meta{ color:var(--muted) !important; }
.cm-meta{ display:flex; justify-content:flex-end; align-items:center; gap:4px; margin-top:1px; font-size:11px; color:var(--muted); line-height:1.4; font-variant-numeric:tabular-nums; }
/* WhatsApp's shape (owner 2026-10-15: «بالشكل زي بتاع واتساب»): small rounded corners, a snug bubble, and on a message of
   words the time at the end of its last line when it fits (the line keeps it room), else under it */
.cm-msg.is-text .cm-bubble{ padding-bottom:6px; }
.cm-msg.is-text .cm-meta{ position:absolute; bottom:3px; inset-inline-end:9px; margin:0; }
.cm-msg.is-text .cm-text::after{ content:""; display:inline-block; width:var(--cm-mw, 50px); height:1px; }
.cm-msg.is-text.is-mine{ --cm-mw:68px; }
.cm-msg.is-text.is-edited{ --cm-mw:88px; }
.cm-msg.is-text.is-mine.is-edited{ --cm-mw:106px; }
.cm-msg.is-text.is-failed .cm-meta{ position:static; margin-top:1px; }
.cm-msg.is-text.is-failed .cm-text::after{ display:none; }
.cm-msg.is-mine .cm-meta{ color:rgba(255,255,255,.78); }
.cm-deleted{ display:flex; align-items:center; gap:6px; font-style:italic; color:var(--muted); font-size:14px; }
.cm-deleted svg{ flex:none; opacity:.8; }
.cm-msg.is-mine .cm-deleted{ color:rgba(255,255,255,.8); }

/* a quote of what it answers */
/* an answer, as Messenger shows it (owner 2026-10-15: «من غير البرتاح الخضرا … زي ماسنجر»): «↩ رد على فلان», then the
   message it answers as a faded bubble, the answer sitting on its lower edge */
.cm-reply-cap{ display:flex; align-items:center; gap:4px; margin:0 8px 3px; color:var(--muted); font:700 12px/1.4 'Cairo',sans-serif; max-width:100%; }
.cm-reply-cap svg{ width:12px; height:12px; flex:none; }
.cm-quote{ position:relative; display:block; max-width:min(100%, 420px); min-width:72px; margin:0 0 -10px; padding:7px 11px 16px; border:0; border-radius:var(--cm-r); background:color-mix(in srgb, var(--ink) 7%, var(--bg)); color:var(--muted); text-align:start; font:inherit; font-size:13.5px; line-height:1.55; cursor:pointer; transition:background .15s ease, transform .15s ease; }
html.arw-dark .cm-quote{ background:color-mix(in srgb, #fff 9%, var(--bg)); }
.cm-quote:hover{ background:color-mix(in srgb, var(--ink) 11%, var(--bg)); }
.cm-quote:active{ transform:scale(.98); }
.cm-quote span{ display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; overflow-wrap:anywhere; }
.cm-msg.has-quote .cm-bubble{ z-index:1; }

/* a spoiler */
.cm-spoiler{ position:relative; }
.cm-spoiler > :not(.cm-spoiler-cover){ filter:blur(9px); user-select:none; pointer-events:none; }
.cm-spoiler-cover{ position:absolute; inset:-2px; z-index:2; display:flex; align-items:center; justify-content:center; gap:6px; border:0; border-radius:12px; background:color-mix(in srgb, var(--ink) 55%, transparent); color:#fff; font:900 13px 'Cairo',sans-serif; cursor:pointer; backdrop-filter:blur(2px); }
.cm-spoiler.is-shown > *{ filter:none; user-select:auto; pointer-events:auto; }
.cm-spoiler.is-shown .cm-spoiler-cover{ display:none; }
.cm-spoil-tag{ display:inline-flex; align-items:center; gap:4px; margin-bottom:4px; padding:1px 8px; border-radius:999px; background:color-mix(in srgb, var(--coral) 16%, transparent); color:var(--coral); font:900 11px 'Cairo',sans-serif; }
.cm-msg.is-mine .cm-spoil-tag{ background:rgba(255,255,255,.2); color:#fff; }

/* attachments */
.cm-img{ display:block; margin:2px -9px 4px; border-radius:14px; overflow:hidden; cursor:zoom-in; background:color-mix(in srgb, var(--ink) 8%, transparent); max-width:340px; }
.cm-img img{ display:block; width:100%; height:auto; max-height:420px; object-fit:cover; }
.cm-msg.is-media .cm-bubble{ padding-top:6px; }
.cm-video{ display:block; margin:2px -9px 4px; border-radius:14px; max-width:340px; width:calc(100% + 18px); background:#000; }
.cm-file{ display:flex; align-items:center; gap:10px; min-width:220px; margin:4px 0; padding:8px 10px; border-radius:12px; background:color-mix(in srgb, var(--ink) 6%, transparent); color:inherit; text-decoration:none; }
.cm-msg.is-mine .cm-file{ background:rgba(255,255,255,.15); }
.cm-file-ic{ width:40px; height:40px; border-radius:11px; display:flex; align-items:center; justify-content:center; background:var(--fc, var(--teal)); color:#fff; font:900 10.5px 'Cairo',sans-serif; flex:none; }
.cm-file-tx{ min-width:0; display:flex; flex-direction:column; }
.cm-file-tx b{ unicode-bidi:plaintext; font-size:14px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; max-width:220px; }
.cm-file-tx small{ opacity:.75; font-size:12px; }
.cm-voice{ display:flex; align-items:center; gap:10px; min-width:230px; padding:4px 0; }
.cm-play{ width:38px; height:38px; border-radius:50%; border:0; background:var(--teal); color:#fff; display:flex; align-items:center; justify-content:center; cursor:pointer; flex:none; }
.cm-msg.is-mine .cm-play{ background:#fff; color:var(--cm-mine); }
.cm-wave{ flex:1; height:32px; display:flex; align-items:center; gap:2px; cursor:pointer; direction:rtl; }
.cm-wave i{ flex:1; min-width:3px; max-width:5px; border-radius:3px; background:color-mix(in srgb, currentColor 32%, transparent); }
.cm-wave i.is-past{ background:currentColor; }
.cm-msg:not(.is-mine) .cm-wave{ color:var(--teal); }
.cm-vtime{ font-size:12px; min-width:34px; text-align:center; font-variant-numeric:tabular-nums; opacity:.85; }
.cm-speed{ border:0; border-radius:999px; padding:1px 7px; background:color-mix(in srgb, currentColor 14%, transparent); color:inherit; font:800 11px 'Cairo',sans-serif; cursor:pointer; }
.cm-progress{ height:4px; border-radius:4px; background:color-mix(in srgb, currentColor 18%, transparent); overflow:hidden; margin:6px 0 2px; }
.cm-progress i{ display:block; height:100%; width:0; background:currentColor; transition:width .2s ease; }

/* stickers and GIFs in the room */
.cm-msg.is-sticker .cm-bubble{ background:transparent !important; box-shadow:none !important; border-color:transparent !important; padding:0 2px; }
.cm-msg.is-sticker .cm-meta{ color:var(--muted) !important; }
.cm-stk{ position:relative; display:flex; align-items:center; justify-content:center; }
.cm-stk-noto{ width:132px; height:132px; }
.cm-stk-noto .cm-stk-ch{ font-size:96px; line-height:1; transition:opacity .2s ease; }
.cm-stk-noto img{ position:absolute; inset:0; width:100%; height:100%; object-fit:contain; opacity:0; transition:opacity .2s ease; }
.cm-stk-noto.is-ready img{ opacity:1; }
.cm-stk-noto.is-ready .cm-stk-ch{ opacity:0; }
.cm-stk-arw{ flex-direction:column; gap:2px; min-width:136px; max-width:180px; padding:12px 14px; border-radius:20px; border:4px solid #fff; background:linear-gradient(-140deg, hsl(var(--sh) 78% 56%), hsl(calc(var(--sh) + 28) 80% 42%)); color:#fff; text-align:center; font:900 19px/1.3 'Cairo',sans-serif; text-shadow:0 2px 0 rgba(0,0,0,.22); box-shadow:0 10px 22px -12px rgba(0,0,0,.5); transform:rotate(3deg); }
.cm-stk-arw.is-r{ transform:rotate(-3deg); }
.cm-stk-arw b{ font:inherit; }
.cm-stk-arw .cm-stk-e{ font-size:34px; line-height:1.1; text-shadow:none; }
html.arw-dark .cm-stk-arw{ border-color:#232831; }
.cm-msg.is-sticker .cm-stk-arw{ animation:cm-stk-in .35s cubic-bezier(.34,1.56,.64,1); }
@keyframes cm-stk-in{ from{ transform:scale(.6) rotate(8deg); opacity:0; } }
.cm-gif{ display:block; margin:2px -9px 4px; border-radius:14px; width:calc(100% + 18px); max-width:300px; min-width:160px; max-height:340px; object-fit:cover; background:color-mix(in srgb, var(--ink) 8%, transparent); cursor:pointer; }

/* reactions */
.cm-reacts{ display:flex; flex-wrap:wrap; gap:4px; margin-top:-6px; z-index:1; padding-inline:8px; }
.cm-reacts button{ display:inline-flex; align-items:center; gap:3px; padding:1px 8px; border:1px solid var(--line); border-radius:999px; background:var(--card); color:var(--ink); font:800 12px 'Cairo',sans-serif; cursor:pointer; box-shadow:0 2px 6px -3px rgba(0,0,0,.25); transition:transform .15s ease; line-height:1.6; }
.cm-reacts button:hover{ transform:scale(1.08); }
.cm-reacts button.is-mine{ border-color:var(--teal); background:var(--teal-soft); }
.cm-reacts button span{ font-size:14px; }
.cm-reacts button.is-pop{ animation:cm-chip .46s cubic-bezier(.34,1.7,.64,1); }
@keyframes cm-chip{ from{ transform:scale(0); opacity:0; } }

/* the message's own tools (owner 2026-10-15: «زي الماسنجر»). A pointer: ☺ ↩ ⋮ by the message's side, toward the middle */
.cm-tools{ position:absolute; top:50%; inset-inline-start:calc(100% + 4px); display:flex; align-items:center; gap:0; opacity:0; pointer-events:none; transform:translateY(-50%) scale(.85); transition:opacity .16s ease, transform .26s cubic-bezier(.34,1.45,.64,1); z-index:4; white-space:nowrap; }
/* no gap to fall through on the way from the message to them */
.cm-tools::before{ content:""; position:absolute; inset-block:-12px; inset-inline-start:-8px; width:10px; }
.cm-msg.is-mine .cm-tools{ inset-inline-start:auto; inset-inline-end:calc(100% + 4px); flex-direction:row-reverse; }
.cm-msg.is-mine .cm-tools::before{ inset-inline-start:auto; inset-inline-end:-8px; }
@media (hover:hover){ .cm-msg:hover .cm-tools, .cm-msg.is-active .cm-tools, .cm-msg:focus-within .cm-tools{ opacity:1; pointer-events:auto; transform:translateY(-50%) scale(1); } }
.cm-tools button{ width:30px; height:30px; border:0; border-radius:50%; background:transparent; color:var(--muted); display:flex; align-items:center; justify-content:center; cursor:pointer; transition:background .15s ease, color .15s ease, transform .2s cubic-bezier(.34,1.56,.64,1); }
.cm-tools button:hover{ background:color-mix(in srgb, var(--ink) 8%, transparent); color:var(--ink); transform:scale(1.08); }
.cm-tools button:active{ transform:scale(.9); }
.cm-tools svg{ width:17px; height:17px; }

/* the reactions' pill and the options (both a pointer's and a finger's): frosted glass, as Apple's */
.cm-body{ --cm-glass:rgba(255,255,255,.9); --cm-glass-line:rgba(0,0,0,.08); }
html.arw-dark .cm-body{ --cm-glass:rgba(40,44,52,.9); --cm-glass-line:rgba(255,255,255,.08); }
.cm-float{ position:fixed; z-index:1305; animation:cm-float-in .26s cubic-bezier(.34,1.4,.64,1) both; }
.cm-float.is-out{ animation:cm-float-out .16s ease forwards; pointer-events:none; }
@keyframes cm-float-in{ from{ opacity:0; transform:scale(.6); } }
@keyframes cm-float-out{ to{ opacity:0; transform:scale(.85); } }
.cm-rbar{ display:flex; align-items:center; gap:1px; padding:5px 6px; border-radius:999px; background:var(--cm-glass); -webkit-backdrop-filter:blur(22px) saturate(1.7); backdrop-filter:blur(22px) saturate(1.7); box-shadow:0 12px 32px -10px rgba(0,0,0,.38), 0 0 0 .5px var(--cm-glass-line); }
.cm-rbar button{ width:42px; height:42px; flex:none; border:0; border-radius:50%; background:transparent; font-size:27px; line-height:1; padding:0; cursor:pointer; display:flex; align-items:center; justify-content:center; transition:transform .22s cubic-bezier(.34,1.56,.64,1), background .15s ease; animation:cm-rb-in .44s cubic-bezier(.34,1.56,.64,1) both; animation-delay:calc(var(--i, 0) * 26ms + 50ms); }
@media (hover:hover){ .cm-rbar button:hover{ transform:scale(1.3) translateY(-5px); } }
.cm-rbar button:active{ transform:scale(.88); }
.cm-rbar button.is-mine{ background:color-mix(in srgb, var(--teal) 22%, transparent); }
.cm-rbar .cm-rb-plus{ width:36px; height:36px; margin-inline-start:4px; background:color-mix(in srgb, var(--ink) 9%, transparent); color:var(--ink); }
@keyframes cm-rb-in{ from{ opacity:0; transform:scale(.25) translateY(12px); } }
.cm-menu{ min-width:220px; max-width:min(290px, calc(100vw - 24px)); padding:6px; border-radius:16px; background:var(--cm-glass); -webkit-backdrop-filter:blur(24px) saturate(1.7); backdrop-filter:blur(24px) saturate(1.7); box-shadow:0 20px 50px -14px rgba(0,0,0,.42), 0 0 0 .5px var(--cm-glass-line); }
.cm-menu button{ display:flex; width:100%; align-items:center; justify-content:space-between; gap:16px; padding:10px 12px; border:0; border-radius:10px; background:transparent; color:var(--ink); font:700 15px/1.3 'Tajawal',sans-serif; cursor:pointer; text-align:start; transition:background .12s ease; }
.cm-menu button:hover, .cm-menu button:focus-visible{ background:color-mix(in srgb, var(--ink) 8%, transparent); outline:none; }
.cm-menu button.is-danger{ color:#ff3b30; }
.cm-menu-ic{ display:flex; flex:none; opacity:.9; }
.cm-menu-ic svg{ width:19px; height:19px; }
.cm-menu-sep{ display:block; height:1px; margin:5px 8px; background:var(--cm-glass-line); }

/* a finger: the long press. The room blurs, the message lifts, the reactions over it, the options under it */
.cm-focus{ position:fixed; inset:0; z-index:1315; touch-action:none; -webkit-tap-highlight-color:transparent; }
.cm-focus-bg{ position:absolute; inset:0; background:rgba(12,14,18,.3); -webkit-backdrop-filter:blur(16px) saturate(1.25); backdrop-filter:blur(16px) saturate(1.25); opacity:0; transition:opacity .3s ease; }
html.arw-dark .cm-focus-bg{ background:rgba(0,0,0,.55); }
.cm-focus.is-open .cm-focus-bg{ opacity:1; }
.cm-focus.is-closing .cm-focus-bg{ transition-duration:.24s; }
.cm-focus-msg{ position:fixed !important; z-index:1; margin:0 !important; max-width:none !important; pointer-events:none; transition:transform .44s cubic-bezier(.32,1.28,.5,1); will-change:transform; }
.cm-focus.is-closing .cm-focus-msg{ transition:transform .3s cubic-bezier(.3,.7,.3,1); }
.cm-focus-msg > .cm-av{ visibility:hidden; }
.cm-focus-msg .cm-bubble{ box-shadow:0 14px 36px -12px rgba(0,0,0,.45); }
.cm-focus-msg.is-clipped .cm-bwrap{ overflow:hidden; -webkit-mask-image:linear-gradient(#000 78%, transparent); mask-image:linear-gradient(#000 78%, transparent); }
.cm-focus .cm-rbar, .cm-focus .cm-menu{ position:fixed; z-index:2; opacity:0; transform:scale(.4); transition:opacity .18s ease, transform .4s cubic-bezier(.34,1.4,.64,1); }
.cm-focus .cm-menu{ transition-delay:.03s; }
.cm-focus.is-open .cm-rbar, .cm-focus.is-open .cm-menu{ opacity:1; transform:none; }
.cm-focus.is-closing .cm-rbar, .cm-focus.is-closing .cm-menu{ transition:opacity .16s ease, transform .2s ease; transition-delay:0s; }
/* iOS's own menu: rows over hairlines, the dangerous ones after a thicker line */
.cm-focus .cm-menu{ width:250px; padding:0; border-radius:14px; overflow:hidden; }
.cm-focus .cm-menu button{ padding:13px 16px; border-radius:0; font-size:16px; }
.cm-focus .cm-menu button + button{ box-shadow:inset 0 .5px 0 var(--cm-glass-line); }
.cm-focus .cm-menu button:active{ background:color-mix(in srgb, var(--ink) 10%, transparent); }
.cm-focus .cm-menu-sep{ height:7px; margin:0; background:color-mix(in srgb, var(--ink) 8%, transparent); }
.cm-focus .cm-rbar button{ width:44px; height:44px; font-size:29px; }

/* a finger: held, it sinks a little; swiped toward the middle, it answers (the arrow fills when it will) */
@media (hover:none){
  .cm-bubble{ -webkit-touch-callout:none; -webkit-user-select:none; user-select:none; touch-action:pan-y; }
  .cm-msg > .cm-bwrap, .cm-msg > .cm-av{ transform:translateX(var(--sx, 0px)); transition:transform .42s cubic-bezier(.3,1.35,.5,1); }
  .cm-msg.is-swiping > .cm-bwrap, .cm-msg.is-swiping > .cm-av{ transition:none; }
  .cm-msg.is-pressing > .cm-bwrap{ transform:scale(.95); transition:transform .5s cubic-bezier(.2,.8,.2,1); }
  /* the answer's arrow under the message, not over it */
  .cm-msg{ isolation:isolate; }
  .cm-msg .cm-swipe-ic{ z-index:-1; }
}
.cm-msg .cm-swipe-ic{ position:absolute; inset-inline-start:4px; top:50%; width:32px; height:32px; margin-top:-16px; border-radius:50%; display:flex; align-items:center; justify-content:center; background:color-mix(in srgb, var(--ink) 9%, transparent); color:var(--ink); opacity:0; transform:scale(.35); pointer-events:none; transition:opacity .2s ease, transform .3s ease, background .2s ease, color .2s ease; }
.cm-msg.is-swiping .cm-swipe-ic{ transition:background .2s ease, color .2s ease; }
.cm-msg .cm-swipe-ic svg{ width:17px; height:17px; }
.cm-msg .cm-swipe-ic.is-armed{ background:var(--teal); color:#fff; animation:cm-armed .34s cubic-bezier(.34,1.56,.64,1); }
@keyframes cm-armed{ 40%{ scale:1.25; } }
.cm-msg.is-mine .cm-swipe-ic{ inset-inline-start:auto; inset-inline-end:4px; }

/* the jump down, the typing line */
.cm-jump{ position:absolute; inset-inline-start:18px; bottom:92px; width:44px; height:44px; border-radius:50%; border:1px solid var(--line); background:var(--card); color:var(--ink); display:flex; align-items:center; justify-content:center; cursor:pointer; box-shadow:0 8px 20px -8px rgba(0,0,0,.35); z-index:5; }
.cm-jump[hidden]{ display:none; }
.cm-jump-n{ position:absolute; top:-6px; inset-inline-end:-4px; min-width:20px; height:20px; padding:0 5px; border-radius:999px; background:var(--coral); color:#fff; font:900 11px/20px 'Cairo',sans-serif; }
/* «فلان يكتب…»: their picture and a small bubble with the moving dots, over the box */
.cm-typing{ height:0; padding:0 18px; display:flex; align-items:center; gap:6px; overflow:visible; position:relative; z-index:4; }
.cm-typing.is-on{ height:34px; }
.cm-typing-avs{ display:inline-flex; flex-direction:row-reverse; }
.cm-typing-avs .cm-av{ width:24px; height:24px; font-size:11px; border:2px solid var(--bg); margin-inline-start:-8px; }
.cm-typing-avs .cm-av:last-child{ margin-inline-start:0; }
.cm-typing-bub{ display:inline-flex; align-items:center; gap:7px; max-width:calc(100% - 40px); padding:4px 12px; border-radius:999px; background:var(--card); border:1px solid var(--line); box-shadow:0 4px 12px -8px rgba(0,0,0,.3); animation:cm-pop-in .18s ease; }
@keyframes cm-pop-in{ from{ transform:scale(.85); opacity:0; } }
.cm-typing-tx{ color:var(--teal); font:800 12.5px 'Cairo',sans-serif; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.cm-typing i{ display:inline-flex; gap:3px; flex:none; }
.cm-typing i b{ width:5px; height:5px; border-radius:50%; background:var(--teal); animation:cm-dot 1.2s infinite ease-in-out; }
.cm-typing i b:nth-child(2){ animation-delay:.15s; } .cm-typing i b:nth-child(3){ animation-delay:.3s; }
@keyframes cm-dot{ 0%,60%,100%{ transform:translateY(0); opacity:.5; } 30%{ transform:translateY(-4px); opacity:1; } }

/* ── writing ─────────────────────────────────────────────────────────────── */
.cm-compose{ position:relative; padding:8px 14px 14px; background:color-mix(in srgb, var(--card) 94%, transparent); border-top:1px solid var(--line); backdrop-filter:blur(10px); z-index:3; }
.cm-compose[hidden]{ display:none; }
.cm-attached{ display:flex; align-items:center; gap:10px; margin:0 4px 8px; padding:8px 12px; border-radius:12px; background:var(--bg); border-inline-start:3px solid var(--teal); }
/* answering or editing (Messenger's): an icon, «الرد على فلان» and what it says, × to drop it; no side stripe */
.cm-replying{ display:flex; align-items:center; gap:10px; margin:0 4px 8px; padding:7px 10px 7px 6px; border-radius:16px; background:color-mix(in srgb, var(--ink) 5%, transparent); }
.cm-replying-ic{ width:30px; height:30px; flex:none; display:flex; align-items:center; justify-content:center; border-radius:50%; background:color-mix(in srgb, var(--ink) 8%, transparent); color:var(--ink); }
.cm-replying-ic svg{ width:15px; height:15px; }
.cm-replying.is-edit .cm-replying-ic{ background:color-mix(in srgb, var(--gold) 22%, transparent); color:#a86a06; }
html.arw-dark .cm-replying.is-edit .cm-replying-ic{ color:var(--gold); }
.cm-replying[hidden], .cm-attached[hidden]{ display:none; }
.cm-replying-tx{ flex:1; min-width:0; }
.cm-replying-tx b{ display:block; font:800 13px 'Cairo',sans-serif; color:var(--ink); }
.cm-replying{ animation:cm-rep-in .28s cubic-bezier(.2,.9,.3,1.15); }
@keyframes cm-rep-in{ from{ opacity:0; transform:translateY(10px); } }
/* @: who to mention */
.cm-mention-pop{ position:absolute; bottom:100%; inset-inline:14px; z-index:9; display:flex; flex-direction:column; gap:2px; margin-bottom:6px; padding:6px; border-radius:16px; background:var(--card); border:1px solid var(--line); box-shadow:0 18px 40px -16px rgba(0,0,0,.4); max-width:360px; }
.cm-mention-pop[hidden]{ display:none; }
.cm-mention-row{ display:flex; align-items:center; gap:10px; padding:6px 8px; border:0; border-radius:12px; background:transparent; color:var(--ink); text-align:start; cursor:pointer; font:inherit; }
.cm-mention-row .cm-av{ width:32px; height:32px; font-size:13px; }
.cm-mention-row:hover, .cm-mention-row.is-on{ background:var(--teal-soft); }
.cm-replying-tx span{ display:block; font-size:13px; color:var(--muted); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.cm-replying button, .cm-attached .cm-att-x{ width:28px; height:28px; border:0; border-radius:50%; background:transparent; color:var(--muted); font-size:20px; line-height:1; cursor:pointer; flex:none; }
.cm-attached{ border-inline-start-color:var(--violet); flex-wrap:wrap; }
.cm-att-item{ position:relative; display:flex; align-items:center; gap:8px; max-width:100%; }
.cm-att-item img{ width:54px; height:54px; border-radius:10px; object-fit:cover; display:block; }
.cm-att-item .cm-file-tx b{ max-width:200px; }
.cm-row{ display:flex; align-items:flex-end; gap:6px; }
.cm-ic{ width:42px; height:42px; border:0; border-radius:50%; background:transparent; color:var(--muted); display:flex; align-items:center; justify-content:center; cursor:pointer; flex:none; transition:background .15s ease, color .15s ease; }
.cm-ic:hover, .cm-ic[aria-expanded="true"]{ background:color-mix(in srgb, var(--teal) 12%, transparent); color:var(--teal); }
.cm-spoil[aria-pressed="true"]{ background:color-mix(in srgb, var(--coral) 15%, transparent); color:var(--coral); }
.cm-input{ flex:1; min-width:0; display:flex; border:1px solid var(--line); border-radius:22px; background:var(--bg); transition:border-color .15s ease, box-shadow .15s ease; }
.cm-input:focus-within{ border-color:var(--teal); box-shadow:0 0 0 3px var(--teal-soft); }
.cm-input textarea{ flex:1; min-width:0; resize:none; border:0; outline:none; background:transparent; color:var(--ink); font:500 15.5px/1.6 'Tajawal',sans-serif; padding:9px 16px; max-height:150px; }
.cm-input.is-spoiler{ border-color:var(--coral); }
.cm-send{ width:44px; height:44px; border:0; border-radius:50%; background:var(--teal); color:#fff; display:flex; align-items:center; justify-content:center; cursor:pointer; flex:none; box-shadow:0 6px 16px -8px var(--teal); transition:transform .15s ease, background .15s ease; }
.cm-send:hover{ transform:scale(1.06); }
.cm-send:active{ transform:scale(.94); }
.cm-send .cm-i-send{ display:none; }
.cm-send.is-send .cm-i-send{ display:block; }
.cm-send.is-send .cm-i-mic{ display:none; }
.cm-send:disabled{ opacity:.5; cursor:default; transform:none; }
.cm-rec{ display:flex; align-items:center; gap:10px; padding:2px 4px; }
.cm-rec[hidden]{ display:none; }
.cm-rec-x{ width:42px; height:42px; border:0; border-radius:50%; background:color-mix(in srgb, var(--coral) 12%, transparent); color:var(--coral); display:flex; align-items:center; justify-content:center; cursor:pointer; flex:none; }
.cm-rec-dot{ width:11px; height:11px; border-radius:50%; background:#ef4444; animation:cm-blink 1s steps(2) infinite; flex:none; }
@keyframes cm-blink{ 50%{ opacity:.25; } }
.cm-rec-time{ font:900 15px 'Cairo',sans-serif; color:var(--ink); min-width:42px; font-variant-numeric:tabular-nums; }
.cm-rec-wave{ flex:1; min-width:0; height:36px; color:var(--teal); }
.cm-muted{ padding:10px 14px; border-radius:14px; background:color-mix(in srgb, var(--coral) 10%, var(--card)); color:var(--coral); font-weight:700; font-size:14px; text-align:center; }
.cm-muted[hidden]{ display:none; }
.cm-compose.is-muted .cm-row{ display:none; }

/* not a member yet */
.cm-gate{ position:absolute; inset:var(--cm-head-h) 0 0 0; z-index:6; display:flex; align-items:safe center; justify-content:center; padding:20px; overflow-y:auto; background:color-mix(in srgb, var(--bg) 55%, transparent); backdrop-filter:blur(6px); }
.cm-gate[hidden]{ display:none; }
.cm-gate-card{ max-width:420px; width:100%; padding:28px 26px; border-radius:22px; background:var(--card); border:1px solid var(--line); text-align:center; box-shadow:0 24px 50px -24px rgba(0,0,0,.35); }
.cm-gate-ic{ width:62px; height:62px; margin:0 auto 14px; border-radius:20px; display:flex; align-items:center; justify-content:center; background:var(--teal-soft); color:var(--teal); }
.cm-gate-card h2{ margin:0 0 8px; font:900 22px 'Cairo',sans-serif; color:var(--ink); }
.cm-gate-card p{ margin:0 0 14px; color:var(--muted); font-size:15px; line-height:1.8; }
.cm-gate-card ul{ list-style:none; margin:0 0 18px; padding:0; display:flex; flex-direction:column; gap:7px; text-align:start; }
.cm-gate-card li{ display:flex; align-items:center; gap:9px; font-weight:700; font-size:14.5px; color:var(--ink); }
.cm-gate-card li::before{ content:"✓"; width:22px; height:22px; border-radius:50%; background:var(--teal-soft); color:var(--teal); display:flex; align-items:center; justify-content:center; font-size:12px; font-weight:900; flex:none; }
.cm-gate-btns{ display:flex; flex-direction:column; gap:8px; }
.cm-btn{ display:inline-flex; align-items:center; justify-content:center; height:48px; padding:0 22px; border:0; border-radius:14px; background:var(--teal); color:#fff; font:800 15.5px 'Cairo',sans-serif; text-decoration:none; cursor:pointer; transition:transform .15s ease, box-shadow .15s ease; box-shadow:0 10px 22px -12px var(--teal); }
.cm-btn:hover{ transform:translateY(-1px); }
.cm-btn-ghost{ background:transparent; color:var(--ink); border:1px solid var(--line); box-shadow:none; }

/* ── floating pieces ─────────────────────────────────────────────────────── */
.cm-pop{ position:fixed; z-index:1300; background:var(--card); border:1px solid var(--line); border-radius:18px; box-shadow:0 22px 50px -18px rgba(0,0,0,.4); }
.cm-pop[hidden]{ display:none; }
/* the picker: emoji, stickers, GIFs (a floating card on a computer, the keyboard's place on a phone) */
.cm-emoji-pop{ width:min(392px, calc(100vw - 20px)); height:min(440px, calc(100dvh - 140px)); display:flex; flex-direction:column; overflow:hidden; }
.cm-pk-tabs{ display:flex; gap:4px; padding:8px 8px 0; flex:none; }
.cm-pk-tabs button{ flex:1; height:36px; border:0; border-radius:12px 12px 0 0; background:transparent; color:var(--muted); font:800 14px 'Cairo',sans-serif; cursor:pointer; position:relative; transition:color .15s ease, background .15s ease; }
.cm-pk-tabs button:hover{ color:var(--ink); }
.cm-pk-tabs button.is-on{ color:var(--teal); background:color-mix(in srgb, var(--teal) 8%, transparent); }
.cm-pk-tabs button.is-on::after{ content:""; position:absolute; inset-inline:22%; bottom:0; height:3px; border-radius:3px 3px 0 0; background:var(--teal); }
.cm-emoji-pop.is-react .cm-pk-tabs{ display:none; }
.cm-pk-pane{ flex:1; min-height:0; display:flex; flex-direction:column; border-top:1px solid var(--line); }
.cm-pk-pane[hidden]{ display:none !important; }
.cm-pk-search{ display:flex; align-items:center; gap:6px; padding:8px 8px 4px; flex:none; }
.cm-pk-search input{ flex:1; min-width:0; height:38px; padding:0 14px; border:1px solid var(--line); border-radius:999px; background:var(--bg); color:var(--ink); font:500 15px 'Tajawal',sans-serif; outline:none; -webkit-appearance:none; appearance:none; }
.cm-pk-search input:focus{ border-color:var(--teal); box-shadow:0 0 0 3px var(--teal-soft); }
.cm-tone{ flex:none; width:38px; height:38px; border:1px solid var(--line); border-radius:50%; background:var(--bg); font-size:20px; line-height:1; cursor:pointer; }
.cm-emoji-tabs{ display:flex; gap:2px; padding:2px 6px 6px; border-bottom:1px solid var(--line); overflow-x:auto; scrollbar-width:none; flex:none; }
.cm-emoji-tabs::-webkit-scrollbar{ display:none; }
.cm-emoji-tabs button{ flex:1 0 34px; height:34px; border:0; border-radius:10px; background:transparent; font-size:19px; cursor:pointer; filter:grayscale(.7); opacity:.7; transition:opacity .15s ease, filter .15s ease, background .15s ease; }
.cm-emoji-tabs button.is-on{ background:var(--teal-soft); filter:none; opacity:1; }
.cm-emoji-grid{ position:relative; flex:1; min-height:0; overflow-y:auto; overscroll-behavior:contain; padding:2px 8px 10px; scrollbar-width:thin; }
.cm-emoji-grid section{ content-visibility:auto; contain-intrinsic-size:auto 300px; }
.cm-emoji-grid.is-search section[data-cat], .cm-emoji-grid.is-search .cm-pk-wait{ display:none; }
.cm-emoji-grid section > b{ display:block; position:sticky; top:0; z-index:1; padding:8px 4px 4px; background:var(--card); color:var(--muted); font:800 12px 'Cairo',sans-serif; }
.cm-eg{ display:grid; grid-template-columns:repeat(auto-fill, minmax(40px, 1fr)); gap:1px; }
.cm-eg button{ aspect-ratio:1; border:0; border-radius:10px; background:transparent; font-size:25px; line-height:1; cursor:pointer; padding:0; font-family:"Apple Color Emoji","Segoe UI Emoji","Noto Color Emoji",sans-serif; transition:transform .1s ease, background .1s ease; }
.cm-eg button:hover{ background:color-mix(in srgb, var(--ink) 7%, transparent); transform:scale(1.18); }
.cm-eg button:active{ transform:scale(.9); }
.cm-pk-wait{ display:flex; justify-content:center; padding:22px; color:var(--muted); font-size:13px; text-align:center; }
.cm-pk-wait span{ width:26px; height:26px; border-radius:50%; border:3px solid var(--line); border-top-color:var(--teal); animation:cm-spin .8s linear infinite; }
@keyframes cm-spin{ to{ transform:rotate(-360deg); } }
/* stickers */
.cm-stk-tabs{ display:flex; gap:6px; padding:8px 8px 6px; flex:none; }
.cm-stk-tabs button{ height:32px; padding:0 14px; border:1px solid var(--line); border-radius:999px; background:var(--card); color:var(--ink); font:800 13px 'Cairo',sans-serif; cursor:pointer; }
.cm-stk-tabs button.is-on{ background:var(--teal); border-color:var(--teal); color:#fff; }
.cm-stk-grid{ flex:1; min-height:0; overflow-y:auto; overscroll-behavior:contain; padding:0 8px 10px; scrollbar-width:thin; }
.cm-stk-title{ display:block; padding:8px 4px 6px; color:var(--muted); font:800 12px 'Cairo',sans-serif; }
.cm-stk-list{ display:grid; grid-template-columns:repeat(auto-fill, minmax(104px, 1fr)); gap:6px; }
.cm-stk-list.is-noto{ grid-template-columns:repeat(auto-fill, minmax(58px, 1fr)); gap:2px; }
.cm-stk-pick{ display:flex; align-items:center; justify-content:center; min-height:58px; padding:4px; border:0; border-radius:14px; background:transparent; cursor:pointer; transition:transform .12s ease, background .12s ease; overflow:hidden; }
.cm-stk-pick:hover{ background:color-mix(in srgb, var(--ink) 6%, transparent); transform:scale(1.06); }
.cm-stk-pick:active{ transform:scale(.94); }
.cm-stk-pick > .cm-stk-ch{ font-size:38px; line-height:1; }
.cm-stk-pick .cm-stk-arw{ width:100%; min-height:70px; font-size:13px; padding:8px 6px; border-width:3px; }
.cm-stk-pick .cm-stk-arw .cm-stk-e{ font-size:22px; }
/* GIFs */
.cm-gif-chips{ display:flex; gap:6px; padding:2px 8px 8px; overflow-x:auto; scrollbar-width:none; flex:none; }
.cm-gif-chips::-webkit-scrollbar{ display:none; }
.cm-gif-chips button{ flex:none; height:30px; padding:0 13px; border:1px solid var(--line); border-radius:999px; background:var(--card); color:var(--ink); font:700 13px 'Tajawal',sans-serif; cursor:pointer; }
.cm-gif-chips button.is-on{ background:var(--teal); border-color:var(--teal); color:#fff; }
.cm-gif-grid{ flex:1; min-height:0; overflow-y:auto; overscroll-behavior:contain; padding:0 8px 8px; columns:2; column-gap:6px; scrollbar-width:thin; }
.cm-gif-pick{ display:block; width:100%; margin:0 0 6px; padding:0; border:0; border-radius:12px; overflow:hidden; background:color-mix(in srgb, var(--ink) 8%, transparent); cursor:pointer; break-inside:avoid; transition:transform .12s ease; }
.cm-gif-pick:hover{ transform:scale(.98); }
.cm-gif-pick video{ display:block; width:100%; height:100%; object-fit:cover; margin:0; border-radius:0; max-width:none; pointer-events:none; }
.cm-gif-note{ column-span:all; margin:18px 8px; color:var(--muted); font-size:14px; line-height:1.8; text-align:center; }
.cm-gif-grid .cm-pk-wait{ column-span:all; }
.cm-gif-by{ flex:none; padding:2px 10px 6px; color:var(--muted); font:700 11px 'Cairo',sans-serif; text-align:center; }
.cm-gif-by:empty{ display:none; }
/* on a phone: under the box, where the keyboard was */
.cm-emoji-pop.is-dock{ position:static; width:auto; height:min(42dvh, 340px); flex:none; border-radius:0; border-inline:0; border-bottom:0; box-shadow:none; animation:cm-dock .2s cubic-bezier(.16,1,.3,1); padding-bottom:env(safe-area-inset-bottom, 0px); }
@keyframes cm-dock{ from{ transform:translateY(24px); opacity:.5; } }
.cm-emoji-pop.is-dock .cm-eg{ grid-template-columns:repeat(auto-fill, minmax(42px, 1fr)); }
.cm-attach-pop{ padding:6px; display:flex; flex-direction:column; min-width:190px; }
.cm-attach-pop button{ display:flex; align-items:center; gap:10px; padding:10px 12px; border:0; border-radius:12px; background:transparent; color:var(--ink); font:700 14.5px 'Tajawal',sans-serif; cursor:pointer; text-align:start; }
.cm-attach-pop button:hover{ background:color-mix(in srgb, var(--ink) 6%, transparent); }
.cm-pop-ic{ width:34px; height:34px; border-radius:50%; display:flex; align-items:center; justify-content:center; background:var(--c); color:#fff; flex:none; }
.cm-people-pop{ width:290px; max-height:380px; overflow-y:auto; padding:12px; }
.cm-pop-title{ display:block; margin:0 6px 8px; font:900 14px 'Cairo',sans-serif; color:var(--ink); }
.cm-person{ display:flex; align-items:center; gap:10px; padding:6px; border-radius:12px; font-weight:700; font-size:14.5px; color:var(--ink); }
.cm-person .cm-av{ width:34px; height:34px; font-size:13px; }
.cm-person svg{ width:15px; height:15px; }
.cm-person::after{ content:""; margin-inline-start:auto; width:8px; height:8px; border-radius:50%; background:#22c55e; flex:none; }
.cm-person-tx{ min-width:0; display:flex; flex-direction:column; line-height:1.35; }
.cm-person-tx b{ display:flex; align-items:center; gap:4px; font:800 14px 'Cairo',sans-serif; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.cm-person-tx small{ color:var(--muted); font-size:12px; direction:rtl; text-align:end; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.cm-person.is-typing small{ color:var(--teal); font-weight:800; direction:ltr; text-align:start; }

@keyframes cm-fade{ from{ opacity:0; } }

/* a picture full size */
.cm-viewer{ position:fixed; inset:0; z-index:1320; display:flex; align-items:center; justify-content:center; background:rgba(8,10,14,.92); padding:56px 16px 16px; cursor:zoom-out; animation:cm-fade .15s ease; }
.cm-viewer[hidden]{ display:none; }
.cm-viewer img{ max-width:100%; max-height:100%; border-radius:12px; object-fit:contain; box-shadow:0 20px 60px rgba(0,0,0,.5); }
.cm-viewer-bar{ position:absolute; top:12px; inset-inline:16px; display:flex; justify-content:space-between; align-items:center; }
.cm-viewer-bar a{ color:#fff; font:800 14px 'Cairo',sans-serif; text-decoration:none; padding:6px 14px; border-radius:999px; background:rgba(255,255,255,.12); }
.cm-viewer-bar button{ width:40px; height:40px; border:0; border-radius:50%; background:rgba(255,255,255,.12); color:#fff; font-size:24px; cursor:pointer; }

/* the rules */
.cm-modal{ position:fixed; inset:0; z-index:1330; display:flex; align-items:center; justify-content:center; padding:16px; background:rgba(0,0,0,.45); animation:cm-fade .15s ease; }
.cm-modal[hidden]{ display:none; }
.cm-modal-card{ width:100%; max-width:480px; max-height:calc(100dvh - 32px); overflow-y:auto; padding:26px 24px 22px; border-radius:22px; background:var(--card); color:var(--ink); box-shadow:0 30px 60px -20px rgba(0,0,0,.5); }
.cm-modal-card h2{ margin:0 0 6px; font:900 22px 'Cairo',sans-serif; }
.cm-modal-card p{ margin:0 0 12px; color:var(--muted); font-size:15px; }
.cm-modal-card ol{ margin:0 0 12px; padding-inline-start:20px; display:flex; flex-direction:column; gap:9px; font-size:15px; line-height:1.75; }
.cm-modal-card .cm-modal-note{ font-size:13px; }
.cm-modal-card .cm-btn{ width:100%; }
.cm-report-opts{ display:flex; flex-direction:column; gap:6px; margin:0 0 14px; }
.cm-report-opts label{ display:flex; align-items:center; gap:10px; padding:10px 12px; border:1px solid var(--line); border-radius:12px; cursor:pointer; font-weight:700; }
.cm-report-opts label:has(input:checked){ border-color:var(--teal); background:var(--teal-soft); }
.cm-modal-btns{ display:flex; gap:8px; }
.cm-modal-btns .cm-btn{ flex:1; }

.cm-toast{ position:fixed; bottom:24px; right:50%; transform:translateX(50%); z-index:1340; padding:10px 18px; border-radius:999px; background:var(--ink); color:var(--bg); font:800 14px 'Cairo',sans-serif; box-shadow:0 12px 30px -10px rgba(0,0,0,.45); animation:cm-fade .2s ease; max-width:calc(100vw - 32px); text-align:center; }
.cm-toast[hidden]{ display:none; }
.cm-conn{ position:absolute; top:calc(var(--cm-head-h) + 8px); right:50%; transform:translateX(50%); z-index:4; padding:5px 14px; border-radius:999px; background:var(--ink); color:var(--bg); font:800 12.5px 'Cairo',sans-serif; box-shadow:0 8px 20px -8px rgba(0,0,0,.4); }

/* a picture or a file dragged over the room */
.cm-chat.is-drop::after{ content:"أفلت الصور أو الملفات هنا لإرسالها"; position:absolute; inset:10px; z-index:20; display:flex; align-items:center; justify-content:center; border:3px dashed var(--teal); border-radius:20px; background:color-mix(in srgb, var(--teal) 12%, color-mix(in srgb, var(--bg) 85%, transparent)); color:var(--teal); font:900 18px 'Cairo',sans-serif; pointer-events:none; }

/* ── a phone: one screen at a time ───────────────────────────────────────── */
@media (max-width:1150px){
  .cm-page{ padding:0; max-width:none; }
  .cm-app{ display:block; height:auto; min-height:0; border:0; border-radius:0; box-shadow:none; background:var(--bg); }
  .cm-side{ border:0; background:var(--bg); display:flex; flex-direction:column; min-height:calc(100dvh - var(--cm-top, 60px)); }
  /* the rooms fill the screen here too (a tall tablet), each no taller than a card should be */
  .cm-rooms{ flex:1; }
  .cm-room{ flex:1 1 auto; max-height:118px; }
  .cm-side-head{ padding:20px 18px 10px; }
  .cm-rooms{ overflow:visible; padding:4px 10px 16px; gap:6px; }
  .cm-room{ background:var(--card); border:1px solid var(--line); padding:11px 12px; }
  .cm-room.is-on::before{ display:none; }
  .cm-chat{ display:none; }
  .cm-app[data-view="room"] .cm-side{ display:none; }
  /* as tall as what the keyboard leaves (assets/community.js keeps --vvh and --vvt) */
  .cm-app[data-view="room"] .cm-chat{ display:flex; position:fixed; inset:auto 0; top:var(--vvt, 0px); z-index:1200; height:var(--vvh, 100dvh); }
  .cm-typing{ padding:0 10px; }
  .cm-stk-noto{ width:116px; height:116px; }
  .cm-stk-noto .cm-stk-ch{ font-size:84px; }
  .cm-gif{ max-width:250px; }
  .cm-sound{ width:36px; height:36px; }
  body.cm-in-room > header{ visibility:hidden; }
  .cm-back{ display:inline-flex; }
  .cm-head{ padding:8px 10px; gap:8px; padding-top:calc(8px + env(safe-area-inset-top, 0px)); }
  .cm-people-btn{ padding:4px 4px 4px 8px; }
  .cm-people-n{ display:none; }
  .cm-scroll{ padding:10px 10px 6px; }
  .cm-msg{ max-width:88%; }
  .cm-av{ width:32px; height:32px; font-size:13px; }
  .cm-msg{ grid-template-columns:32px minmax(0,auto); gap:8px; }
  .cm-compose{ padding:6px 8px calc(8px + env(safe-area-inset-bottom, 0px)); }
  .cm-ic{ width:38px; height:38px; }
  .cm-spoil{ display:none; }
  .cm-compose.is-typing .cm-spoil{ display:flex; }
  .cm-compose.is-typing [data-act="attach"]{ display:none; }
  .cm-input textarea{ font-size:16px; padding:8px 14px; }
  .cm-jump{ bottom:84px; inset-inline-start:12px; }
  .cm-img, .cm-video{ max-width:260px; }
  body.cm-in-room{ overflow:hidden; }
  body.cm-in-room .arw-bottom-nav, body.cm-in-room .mobile-bottom-nav, body.cm-in-room .bottom-nav{ display:none !important; }
}
@media (prefers-reduced-motion: reduce){ .cm-live-dot, .cm-rec-dot, .cm-typing i b, .cm-pk-wait span, .cm-msg.is-sticker .cm-stk-arw, .cm-emoji-pop.is-dock, .cm-typing-bub, .cm-msg.is-new > *, .cm-reacts button, .cm-replying, .cm-rbar button, .cm-float, .cm-swipe-ic{ animation:none !important; } .cm-focus *, .cm-msg > *{ transition-duration:.01s !important; } }

/* the rooms fill the whole list, top to bottom (owner 2026-10-14: «خلي الجروبات تكون بكامل القايمة مش يكون في فراغ فاضي»);
   on a short screen each keeps its size and the list scrolls */
@media (min-width:1151px){
  .cm-rooms{ gap:4px; }
  .cm-room{ flex:1 1 0; min-height:56px; padding-block:6px; }
}
/* a short screen (a laptop at 768px or less): a tighter head and rooms, so all nine show without scrolling */
@media (min-width:1151px) and (max-height:860px){
  .cm-side-head{ padding:14px 18px 8px; }
  .cm-title{ font-size:20px; }
  .cm-sub{ font-size:13px; margin-top:2px; }
  .cm-total{ margin-top:6px; padding:2px 10px; }
  .cm-rooms{ gap:2px; padding-bottom:4px; }
  .cm-room{ min-height:46px; padding-block:4px; grid-template-columns:40px minmax(0,1fr) auto; gap:10px; }
  .cm-room .cm-mark{ width:40px; height:40px; border-radius:13px; font-size:11px; }
  .cm-room-tx b{ font-size:14px; line-height:1.35; }
  .cm-room-last{ font-size:12.5px; }
  .cm-rules-link{ margin:4px 18px 10px; }
}

/* a tablet: the one-screen layout, the rooms' list not wider than reads well */
@media (min-width:601px) and (max-width:1150px){ .cm-side{ max-width:760px; margin:0 auto; } }

/* «العضوية المميزة» (pages/premium.njk): a golden name and the crown in the rooms */
.cm-msg.is-prem .cm-name > span:first-child{ background:linear-gradient(-135deg, #e09a12, #c77c00); -webkit-background-clip:text; background-clip:text; color:transparent; }
html.arw-dark .cm-msg.is-prem .cm-name > span:first-child{ background-image:linear-gradient(-135deg, #ffd25a, #f2a53c); }
.cm-prem{ display:inline-flex; align-items:center; gap:3px; padding:0 7px; border-radius:999px; background:linear-gradient(-135deg, #ffd25a, #e09a12); color:#3b2600 !important; font:900 10.5px/1.7 'Cairo',sans-serif; text-decoration:none; }
.cm-prem svg{ width:10px !important; height:10px !important; }
.cm-msg.is-prem:not(.is-mine) .cm-bubble{ border-color:color-mix(in srgb, #e09a12 30%, transparent); }
/* a room the owner closed for writing (the panel's «الغرف»): a small lock after its name */
.cm-room.is-closed .cm-room-tx b::after{ content:""; display:inline-block; width:13px; height:13px; margin-inline-start:6px; vertical-align:-1px; background:currentColor; opacity:.55; -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M7 10V7a5 5 0 0 1 10 0v3h1a1 1 0 0 1 1 1v10a1 1 0 0 1-1 1H6a1 1 0 0 1-1-1V11a1 1 0 0 1 1-1zm2 0h6V7a3 3 0 0 0-6 0z'/%3E%3C/svg%3E") center/contain no-repeat; mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M7 10V7a5 5 0 0 1 10 0v3h1a1 1 0 0 1 1 1v10a1 1 0 0 1-1 1H6a1 1 0 0 1-1-1V11a1 1 0 0 1 1-1zm2 0h6V7a3 3 0 0 0-6 0z'/%3E%3C/svg%3E") center/contain no-repeat; }
.cm-tools button svg{ width:18px; height:18px; }

/* a muted room (the bell in the room's head): the bell crossed out, a small one by the room's name, its count grey */
.cm-room.is-muted .cm-room-tx b::before{ content:"🔕"; font-size:11px; margin-inline-end:5px; vertical-align:1px; }
.cm-room.is-muted .cm-room-new{ background:var(--muted); box-shadow:none; }
.cm-mute-pop{ width:250px; padding:10px; display:flex; flex-direction:column; gap:2px; }
.cm-mute-pop button{ display:flex; align-items:center; padding:10px 12px; border:0; border-radius:12px; background:transparent; color:var(--ink); font:700 14.5px 'Tajawal',sans-serif; text-align:start; cursor:pointer; }
.cm-mute-pop button:hover{ background:color-mix(in srgb, var(--ink) 6%, transparent); }
.cm-mute-pop .cm-mute-off{ color:var(--teal); font-weight:800; }
.cm-mute-now{ margin:0 6px 6px; color:var(--coral); font-size:13px; font-weight:700; }
.cm-mute-sound{ display:flex; align-items:center; gap:8px; margin-top:6px; padding:10px 8px 2px; border-top:1px solid var(--line); color:var(--muted); font-size:13.5px; font-weight:700; cursor:pointer; }
.cm-mute-sound input{ width:17px; height:17px; accent-color:var(--teal); }

/* a report: a reason to pick, words to write, or both */
.cm-report-why{ width:100%; min-height:76px; margin:0 0 14px; padding:10px 12px; border:1px solid var(--line); border-radius:12px; background:var(--bg); color:var(--ink); font:500 15px/1.6 'Tajawal',sans-serif; resize:vertical; outline:none; }
.cm-report-why:focus{ border-color:var(--teal); box-shadow:0 0 0 3px var(--teal-soft); }
.cm-report-opts label{ padding:9px 12px; }

/* the tools of a pointer stand beside the widest message too, inside the room (never a sideways scroll: #577) */
@media (hover:hover) and (pointer:fine){ .cm-msg{ max-width:min(78%, 640px, calc(100% - 112px)); } }

/* a room's own background (owner 2026-10-15: «خلفية … ضبابية شوية … لايقة … موبيل او ويب … دارك مود او لايت مود»):
   the owner's picture filling the room at any size (cover, centred), blurred and under a veil of the site's own colour
   (light cream or night black, as much as the owner chose), so the messages always read; the header and the box turn
   to frosted glass over it. assets/community.js paintBg, worker/src/chat.ts roomBg. */
.cm-chat.has-bg{ isolation:isolate; overflow:hidden; background-image:none; --cm-veil:rgba(250,247,240,var(--cm-bg-dim, .45)); }
html.arw-dark .cm-chat.has-bg{ --cm-veil:rgba(7,9,13,var(--cm-bg-dim, .45)); }
.cm-chat.has-bg::before{ content:""; position:absolute; inset:calc(var(--cm-bg-blur, 12px) * -2.5 - 4px); z-index:-1; pointer-events:none;
  background-color:var(--bg); background-image:linear-gradient(var(--cm-veil), var(--cm-veil)), var(--cm-bg, none); background-size:cover; background-position:center;
  filter:blur(var(--cm-bg-blur, 12px)) saturate(1.15); transition:opacity .5s ease; }
.cm-chat.has-bg .cm-head, .cm-chat.has-bg .cm-compose{ background:color-mix(in srgb, var(--card) 72%, transparent); -webkit-backdrop-filter:blur(18px) saturate(1.4); backdrop-filter:blur(18px) saturate(1.4); }
/* the words that sit on the picture itself get a soft glass of their own */
.cm-chat.has-bg .cm-reply-cap, .cm-chat.has-bg .cm-sys{ width:fit-content; padding:2px 9px; border-radius:999px; background:color-mix(in srgb, var(--card) 70%, transparent); -webkit-backdrop-filter:blur(8px); backdrop-filter:blur(8px); }
.cm-chat.has-bg .cm-msg.is-mine .cm-reply-cap{ margin-inline-start:auto; }
.cm-chat.has-bg .cm-msg.is-big .cm-meta, .cm-chat.has-bg .cm-msg.is-sticker .cm-meta{ width:fit-content; padding:1px 8px; border-radius:999px; background:color-mix(in srgb, var(--card) 70%, transparent); }

/* a secret room (owner 2026-10-15: «غرفة خاصة … سرية»): a small gold lock on its mark, and by its name in the header —
   seen only by those who may open it */
.cm-room.is-secret .cm-mark{ position:relative; overflow:visible; }
.cm-room.is-secret .cm-mark::after{ content:""; position:absolute; bottom:-4px; inset-inline-end:-4px; width:20px; height:20px; border-radius:50%; border:2px solid var(--card);
  background:#e09a12 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23fff' d='M7 10V7a5 5 0 0 1 10 0v3h1a1 1 0 0 1 1 1v10a1 1 0 0 1-1 1H6a1 1 0 0 1-1-1V11a1 1 0 0 1 1-1zm2 0h6V7a3 3 0 0 0-6 0z'/%3E%3C/svg%3E") center/11px no-repeat; }
.cm-head.is-secret .cm-head-name::after{ content:""; display:inline-block; width:16px; height:16px; margin-inline-start:6px; vertical-align:-2px; border-radius:50%;
  background:#e09a12 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23fff' d='M7 10V7a5 5 0 0 1 10 0v3h1a1 1 0 0 1 1 1v10a1 1 0 0 1-1 1H6a1 1 0 0 1-1-1V11a1 1 0 0 1 1-1zm2 0h6V7a3 3 0 0 0-6 0z'/%3E%3C/svg%3E") center/9px no-repeat; }

/* ── a phone: the community is an app of its own (owner 2026-10-15: «اكني فتحت تطبيق … الشات وبس … ولما بطلع وانزل
   بطلع وانزل في الشات بس»). The page itself never moves: the site's header, footer and bottom bar are gone, the
   community fills what the screen shows (above the keyboard: --vvt/--vvh, assets/community.js), and only its lists
   scroll. A long press is the message's menu, never a text selection; copying is in that menu. ── */
.cm-home{ display:none; }
@media (max-width:1150px){
  html:has(> body.cm-body){ height:100%; overflow:hidden; overscroll-behavior:none; }
  body.cm-body{ position:fixed; inset:0; width:100%; height:100%; overflow:hidden; overscroll-behavior:none; }
  body.cm-body > header, body.cm-body > footer, body.cm-body .arw-bottom-nav, body.cm-body .mobile-bottom-nav, body.cm-body .bottom-nav,
  body.cm-body .arw-more-sheet, body.cm-body .arw-more-overlay, body.cm-body .arw-reply-toast, body.cm-body .arw-follow-toast,
  body.cm-body .arw-nudge, body.cm-body .m-progress, body.cm-body .xp-top{ display:none !important; }
  .cm-page{ position:fixed; right:0; left:0; top:var(--vvt, 0px); height:var(--vvh, 100dvh); z-index:1200; display:flex; flex-direction:column; overflow:hidden; margin:0; padding:0; max-width:none; background:var(--bg);
    -webkit-user-select:none; user-select:none; -webkit-touch-callout:none; -webkit-tap-highlight-color:transparent; touch-action:manipulation; }
  .cm-page textarea, .cm-page input, .cm-page [contenteditable]{ -webkit-user-select:text; user-select:text; -webkit-touch-callout:default; }
  .cm-page img, .cm-page video{ -webkit-user-drag:none; }
  .cm-app{ flex:1; min-height:0; height:auto; display:flex; flex-direction:column; }
  /* the groups: the app's bar, then the list (it alone scrolls) */
  .cm-side{ flex:1; min-height:0; max-width:none; margin:0; }
  .cm-side-head{ display:grid; grid-template-columns:auto minmax(0,1fr); grid-template-areas:"home title" "home total"; align-items:center; column-gap:10px;
    padding:calc(10px + env(safe-area-inset-top, 0px)) 12px 10px; background:var(--card); border-bottom:1px solid var(--line); }
  .cm-home{ grid-area:home; display:inline-flex; align-items:center; justify-content:center; width:40px; height:40px; border-radius:50%; color:var(--ink); text-decoration:none; }
  .cm-home:active{ background:color-mix(in srgb, var(--ink) 8%, transparent); }
  html[dir="ltr"] .cm-home svg{ transform:scaleX(-1); }
  .cm-title{ grid-area:title; font-size:19px; }
  .cm-sub{ display:none; }
  .cm-total{ grid-area:total; justify-self:start; margin-top:2px; }
  .cm-rooms{ flex:1; min-height:0; overflow-y:auto; overscroll-behavior:contain; -webkit-overflow-scrolling:touch; padding:8px 10px 10px; }
  .cm-rules-link{ margin:4px 18px calc(10px + env(safe-area-inset-bottom, 0px)); }
  /* the room: the whole app, its messages alone scroll */
  .cm-app[data-view="room"] .cm-chat{ position:relative; inset:auto; top:auto; height:auto; flex:1; min-height:0; z-index:auto; }
  .cm-scroll, .cm-pop, .cm-emoji-pop, .cm-mention-pop{ overscroll-behavior:contain; -webkit-overflow-scrolling:touch; }
}
