/* QChat R66.1 communications center — responsive, theme-aware. */
.q66-nav-icon{width:18px;height:18px;display:inline-grid;place-items:center;flex:0 0 18px}.q66-nav-icon svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.q66-notice-bell{position:relative;width:36px;height:36px;display:grid;place-items:center;padding:0;border-radius:11px;background:var(--surface);color:var(--ink)}.q66-notice-bell svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}.q66-notice-bell i{position:absolute;top:-5px;left:-5px;min-width:17px;height:17px;padding:0 4px;border-radius:20px;background:#e24e64;color:#fff;font:700 10px/17px Vazirmatn,Arial;text-align:center;font-style:normal}
.q66-page{min-height:calc(100dvh - 145px);display:flex;flex-direction:column;gap:16px}.q66-page-head{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:22px 24px;border:1px solid var(--line);border-radius:18px;background:linear-gradient(120deg,var(--surface),var(--pale));}.q66-page-head h2{font-size:21px;margin:3px 0 5px}.q66-page-head p{margin:0;color:var(--muted);font-size:12px}.q66-kicker{display:block;color:var(--green);font:700 9px/1.5 Arial,sans-serif;letter-spacing:1.5px;direction:ltr;text-align:right}.q66-unread-summary{white-space:nowrap;background:var(--surface);border:1px solid var(--line);border-radius:999px;padding:7px 12px;color:var(--green);font-size:11px}
.q66-chat-layout{display:grid;grid-template-columns:minmax(260px,330px) minmax(0,1fr);gap:14px;min-height:500px;flex:1}.q66-thread-list,.q66-chat-panel,.q66-announcement-form,.q66-announcement-history{background:var(--surface);border:1px solid var(--line);border-radius:16px;min-width:0;overflow:hidden}.q66-thread-list{display:flex;flex-direction:column}.q66-section-head{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:14px 16px;border-bottom:1px solid var(--line);font-size:12px}.q66-section-head span{font-size:10px;color:var(--muted)}#q66-company-threads,#q66-host-threads{overflow:auto;min-height:0;flex:1;padding:7px}.q66-thread{display:flex;flex-direction:column;gap:3px;width:100%;padding:11px 12px;margin:2px 0;text-align:right;border:1px solid transparent;border-radius:11px;background:transparent}.q66-thread:hover{background:var(--bg)}.q66-thread.active{background:var(--pale);border-color:color-mix(in srgb,var(--green) 35%,var(--line))}.q66-thread-top{display:flex;align-items:center;justify-content:space-between;gap:8px}.q66-thread-top b{font-size:12px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.q66-thread-top i{font-style:normal;display:grid;place-items:center;min-width:19px;height:19px;padding:0 5px;border-radius:20px;background:#e24e64;color:white;font-size:10px}.q66-thread small{font-size:10px;color:var(--muted)}.q66-thread-preview{font-size:11px;color:var(--ink);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;opacity:.8}
.q66-chat-panel{display:grid;grid-template-rows:auto minmax(0,1fr) auto;min-height:500px}.q66-chat-head{display:flex;align-items:center;gap:12px;padding:12px 16px;border-bottom:1px solid var(--line);min-height:62px}.q66-chat-head>div{display:flex;flex-direction:column;min-width:0}.q66-chat-head b{font-size:13px}.q66-chat-head small{font-size:10px;color:var(--muted)}.q66-back{display:none;padding:6px 9px;font-size:10px}.q66-messages{overflow:auto;min-height:0;padding:18px;background:var(--bg);display:flex;flex-direction:column;gap:10px}.q66-bubble{max-width:min(82%,680px);padding:11px 14px;border:1px solid var(--line);border-radius:14px;background:var(--surface);box-shadow:var(--shadow);overflow-wrap:anywhere}.q66-bubble.q66-company{align-self:flex-start;border-bottom-right-radius:4px}.q66-bubble.q66-site{align-self:flex-end;border-bottom-left-radius:4px;background:var(--pale)}.q66-bubble-head{display:flex;justify-content:space-between;align-items:center;gap:12px}.q66-bubble-head b{font-size:10px;color:var(--green)}.q66-bubble-head small{font-size:9px;color:var(--muted)}.q66-bubble p{margin:5px 0 0;white-space:pre-wrap;font-size:12px;line-height:1.9}.q66-composer{display:flex;align-items:flex-end;gap:9px;padding:11px;border-top:1px solid var(--line)}.q66-composer textarea{min-height:48px;height:54px;max-height:130px;resize:vertical}.q66-composer button{min-width:105px;height:46px}.q66-empty{padding:24px 14px;text-align:center;color:var(--muted);font-size:11px;line-height:2}
.q66-form{padding:4px 0}.q66-form h2{margin:0 0 14px}.q66-form label,.q66-announcement-form label{display:block;font-size:11px;color:var(--muted);margin:11px 0}.q66-form textarea,.q66-announcement-form textarea{min-height:120px}.q66-notice-list{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(360px,100%),1fr));gap:12px}.q66-notice{border:1px solid var(--line);background:var(--surface);border-radius:15px;padding:17px;box-shadow:var(--shadow)}.q66-notice.read{opacity:.72}.q66-notice-head{display:flex;justify-content:space-between;align-items:center;gap:8px}.q66-notice-head small,.q66-notice .q66-read-label{font-size:10px;color:var(--muted)}.q66-level{display:inline-block;padding:3px 9px;border-radius:999px;background:var(--pale);color:var(--green);font-size:10px}.q66-notice.level-warning{border-inline-start:4px solid #d49a32}.q66-notice.level-critical{border-inline-start:4px solid #d94d5c}.q66-notice.level-maintenance{border-inline-start:4px solid #4787bd}.q66-notice h3{margin:10px 0 4px;font-size:14px}.q66-notice p{white-space:pre-wrap;overflow-wrap:anywhere;font-size:12px;line-height:2;margin:0 0 12px}.q66-notice button{font-size:10px;padding:6px 10px}.q66-tabs{display:flex;gap:7px;flex-wrap:wrap}.q66-tabs button{font-size:11px}.q66-tabs button.active{background:var(--purple);border-color:var(--purple);color:white}.q66-announcements{display:grid;grid-template-columns:minmax(300px,.9fr) minmax(0,1.1fr);gap:14px;align-items:start}.q66-announcements[hidden]{display:none!important}.q66-announcement-form{padding:17px}.q66-announcement-form form{padding:3px 16px 16px}.q66-announcement-form select[multiple]{min-height:140px}.q66-check{display:flex!important;align-items:center;gap:8px}.q66-check input{width:17px;height:17px}.q66-announcement-form form>button{width:100%;margin-top:8px}.q66-announcement-history{padding-bottom:8px}.q66-announcement-row{padding:13px 16px;border-bottom:1px solid var(--line)}.q66-announcement-row:last-child{border-bottom:0}.q66-row-title{display:flex;align-items:center;justify-content:space-between;gap:10px}.q66-row-title b{font-size:12px}.q66-announcement-row p{font-size:11px;line-height:1.9;margin:5px 0;white-space:pre-wrap}.q66-announcement-row small{font-size:9px;color:var(--muted)}
@media(max-width:1050px){.q66-chat-layout{grid-template-columns:minmax(220px,280px) minmax(0,1fr)}.q66-announcements{grid-template-columns:1fr}.q66-page-head{padding:18px}}
@media(max-width:720px){.q66-page{min-height:calc(100dvh - 100px)}.q66-page-head{align-items:flex-start;flex-direction:column;gap:12px;padding:15px}.q66-page-head h2{font-size:18px}.q66-page-head p{font-size:11px}.q66-chat-layout{display:grid;grid-template-columns:minmax(0,1fr);min-height:calc(100dvh - 250px);position:relative}.q66-thread-list{display:flex;min-height:300px}.q66-chat-panel{display:none;min-height:calc(100dvh - 250px)}.q66-chat-layout.q66-chat-open .q66-thread-list{display:none}.q66-chat-layout.q66-chat-open .q66-chat-panel{display:grid}.q66-back{display:inline-block}.q66-bubble{max-width:94%}.q66-composer{align-items:stretch;flex-wrap:wrap}.q66-composer textarea{flex-basis:100%}.q66-composer button{width:100%}.q66-announcements{grid-template-columns:minmax(0,1fr)}.q66-notice-list{grid-template-columns:minmax(0,1fr)}.q66-host-layout .q66-chat-panel{min-height:calc(100dvh - 245px)}}
@media(min-width:721px) and (max-width:1050px){.q66-chat-layout{grid-template-columns:260px minmax(0,1fr)}.q66-bubble{max-width:90%}}
.q653-head-actions{display:flex;align-items:center;gap:5px}.q653-head-actions button{font-size:10px;padding:5px 9px;white-space:nowrap}.q653-head-actions #q653-sync{color:var(--green);border-color:color-mix(in srgb,var(--green) 40%,var(--line));background:var(--pale)}
.q66-status-action,.q66-status-tools button{font-size:10px;padding:5px 9px;white-space:nowrap}.q66-status-tools{display:flex;gap:5px;align-items:center;margin-inline-start:auto}.q66-status-tools button:first-child{color:var(--green)}.q66-status-action[hidden],.q66-status-tools button[hidden]{display:none!important}

/* R66.4 — one unified notification bell beside the language control. */
.header-side{position:relative}
.q66-bell-wrap{position:relative;display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto;z-index:10030}
.q66-notice-bell{position:relative;width:36px;height:36px;display:grid;place-items:center;padding:0;border:1px solid var(--line);border-radius:11px;background:var(--surface);color:var(--ink);cursor:pointer;box-shadow:none}
.q66-notice-bell:hover{background:var(--pale)}
.q66-notice-bell[data-alert="1"]{border-color:color-mix(in srgb,#d94d5c 48%,var(--line));color:var(--ink);background:var(--surface)}
.q66-notice-bell svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.q66-notice-bell i{position:absolute;top:-5px;inset-inline-start:-5px;min-width:17px;height:17px;padding:0 4px;border-radius:20px;background:var(--green);color:#fff;font:700 10px/17px Vazirmatn,Arial;text-align:center;font-style:normal}
.q66-notice-panel{position:absolute;top:calc(100% + 9px);inset-inline-end:0;width:min(430px,calc(100vw - 24px));max-height:min(76vh,680px);overflow:auto;overscroll-behavior:contain;border:1px solid var(--line);border-radius:15px;background:var(--surface);color:var(--ink);box-shadow:0 18px 60px #0004;padding:0;z-index:10040;direction:rtl}
.q66-notice-panel[hidden]{display:none!important}
.q66-bell-head{position:sticky;top:0;z-index:2;display:flex;align-items:center;gap:10px;padding:12px 14px;background:var(--surface);border-bottom:1px solid var(--line)}
.q66-bell-head b{font-size:13px}.q66-bell-head span{margin-inline-start:auto;font-size:10px;color:var(--muted)}
.q66-bell-head button{width:27px;height:27px;padding:0;border:1px solid var(--line);border-radius:8px;background:var(--bg);color:var(--ink);font-size:18px;line-height:1}
.q66-bell-group{padding:10px 12px;border-bottom:1px solid var(--line)}
.q66-bell-group>header{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:3px 2px 8px}
.q66-bell-group>header b{font-size:11px}.q66-bell-group>header span{font-size:9px;color:var(--muted)}
.q66-bell-item{display:flex;align-items:flex-start;gap:10px;padding:10px 9px;margin:5px 0;border:1px solid var(--line);border-radius:10px;background:var(--bg)}
.q66-bell-item>div{flex:1;min-width:0}.q66-bell-item b{display:block;font-size:11px;line-height:1.7}
.q66-bell-item small{display:block;margin-top:2px;color:var(--muted);font-size:9px;line-height:1.7}
.q66-bell-item p{margin:5px 0 0;font-size:10px;line-height:1.8;white-space:pre-wrap;overflow-wrap:anywhere}
.q66-bell-item.read{opacity:.68}
.q66-bell-item button,.q66-bell-more{flex:0 0 auto;padding:6px 9px;border:1px solid var(--line);border-radius:8px;background:var(--surface);color:var(--ink);font:inherit;font-size:9px;white-space:nowrap}
.q66-bell-item.q66-bell-health{border-inline-start:3px solid #d49a32}
.q66-bell-read{font-size:9px;color:var(--muted);white-space:nowrap}
.q66-bell-chat{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:3px 8px;width:100%;padding:9px;margin:5px 0;text-align:right;border:1px solid var(--line);border-radius:10px;background:var(--bg);color:var(--ink)}
.q66-bell-chat b{font-size:10px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.q66-bell-chat small{grid-column:1;grid-row:2;font-size:9px;color:var(--muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.q66-bell-chat i{grid-column:2;grid-row:1/3;align-self:center;display:grid;place-items:center;min-width:19px;height:19px;padding:0 5px;border-radius:20px;background:#d94d5c;color:white;font-size:9px;font-style:normal}
.q66-bell-empty{padding:9px 4px;margin:0;color:var(--muted);font-size:10px;line-height:1.8}
.q66-bell-more{display:block;width:100%;margin-top:8px;background:var(--pale);border-color:color-mix(in srgb,var(--green) 28%,var(--line));color:var(--ink)}
@media(max-width:600px){.q66-notice-panel{position:fixed;top:64px;inset-inline:12px;width:auto;max-height:calc(100dvh - 84px)}.q66-bell-item{flex-wrap:wrap}.q66-bell-item button{margin-inline-start:auto}}
