/* Night Hello route owner: aligned with the mobile My Account visual system. */
.night-hello-page {
  --hello-bg: rgb(250, 250, 249);
  --hello-card: #fff;
  --hello-soft: #f5f5f7;
  --hello-text: #101114;
  --hello-muted: #747780;
  --hello-line: #ececf0;
  --hello-purple: #6439fc;
  width: min(100% - 16px, 720px);
  min-height: 100dvh;
  margin: 0 auto;
  padding: 68px 0 126px;
  background: var(--hello-bg);
  color: var(--hello-text);
  box-sizing: border-box;
}

body.night-hello-route,
body.night-hello-route #app {
  background: rgb(250, 250, 249);
}

body.night-mode.night-hello-route,
body.night-mode.night-hello-route #app {
  background: #09090a;
}

.night-hello-page h1,
.night-hello-page h2,
.night-hello-page p {
  margin: 0;
}

.night-hello-page > header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin: 0 0 20px;
  padding: 22px 20px;
  border: 0;
  border-radius: 24px;
  background: var(--hello-card);
}

.night-hello-page > header > div {
  display: grid;
  gap: 5px;
}


.night-hello-page .eyebrow {
  color: #00b908;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .15em;
}

.night-hello-page h1 {
  color: var(--hello-text);
  font-size: 28px;
  font-weight: 850;
  line-height: 1;
  letter-spacing: -.035em;
}


.night-hello-row {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  min-height: 92px;
  padding: 16px 18px;
  border: 0;
  border-radius: 22px;
  background: var(--hello-card);
  color: var(--hello-text);
  text-decoration: none;
}

.night-hello-avatar {
  display: grid;
  width: 52px;
  height: 52px;
  place-items: center;
  overflow: hidden;
  border-radius: 50%;
  background: #f0f0f2;
  color: #101114;
  font-size: 16px;
  font-weight: 900;
}

.night-hello-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.night-hello-row-copy {
  display: grid;
  min-width: 0;
  gap: 4px;
}

.night-hello-row-copy strong {
  font-size: 14px;
  font-weight: 850;
}

.night-hello-row-copy span,
.night-hello-row-copy small {
  overflow: hidden;
  color: var(--hello-muted);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.night-hello-row-copy span {
  font-size: 12px;
}

.night-hello-row-copy small {
  font-size: 10px;
}

.night-hello-row-state {
  display: grid;
  justify-items: end;
  gap: 7px;
  color: var(--hello-muted);
  font-size: 10px;
}

.night-hello-row-state i {
  color: var(--hello-purple);
  font-style: normal;
  font-weight: 750;
}

.night-hello-row.is-expired {
  background: #ededed;
  color: #8d8d92;
  cursor: pointer;
  opacity: .72;
}

.night-hello-row.is-expired:hover,
.night-hello-row.is-expired:focus-visible {
  opacity: .9;
}

.night-hello-row.is-expired .night-hello-avatar {
  filter: grayscale(1);
}

.night-hello-row.is-expired .night-hello-row-copy strong,
.night-hello-row.is-expired .night-hello-row-state i {
  color: #8d8d92;
}

.night-hello-unread {
  display: grid;
  min-width: 20px;
  height: 20px;
  place-items: center;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--hello-purple);
  color: #fff;
  font-weight: 900;
}

.night-hello-empty {
  display: grid;
  min-height: 260px;
  place-items: center;
  align-content: center;
  gap: 8px;
  padding: 28px;
  border-radius: 24px;
  background: var(--hello-card);
  text-align: center;
}

.night-hello-empty h2 {
  color: var(--hello-text);
  font-size: 20px;
}

.night-hello-empty p {
  max-width: 300px;
  color: var(--hello-muted);
  font-size: 12px;
  line-height: 1.5;
}

.night-hello-page > header > a,
.night-hello-report {
  min-height: 34px;
  padding: 9px 12px;
  border: 0;
  border-radius: 999px;
  background: var(--hello-soft);
  color: var(--hello-text);
  font-size: 11px;
  font-weight: 800;
  text-decoration: none;
}

.night-hello-conversation-page {
  display: flex;
  width: min(calc(100% - 48px), 960px);
  height: 100dvh;
  min-height: 0;
  flex-direction: column;
  padding-bottom: 20px;
  overflow: hidden;
}

.night-hello-conversation-page > header {
  flex: 0 0 auto;
}

.night-hello-page .night-hello-chat {
  display: flex;
  width: 100%;
  max-width: none;
  min-height: 0;
  flex: 1 1 auto;
  flex-direction: column;
  margin: 0;
  padding: 0 18px 18px;
  overflow: hidden;
  border-radius: 24px;
  background: var(--hello-card);
  box-sizing: border-box;
}

.night-hello-chat-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 20px 0 18px;
  border-bottom: 1px solid var(--hello-line);
}

.night-hello-chat-head .night-hello-peer {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 12px;
}

.night-hello-chat-meta {
  display: grid;
  justify-items: end;
  gap: 4px;
  text-align: right;
}

.night-hello-chat-head h2 {
  font-size: 20px;
}

.night-hello-chat-head time,
.night-hello-chat-head small {
  color: var(--hello-muted);
  font-size: 11px;
}

.night-hello-messages {
  display: flex;
  min-height: 0;
  flex: 1;
  flex-direction: column;
  gap: 10px;
  padding: 20px 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.night-hello-messages::-webkit-scrollbar {
  display: none;
}

.night-hello-message {
  align-self: flex-start;
  max-width: 80%;
  padding: 11px 14px;
  border-radius: 17px 17px 17px 5px;
  background: var(--hello-soft);
  color: var(--hello-text);
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.night-hello-message.is-own {
  align-self: flex-end;
  border-radius: 17px 17px 5px 17px;
  background: #ebe7ff;
  color: #2f255f;
}

.night-hello-message small {
  display: block;
  margin-top: 4px;
  color: inherit;
  opacity: .65;
}

.night-hello-message img {
  display: block;
  max-width: 260px;
  max-height: 320px;
  border-radius: 12px;
  object-fit: cover;
}

.night-hello-request-actions,
.night-hello-compose {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 14px 0 0;
}

.night-hello-request-actions .primary,
.night-hello-request-actions .secondary {
  width: 90px;
  height: 54px;
  min-width: 90px;
  min-height: 54px;
  margin: 0;
  padding: 0 18px;
  border: 0;
  border-radius: 999px;
  font-weight: 800;
}

.night-hello-request-actions .secondary {
  background: #ededed;
  color: #e35f4f;
}

.night-hello-compose {
  position: static;
  flex: 0 0 auto;
  background: var(--hello-card);
}

.night-hello-compose input[type="text"] {
  flex: 1;
  min-width: 0;
  padding: 13px 15px;
  border: 1px solid var(--hello-line);
  border-radius: 999px;
  background: var(--hello-soft);
  color: var(--hello-text);
}

.night-hello-image-input {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border: 1px solid var(--hello-line);
  border-radius: 50%;
  background: var(--hello-soft);
  color: var(--hello-purple);
  cursor: pointer;
}

.night-hello-image-input input {
  display: none;
}

.night-hello-expired {
  margin: auto;
  padding: 24px;
  color: var(--hello-muted);
  text-align: center;
}

.night-hello-send {
  margin-top: 14px;
}

.night-hello-modal {
  position: fixed;
  inset: 0;
  z-index: 150;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(0,0,0,.68);
}

.night-hello-modal[hidden] {
  display: none;
}

.night-hello-sheet {
  position: relative;
  width: min(100%, 440px);
  padding: 22px;
  border-radius: 24px;
  background: var(--hello-card, #fff);
  color: var(--hello-text, #101114);
}

.night-hello-sheet textarea {
  width: 100%;
  min-height: 110px;
  margin: 15px 0;
  padding: 12px;
  border: 1px solid var(--hello-line, #ececf0);
  border-radius: 14px;
  background: var(--hello-soft, #f5f5f7);
  color: inherit;
  resize: vertical;
}

.night-hello-bell {
  position: relative;
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border: 0;
  background: transparent;
  color: inherit;
}

.night-hello-bell svg {
  width: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
}

.night-hello-bell .night-hello-badge {
  position: absolute;
  top: -4px;
  right: -3px;
  display: inline-grid;
  min-width: 18px;
  height: 18px;
  place-items: center;
  padding: 0 5px;
  border: 2px solid #fff;
  border-radius: 999px;
  background: #ff2d8d;
  color: #fff;
  -webkit-text-fill-color: #fff;
  font-size: 10px;
  font-weight: 950;
  line-height: 1;
  box-shadow: 0 8px 18px rgba(255, 45, 141, .34);
}

body.night-mode .night-hello-page {
  --hello-bg: #09090a;
  --hello-card: #171719;
  --hello-soft: #222226;
  --hello-text: #f5f5f7;
  --hello-muted: #a3a3aa;
  --hello-line: #303036;
}

@media (max-width: 719px) {
  body.night-hello-conversation-active #app > .global-mobile-nav {
    display: none;
  }

  .night-hello-page {
    width: calc(100% - 16px);
    height: calc(100dvh - 54px);
    min-height: 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  .night-hello-conversation-page {
    display: flex;
    width: 100%;
    height: 100dvh;
    flex-direction: column;
    align-items: stretch;
    margin: 0;
    padding: calc(64px + env(safe-area-inset-top)) 12px calc(84px + env(safe-area-inset-bottom));
    overflow: hidden;
  }

  .night-hello-page > header {
    align-items: flex-start;
    padding: 18px 20px;
  }

  .night-hello-conversation-page > header {
    width: 100%;
    max-width: none;
    flex: 0 0 auto;
    align-items: center;
    margin: 0 0 12px;
    padding: 10px 12px;
    border-radius: 18px;
    box-sizing: border-box;
  }

  .night-hello-page h1 {
    font-size: 27px;
  }

  .night-hello-row {
    grid-template-columns: 48px minmax(0, 1fr) auto;
    min-height: 86px;
    padding: 14px 16px;
  }

  .night-hello-avatar {
    width: 48px;
    height: 48px;
  }

  .night-hello-conversation-page .night-hello-chat {
    width: 100%;
    max-width: none;
    min-height: 0;
    flex: 1 1 auto;
    margin: 0;
    padding: 0 14px;
    overflow: hidden;
    border-radius: 20px;
    box-sizing: border-box;
  }

  .night-hello-conversation-page .night-hello-chat-head {
    flex: 0 0 auto;
    padding: 14px 0 12px;
  }

  .night-hello-conversation-page .night-hello-messages {
    min-height: 0;
    padding: 14px 0 18px;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  .night-hello-conversation-page .night-hello-messages::-webkit-scrollbar {
    display: none;
  }

  .night-hello-conversation-page .night-hello-compose {
    position: fixed;
    z-index: 130;
    right: auto;
    bottom: max(10px, env(safe-area-inset-bottom));
    left: 50%;
    display: grid;
    grid-template-columns: 40px minmax(0, 1fr) 60px;
    width: min(696px, calc(100% - 24px));
    height: 58px;
    align-items: center;
    gap: 8px;
    margin: 0;
    padding: 8px 9px;
    border: 0;
    border-radius: 999px;
    background: rgba(255,255,255,.88);
    box-shadow: 0 16px 40px rgba(36,26,86,.18);
    -webkit-backdrop-filter: blur(20px) saturate(160%);
    backdrop-filter: blur(20px) saturate(160%);
    box-sizing: border-box;
    transform: translateX(-50%);
  }

  body.night-mode .night-hello-conversation-page .night-hello-compose {
    background: rgba(23,23,25,.9);
    box-shadow: 0 16px 40px rgba(0,0,0,.42);
  }

  .night-hello-conversation-page .night-hello-image-input,
  .night-hello-conversation-page .night-hello-compose input[type="text"],
  .night-hello-conversation-page .night-hello-compose .primary {
    height: 42px;
    min-height: 42px;
    margin: 0;
    box-sizing: border-box;
  }

  .night-hello-conversation-page .night-hello-image-input {
    width: 40px;
  }

  .night-hello-conversation-page .night-hello-compose input[type="text"] {
    width: 100%;
    padding: 0 15px;
    line-height: 42px;
  }

  .night-hello-conversation-page .night-hello-compose .primary {
    display: grid;
    width: 60px;
    min-width: 60px;
    place-items: center;
    padding: 0;
    border-radius: 999px;
    line-height: 1;
  }

  .night-hello-message {
    max-width: 86%;
  }

  .night-hello-bell {
    width: 36px;
  }
}

