/* Full-height chat surface: header and composer stay put, only messages scroll. */
.screen-transition:has(.direct-room, .group-chat-room) {
  position: fixed;
  z-index: 40;
  top: 0;
  right: 0;
  bottom: calc(80px + max(10px, var(--safe-bottom)));
  left: 0;
  width: 100%;
  max-width: var(--app-shell-width);
  height: auto;
  min-height: 0;
  margin: 0 auto;
  overflow: hidden;
  animation: none;
}

.screen-transition:has(.group-chat-room) {
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
}

.screen-transition:has(.group-chat-room) > .group-chat-room.is-embedded {
  position: relative;
  height: 100%;
  max-height: 100%;
  min-height: 0;
  align-self: stretch;
  overflow: hidden;
}

.direct-room,
.group-chat-room {
  min-height: 0;
  overflow: hidden;
}

.direct-room__messages,
.group-chat-room__messages {
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.direct-composer,
.group-chat-composer {
  position: static !important;
  inset: auto !important;
  bottom: auto !important;
  flex: none;
  width: 100%;
}

@media (width >= 640px) {
  .screen-transition:has(.direct-room, .group-chat-room) {
    top: 20px;
    bottom: 100px;
  }
}

.club-entry-card--forming{cursor:default}.club-entry-card--forming:active{transform:none}.club-entry-card--forming .club-entry-card__action{z-index:2;cursor:pointer;border:1px solid #efede257}.club-entry-card--forming .club-entry-card__action:disabled{cursor:default}.club-entry-card--forming .club-entry-card__action.is-joined{color:#adbaa4;background:#0e1e14cf;border-color:#ced3bc38}
html[data-theme=light] .club-entry-card--forming .club-entry-card__action.is-joined{color:#5a7865;background:#e9e7dfed;border-color:#385b4530}

/* Admin wait-list overview. */
.admin-chat-applications {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 16px;
}

.admin-chat-applications > article {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-width: 0;
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(145deg, #193423b8, #08180eb3);
}

.admin-chat-applications__icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  color: #bdc5b2;
  border: 1px solid #eae8d829;
  border-radius: 14px;
}

.admin-chat-applications > article div {
  min-width: 0;
}

.admin-chat-applications > article strong,
.admin-chat-applications > article small {
  display: block;
}

.admin-chat-applications > article strong {
  overflow: hidden;
  color: var(--ink);
  font-family: var(--serif);
  font-size: 17px;
  font-weight: 400;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-chat-applications > article small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 9px;
}

.admin-chat-applications > article b {
  padding: 8px 11px;
  color: #eae7dc;
  border: 1px solid #d8dcc13d;
  border-radius: 999px;
  background: #3a664b4a;
  font-size: 10px;
  white-space: nowrap;
}

html[data-theme=light] .admin-chat-applications > article {
  background: linear-gradient(145deg, #ffffffd9, #edebe4d1);
  border-color: #375a4429;
  box-shadow: inset 0 1px #fff;
}

html[data-theme=light] .admin-chat-applications__icon {
  color: #537a62;
  border-color: #385b4530;
}

html[data-theme=light] .admin-chat-applications > article b {
  color: #315b41;
  background: #c6d1b14a;
  border-color: #3c6d4f38;
}

@media (width < 700px) {
  .admin-chat-applications {
    grid-template-columns: 1fr;
    padding: 12px;
  }
}

/* Confirmation sheets must cover the navigation and the whole viewport. */
.app-shell:has(.chat-delete-backdrop, .direct-delete-backdrop) > .bottom-nav {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

.screen-transition:has(.chat-delete-backdrop, .direct-delete-backdrop) {
  z-index: 130;
  bottom: 0;
  overflow: visible;
}

.group-chat-room:has(.chat-delete-backdrop),
.direct-room:has(.direct-delete-backdrop) {
  overflow: visible;
}

.chat-delete-backdrop,
.direct-delete-backdrop {
  z-index: 200;
  inset: 0;
  min-height: 100dvh;
  padding: 18px 18px calc(18px + var(--safe-bottom));
}

.chat-delete-sheet,
.direct-delete-sheet {
  max-height: calc(100dvh - 36px - var(--safe-bottom));
  overflow-y: auto;
  overscroll-behavior: contain;
}

/* Complete light palette for the administration area. */
.admin-page {
  min-height: 100dvh;
  color: #1d3a28;
  background:
    radial-gradient(circle at 92% 4%, #a6c09824, transparent 22rem),
    linear-gradient(180deg, #f5f3ef 0%, #efede7 100%);
}

.admin-header {
  color: #1d3a28;
  background: linear-gradient(180deg, #f9f8f4f7, #f1efe9f2);
  border-color: #375a4424;
  box-shadow: 0 9px 26px #36544214;
}

.admin-header > span {
  color: #284a35;
}

.admin-header button {
  color: #517760;
}

.admin-header button:hover {
  color: #30563f;
  background: #ffffff99;
  border-color: #385b4529;
}

.admin-intro .eyebrow {
  color: #678a74;
}

.admin-intro h1 {
  color: #1a3625;
}

.admin-intro p {
  color: #668472;
}

.admin-live,
.admin-online {
  color: #6e8b78;
}

.admin-live i,
.admin-online i {
  background: #6fa282;
  box-shadow: 0 0 0 4px #6fa2821f, 0 0 12px #5f9b7752;
}

.admin-stat-card {
  color: #1d3a28;
  background:
    radial-gradient(circle at 100% 0, #8db5871c, transparent 8rem),
    linear-gradient(145deg, #fffffff2, #eae8dff0);
  border-color: #375a442b;
  box-shadow: 0 13px 30px #36544212, inset 0 1px #fff;
}

.admin-stat-card > span {
  color: #577c65;
  background: #ffffff8f;
  border-color: #385b4530;
  box-shadow: inset 0 1px #fff;
}

.admin-stat-card strong {
  color: #1d3a28;
}

.admin-stat-card small {
  color: #6c8a77;
}

.admin-workspace {
  color: #1d3a28;
  background: linear-gradient(160deg, #fffffff0, #edebe5f2);
  border-color: #375a442e;
  box-shadow: 0 22px 58px #3654421a, inset 0 1px #fff;
}

.admin-toolbar {
  background: #f4f2edd9;
  border-color: #375a4421;
}

.admin-tabs button {
  color: #668472;
  border-color: transparent;
}

.admin-tabs button:hover {
  color: #365b44;
  background: #ffffff7d;
  border-color: #385b4521;
}

.admin-tabs button.is-active {
  color: #f8f7f5;
  background: linear-gradient(145deg, #527e63, #325b42 78%);
  border-color: #2d533c57;
  box-shadow: 0 7px 18px #2f523c29, inset 0 1px #ffffff29;
}

.admin-search {
  color: #5a7e68;
  background: #ffffffe0;
  border-color: #375a4430;
  box-shadow: inset 0 1px #fff;
}

.admin-search input {
  color: #1d3a28;
}

.admin-search input::placeholder {
  color: #869c87;
  opacity: 1;
}

.admin-user-row,
.admin-content-row,
.admin-audit-row,
.admin-moderation-card {
  color: #1d3a28;
  background: #ffffff45;
  border-color: #375a441f;
}

.admin-user-row:nth-child(even),
.admin-content-row:nth-child(even),
.admin-audit-row:nth-child(even) {
  background: #e9e7df3d;
}

.admin-user-row.is-muted,
.admin-content-row.is-muted {
  background: #eadadd70;
}

.admin-user-avatar,
.admin-content-placeholder {
  color: #325b42;
  background: linear-gradient(145deg, #ffffffd9, #e2e2d0d9);
  border-color: #385b4530;
  box-shadow: inset 0 1px #fff;
}

.admin-content-row > img,
.admin-moderation-card > img {
  border-color: #385b4530;
}

.admin-row-title strong,
.admin-audit-row strong {
  color: #22412e;
}

.admin-row-copy p,
.admin-audit-row p {
  color: #5a7966;
}

.admin-row-copy small,
.admin-audit-row small {
  color: #7a947f;
}

.admin-role {
  color: #527961;
  background: #ffffff78;
  border-color: #385b4530;
}

.admin-blocked {
  color: #985c68;
  background: #a9566412;
  border-color: #a34f5e38;
}

.admin-action {
  color: #517760;
  background: #ffffff8c;
  border-color: #385b4530;
  box-shadow: inset 0 1px #fff;
}

.admin-action--danger {
  color: #9b5a67;
  background: #fff7f8a8;
  border-color: #a654633d;
}

.admin-action--restore {
  color: #47765f;
  background: #f5fbf7a8;
  border-color: #5180683b;
}

.admin-moderation__section + .admin-moderation__section,
.admin-moderation__section > header {
  border-color: #375a4421;
}

.admin-moderation__section > header {
  background: #f1f0eaa8;
}

.admin-moderation__section > header .eyebrow {
  color: #6d8e78;
}

.admin-moderation__section > header h2 {
  color: #22412e;
}

.admin-moderation__section > header b {
  color: #3f664e;
  background: #ffffff94;
  border-color: #385b4530;
}

.admin-moderation-card blockquote {
  color: #597965;
  background: #ffffff85;
  border-color: #5f8c703d;
}

.admin-review-status {
  color: #4d7863;
  background: #5c8b7012;
  border-color: #50806732;
}

.admin-review-status.is-pending {
  color: #648b38;
  background: #7bba3417;
  border-color: #709f3b38;
}

.admin-moderation-card__actions button {
  color: #47765f;
  background: #f7fbf8c2;
  border-color: #5180683b;
}

.admin-moderation-card__actions button.is-danger {
  color: #9b5a67;
  background: #fff7f8c2;
  border-color: #a654633d;
}

.admin-moderation-empty,
.admin-loading,
.admin-empty,
.admin-access-state {
  color: #6c8a77;
}

.admin-audit-row > span {
  color: #577c65;
  background: #ffffff8c;
  border-color: #385b4530;
}

.admin-error {
  color: #925865;
  background: #f4dfe3b8;
  border-color: #a6546338;
}

.admin-access-state h1 {
  color: #1d3a28;
}

.admin-access-state button {
  color: #f8f7f5;
  background: linear-gradient(145deg, #527e63, #325b42 78%);
  border-color: #2d533c57;
  box-shadow: 0 8px 20px #2f523c29, inset 0 1px #ffffff29;
}
