/* Late chat skeleton and iOS compose overlay rules.
 * Extracted from styles.css; keep import order in styles.css stable. */

/* Скелетоны первой отрисовки чата (без опоры только на :has в логике). */
@keyframes poker-chat-skeleton-shimmer {
  0% {
    background-position: 100% 0;
  }
  100% {
    background-position: 0 0;
  }
}
.chat-empty--skeleton {
  min-height: 1.15em;
  max-width: 220px;
  margin: 0.35rem 0;
  border-radius: 8px;
  color: transparent !important;
  overflow: hidden;
  pointer-events: none;
  background: linear-gradient(
    90deg,
    rgba(148, 163, 184, 0.14) 25%,
    rgba(148, 163, 184, 0.28) 40%,
    rgba(148, 163, 184, 0.14) 65%
  );
  background-size: 200% 100%;
  animation: poker-chat-skeleton-shimmer 1.1s ease-in-out infinite;
}
.chat-dialog-item__preview--skeleton {
  display: block;
  min-height: 1em;
  min-width: 120px;
  max-width: 100%;
  margin-top: 2px;
  border-radius: 6px;
  color: transparent !important;
  overflow: hidden;
  background: linear-gradient(
    90deg,
    rgba(148, 163, 184, 0.14) 25%,
    rgba(148, 163, 184, 0.28) 40%,
    rgba(148, 163, 184, 0.14) 65%
  );
  background-size: 200% 100%;
  animation: poker-chat-skeleton-shimmer 1.1s ease-in-out infinite;
}
.chat-ios-compose-overlay {
  position: fixed;
  inset: 0;
  z-index: 260;
  display: flex;
  align-items: flex-end;
  justify-content: stretch;
}
.chat-ios-compose-overlay--hidden {
  display: none !important;
}
.chat-ios-compose-overlay__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 8, 23, 0.72);
  backdrop-filter: blur(10px);
}
.chat-ios-compose-overlay__sheet {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: max(18px, env(safe-area-inset-top, 0px)) 14px calc(14px + env(safe-area-inset-bottom, 0px));
  border-radius: 24px 24px 0 0;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.98), rgba(15, 23, 42, 1));
  box-shadow: 0 -24px 48px rgba(2, 8, 23, 0.5);
}
.chat-ios-compose-overlay__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.chat-ios-compose-overlay__title-wrap {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.chat-ios-compose-overlay__eyebrow {
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #93c5fd;
}
.chat-ios-compose-overlay__title {
  font-size: 18px;
  line-height: 1.15;
  color: #f8fafc;
}
.chat-ios-compose-overlay__close,
.chat-ios-compose-overlay__cancel,
.chat-ios-compose-overlay__send {
  border: 0;
  border-radius: 14px;
  font: inherit;
}
.chat-ios-compose-overlay__close {
  width: 40px;
  height: 40px;
  background: rgba(148, 163, 184, 0.14);
  color: #e2e8f0;
  font-size: 24px;
}
.chat-ios-compose-overlay__textarea {
  width: 100%;
  min-height: 160px;
  max-height: 42dvh;
  resize: none;
  border-radius: 18px;
  border: 1px solid rgba(96, 165, 250, 0.28);
  background: rgba(15, 23, 42, 0.84);
  color: #f8fafc;
  padding: 14px 16px;
  box-sizing: border-box;
  font: 16px/1.4 inherit;
}
.chat-ios-compose-overlay__actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.chat-ios-compose-overlay__cancel {
  min-height: 48px;
  background: rgba(148, 163, 184, 0.14);
  color: #e2e8f0;
}
.chat-ios-compose-overlay__send {
  min-height: 48px;
  background: linear-gradient(180deg, #fb923c, #f97316);
  color: #fff7ed;
  font-weight: 700;
}
