/* =====================================================================
   Panel Header & Navigation Chrome (Profile, Chats, & Sub-Views)
   ===================================================================== */

panel-header {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 52px;
  background-color: rgba(255, 255, 255, 0.92);  /* Modern frosted surface */
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-subtle, #edebe6);
  color: var(--text-main, #16181b);             /* Deep ink text */
  position: sticky;
  top: 0;
  z-index: 10;
  font-size: 1.05rem;
  letter-spacing: -0.015em;
  padding: 0 16px;
}

/* Back / Close button container */
panel-close {
  position: absolute;
  left: 12px;
  display: flex;
  align-items: center;
  cursor: pointer;
  height: 100%;
  font-size: 0.95rem;
  color: var(--text-main, #16181b);
}

panel-close .back-button {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  border: none;
  background: transparent;
  cursor: pointer;
}

panel-close:hover .back-button {
  background-color: rgba(22, 24, 27, 0.05);
}

panel-close .icon-chevron {
  margin-right: 6px;
}

panel-close .back-button:focus-visible {
    outline: none;
}

/* Centered title/handle label */
panel-label {
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: -0.02em;
  color: var(--text-main, #16181b);
  max-width: 60%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Sub-action icons */
dm-chats-module dm-home-acoount {
  position: absolute;
  right: 15px;
  width: 26px;
  height: 26px;
  background: url("/images/gears_icon.png") no-repeat center;
  cursor: pointer;
  opacity: 0.75;
  transition: opacity 0.15s ease;
}

dm-chats-module dm-home-acoount:hover {
  opacity: 1;
}

/* Chevron Back Icon */
.icon-chevron {
  display: inline-block;
  width: 20px;
  height: 20px;
  background-color: currentColor;               /* Adapts to dark/light text */
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='15 18 9 12 15 6'%3E%3C/polyline%3E%3C/svg%3E") no-repeat center / contain;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='15 18 9 12 15 6'%3E%3C/polyline%3E%3C/svg%3E") no-repeat center / contain;
  vertical-align: middle;
}