/* css/private-left-r1.css — retained in original cascade order. */

@media (min-width: 761px) {
    #chat.private-view > .conversation > #messages,
    #chat.private-view > .conversation > #composer {
        align-self: flex-start;
    }
    #chat.private-view > .conversation > #composer {
        max-width: min(var(--chat-reading-width), calc(100% - 24px));
    }
}


/* css/web-polish-r1.css — retained in original cascade order. */
/* Preserve the private conversation position when its sidebar is hidden. */
@media (min-width: 761px) {
  #chat.shell.bird-sidebar-hidden.private-view {
    grid-template-columns: var(--side-panel-width, 180px) minmax(0, 1fr);
  }
}
/* The server tab has no participant list or outgoing calls. */
#chat.server-view #users-toggle,
#chat.server-view #users-panel,
#chat.server-view #call-head-controls,
#chat.server-view #call-phone,
#chat.server-view #call-video {
  display: none !important;
}
/* Icon styling must respect availability set by the call controller. */
#chat #call-phone[hidden],
#chat #call-video[hidden] {
  display: none !important;
}


/* css/conversation-search-r1.css — retained in original cascade order. */
/* The same transparent, fine-line violet glyph as camera/member controls. */
#chat.header-r1 #conversation-search-toggle,
#chat #conversation-search-toggle {
  box-sizing: border-box; display: inline-grid; place-items: center;
  flex: 0 0 38px; width: 38px; min-width: 38px; height: 38px; min-height: 38px;
  order: 3; margin: 0; padding: 7px; border: 0 !important; border-radius: 50%;
  background: transparent !important; box-shadow: none !important;
  color: var(--purple, #c177ff);
  color: color-mix(in srgb, var(--purple, #c177ff) 90%, white 10%); opacity: .82;
}
#chat #conversation-search-toggle svg,
#chat #conversation-search svg {
  display: block; width: 23px; height: 23px; fill: none;
  stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
  vector-effect: non-scaling-stroke; pointer-events: none;
}
#chat #conversation-search-toggle:hover,
#chat #conversation-search-toggle[aria-expanded="true"] { color: #d29bff; opacity: 1; }
#chat #conversation-search-toggle:focus-visible,
#chat #conversation-search button:focus-visible { outline: 1px solid var(--purple, #c177ff); outline-offset: 3px; }
#chat #conversation-search {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center;
  gap: 6px 10px; flex: none; padding: 8px 20px 10px;
  border: 0; color: var(--muted, #a3a4b7); background: transparent;
}
#chat #conversation-search[hidden] { display: none !important; }
#chat #conversation-search input {
  width: 100%; min-width: 0; padding: 8px 10px; font-size: 14px;
  border: 1px solid var(--zw-border, #494158); border-radius: 12px;
  background: var(--zw-panel, #191720); color: var(--zw-text, #eee);
}
#chat #conversation-search .search-controls { display: flex; align-items: center; gap: 2px; }
#chat #conversation-search .search-count { font-size: 12px; white-space: nowrap; padding-right: 5px; }
#chat #conversation-search button {
  display: inline-grid; place-items: center; flex: none; width: 32px; height: 34px;
  margin: 0; padding: 5px; border: 0; border-radius: 8px;
  background: transparent; color: var(--purple, #c177ff);
}
#chat #conversation-search button:disabled { opacity: .3; cursor: default; }
#chat #conversation-search-hint { grid-column: 1 / -1; font-size: 11px; }
#chat #messages > .line.zw-search-hit { background: rgba(177, 126, 240, .06); border-radius: 8px; }
#chat #messages > .line.zw-search-current { background: rgba(177, 126, 240, .15); outline: 1px solid var(--purple, #c177ff); outline-offset: 2px; }
@media (max-width: 760px) {
  #chat.header-r1 #conversation-search-toggle,
  #chat #conversation-search-toggle { width: 36px; min-width: 36px; flex-basis: 36px; height: 36px; min-height: 36px; padding: 6px; }
  #chat #conversation-search { padding: 6px 10px 8px; gap: 5px; }
  #chat #conversation-search input { font-size: 16px; }
  #chat #conversation-search .search-count { font-size: 11px; }
}
@media (max-width: 380px) {
  #chat #conversation-search { grid-template-columns: minmax(0, 1fr); }
  #chat #conversation-search .search-controls { justify-content: flex-end; }
}


/* css/panels-static-r1.css — retained in original cascade order. */
/* Desktop channels keep the same reading area for every panel combination. */
@media (min-width: 761px) {
  #chat.shell:not(.private-view):not(.server-view) {
    grid-template-columns: var(--side-panel-width, 180px) minmax(0, 1fr) var(--side-panel-width, 180px);
  }
  #chat.shell:not(.private-view):not(.server-view) > .conversation {
    grid-column: 2; grid-row: 2;
  }
  #chat.shell:not(.private-view):not(.server-view) > .sidebar {
    grid-column: 1; grid-row: 2;
  }
  #chat.shell:not(.private-view):not(.server-view) > .users-panel {
    grid-column: 3; grid-row: 2;
  }
}


/* css/jump-bottom-r1.css — retained in original cascade order. */
#chat #jump-bottom-r1 {
  position: absolute; right: 12px; bottom: 100px; z-index: 4;
  display: inline-grid; place-items: center; width: 40px; height: 40px;
  min-width: 40px; min-height: 40px; padding: 8px; margin: 0;
  border: 0; border-radius: 50%;
  background: var(--zw-panel, #191720);
  background: color-mix(in srgb, var(--zw-panel, #191720) 94%, transparent);
  color: var(--purple, #c177ff); opacity: .88;
  box-shadow: 0 2px 8px #0003;
}
#chat #jump-bottom-r1[hidden] { display: none !important; }
#chat #jump-bottom-r1 svg {
  display: block; width: 23px; height: 23px; fill: none;
  stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
  vector-effect: non-scaling-stroke; pointer-events: none;
}
#chat #jump-bottom-r1:hover { color: #d29bff; opacity: 1; }
#chat #jump-bottom-r1:focus-visible { outline: 1px solid var(--purple, #c177ff); outline-offset: 3px; opacity: 1; }


/* css/private-header-r1.css — retained in original cascade order. */
/* Remove only the letter tile from the private conversation heading. */
#chat.private-view .conversation-title > .conversation-icon {
  display: none !important;
}
#chat.private-view .conversation-title {
  grid-template-columns: minmax(0, 1fr);
  column-gap: 0;
}
#chat.private-view .conversation-title > h2,
#chat.private-view .conversation-title > .conversation-subtitle {
  grid-column: 1;
}


/* css/private-colour-r1.css — retained in original cascade order. */
/* Private heading uses the same public profile colour as message authors. */
#chat.private-view #room-title {
  color: var(--public-nick, #FFFFFF) !important;
}

