
.messages-icon {
  background: linear-gradient(145deg, #304436, #182c21);
  color: #c3e9ac;
  border-color: #a6d48a45;
}
.contacts-icon {
  background: linear-gradient(145deg, #293537, #1a2329);
  color: #a5bfc9;
}
.app-icon {
  position: relative;
}
.unread-badge {
  position: absolute;
  right: -5px;
  top: -5px;
  background: #c9e6ae;
  color: #162512;
  border: 2px solid #10191b;
  border-radius: 20px;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  font: 9px/13px monospace;
  z-index: 1;
}
.widgets {
  margin-bottom: 12px;
}
.widgets .widget {
  min-height: 109px;
  padding: 13px 15px;
}
.calendar-num {
  font-size: 40px;
}
.heab-widget strong {
  font-size: 17px;
  margin-top: 13px;
}
.terminal-strip {
  height: 46px;
  margin-bottom: 19px;
}
.apps {
  gap: 17px 14px;
}
.apps .app-icon {
  height: 54px;
  width: 54px;
}
.workspace-foot {
  margin-top: 19px;
}
.chat-copy {
  font-size: 12px;
  line-height: 1.9;
  color: #9cae9f;
  margin: 8px 0 20px;
}
.chat-eyebrow {
  font: 8px/1.5 monospace;
  letter-spacing: 0.14em;
  color: #95ac83;
  text-transform: uppercase;
}
.chat-actions {
  display: flex;
  gap: 9px;
  align-items: center;
  flex-wrap: wrap;
  margin: 15px 0;
}
.chat-btn {
  background: #263b2a;
  color: #d8ecc5;
  border: 1px solid #b8d59d38;
  border-radius: 10px;
  padding: 10px 13px;
  font: 10px/1.5 monospace;
}
.chat-btn.secondary {
  background: #182326;
  color: #adbbb1;
  border-color: #ffffff17;
}
.chat-btn:disabled {
  opacity: 0.5;
  cursor: wait;
}
.chat-btn.danger {
  color: #dfa799;
  border-color: #dfa79933;
  background: #39251e55;
}
.chat-error {
  padding: 11px 13px;
  border: 1px solid #dfac8d45;
  border-radius: 10px;
  background: #b8663010;
  color: #ebc6ad;
  font: 10px/1.7 monospace;
  white-space: pre-wrap;
  margin: 10px 0;
}
.chat-error:empty {
  display: none;
}
.chat-search,
.chat-input {
  width: 100%;
  border: 1px solid #91a38933;
  background: #0a1215;
  color: #dce6d6;
  border-radius: 10px;
  padding: 12px 13px;
  font: 12px/1.5 Arial;
  margin: 7px 0 12px;
  outline-offset: 2px;
}
.chat-input::placeholder,
.chat-search::placeholder {
  color: #536b5c;
}
.chat-form label {
  font: 9px/1.7 monospace;
  letter-spacing: 0.05em;
  color: #8aa18b;
  display: block;
  margin-top: 9px;
}
.chat-form textarea {
  min-height: 90px;
  resize: vertical;
}
.chat-form h3 {
  font-size: 29px;
}
.chat-empty {
  border: 1px dashed #cbe5a32a;
  border-radius: 15px;
  padding: 25px 20px;
  margin: 20px 0;
  text-align: center;
  color: #849781;
  font-size: 12px;
  line-height: 1.9;
}
.thread-list {
  margin-top: 20px;
  border-block: 1px solid #ffffff0f;
}
.thread-item {
  display: flex;
  width: 100%;
  text-align: left;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid #ffffff0d;
  padding: 17px 0;
  background: none;
}
.thread-item:last-child {
  border: 0;
}
.thread-avatar {
  height: 38px;
  width: 38px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  background: #26352a;
  color: #bdd4ac;
  border: 1px solid #cbe5a325;
  border-radius: 12px;
  font-size: 15px;
}
.thread-main {
  flex: 1;
  min-width: 0;
}
.thread-main strong {
  display: block;
  color: #cfdfc8;
  font-size: 13px;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.thread-main p {
  font-size: 10px !important;
  line-height: 1.5 !important;
  color: #7b9381 !important;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  margin: 6px 0 0;
}
.thread-meta {
  font: 8px monospace;
  color: #718a75;
  display: flex;
  flex-direction: column;
  align-items: end;
  gap: 8px;
}
.thread-unread {
  display: grid;
  place-items: center;
  background: #b8d79c;
  color: #172311;
  border-radius: 50%;
  height: 16px;
  min-width: 16px;
  font: 9px monospace;
  padding: 2px;
}
.chat-shell {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
}
.app-content:has(.chat-shell) {
  padding: 0 17px 16px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.messaging-root:has(.chat-shell) {
  height: 100%;
  flex: 1;
  min-height: 0;
}
.chat-top {
  padding: 15px 0 13px;
  border-bottom: 1px solid #ffffff12;
  display: flex;
  gap: 10px;
  align-items: center;
  flex-shrink: 0;
}
.chat-back {
  height: 30px;
  width: 27px;
  color: #c2d7b4;
  background: none;
  font-size: 20px;
}
.chat-person {
  flex: 1;
  min-width: 0;
}
.chat-person strong {
  display: block;
  font-size: 14px;
  font-weight: 500;
  color: #d8e8d0;
}
.chat-person small {
  display: block;
  font: 8px/1.6 monospace;
  color: #7e9680;
  margin-top: 4px;
}
.chat-top .chat-btn {
  font-size: 8px;
  padding: 7px 8px;
}
.chat-status {
  font: 8px/1.7 monospace;
  color: #799573;
  min-height: 23px;
  padding: 7px 0 3px;
  flex-shrink: 0;
}
.message-list {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 10px 0;
  scrollbar-width: thin;
  scrollbar-color: #374d3b transparent;
  display: flex;
  flex-direction: column;
  gap: 12px;
  overscroll-behavior: contain;
}
.message-line {
  display: flex;
  flex-direction: column;
  align-items: start;
  max-width: 87%;
  align-self: start;
  animation: bubbleEnter 0.25s ease-out;
}
.message-line.mine {
  align-self: end;
  align-items: end;
}
.bubble {
  background: #1b282b;
  border: 1px solid #ffffff0c;
  border-radius: 13px 13px 13px 3px;
  color: #c5d4ca;
  padding: 11px 13px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font: 12px/1.75 Arial;
}
.mine .bubble {
  background: #2d442c;
  border-color: #b9d89419;
  color: #e2efda;
  border-radius: 13px 13px 3px 13px;
}
.message-line time {
  font: 7px/1.5 monospace;
  color: #687e6e;
  margin-top: 4px;
}
.message-start {
  font: 9px/1.8 monospace;
  text-align: center;
  color: #627d68;
  padding: 18px 10px;
}
.load-older {
  align-self: center;
  background: none;
  color: #a3bf94;
  font: 9px monospace;
  padding: 12px;
}
.composer {
  display: flex;
  align-items: end;
  gap: 8px;
  border-top: 1px solid #ffffff17;
  padding-top: 11px;
  margin-top: 5px;
  flex-shrink: 0;
}
.composer textarea {
  flex: 1;
  min-width: 0;
  min-height: 42px;
  max-height: 96px;
  resize: none;
  border: 1px solid #b9d79520;
  background: #111e20;
  color: #e1efda;
  border-radius: 11px;
  padding: 11px 12px;
  font: 12px/1.5 Arial;
}
.composer button {
  height: 42px;
  width: 43px;
  flex-shrink: 0;
  border: 1px solid #cbe5a337;
  border-radius: 11px;
  background: #c1df9f;
  color: #142613;
  font-size: 20px;
}
.composer button:disabled {
  opacity: 0.5;
  cursor: wait;
}
.chat-footer {
  font: 7px/1.6 monospace;
  color: #526e58;
  margin-top: 8px;
}
.contact-count {
  font: 9px monospace;
  color: #7c9779;
  margin-top: -4px;
}
.contact-list {
  margin-top: 16px;
}
.contact-row {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  background: none;
  text-align: left;
  border-bottom: 1px solid #ffffff10;
  padding: 15px 0;
}
.contact-row strong {
  font-size: 13px;
  color: #c6d9bf;
  font-weight: 500;
}
.contact-row small {
  display: block;
  font: 9px/1.8 monospace;
  color: #789177;
  margin-top: 3px;
}
.contact-detail-title {
  font-size: 30px !important;
  overflow-wrap: anywhere;
}
.contact-field {
  padding: 15px 0;
  border-bottom: 1px solid #ffffff0d;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: 12px;
  color: #b1c6a8;
  line-height: 1.8;
}
.contact-field span {
  display: block;
  font: 8px/1.8 monospace;
  letter-spacing: 0.1em;
  color: #718d70;
  text-transform: uppercase;
  margin-bottom: 5px;
}
.private-label {
  font: 8px/1.7 monospace;
  color: #8dac7a;
  border: 1px solid #cbe5a326;
  border-radius: 20px;
  padding: 6px 10px;
  display: inline-block;
}
.messages-root-heading {
  font-size: 32px !important;
  margin-top: 14px !important;
}
.message-preview-note {
  border: 1px solid #cbe5a320;
  background: #cbe5a307;
  padding: 11px;
  font: 9px/1.7 monospace;
  color: #b2c7a5;
  border-radius: 10px;
  margin: 10px 0;
}
@keyframes bubbleEnter {
  from {
    opacity: 0;
    transform: translateY(7px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@media (max-height: 760px) {
  .home {
    padding-bottom: 145px;
  }
  .widgets .widget {
    min-height: 94px;
    padding: 11px 13px;
  }
  .calendar-num {
    font-size: 35px;
  }
  .heab-widget strong {
    font-size: 15px;
    margin-top: 9px;
  }
  .apps {
    gap: 13px 12px;
  }
  .apps .app-icon {
    height: 48px;
    width: 48px;
  }
  .terminal-strip {
    height: 39px;
    margin-bottom: 15px;
  }
  .workspace-foot {
    font-size: 6px;
    margin-top: 15px;
  }
}
@media (max-height: 690px) {
  .terminal-strip {
    display: none;
  }
  .workspace-foot {
    display: none;
  }
  .widgets {
    margin-bottom: 19px;
  }
  .home .workspace-title {
    margin-bottom: 17px;
  }
  .apps {
    gap: 13px 12px;
  }
  .apps .app-icon {
    height: 47px;
    width: 47px;
  }
  .chat-top .chat-btn {
    padding: 6px;
  }
  .chat-footer {
    display: none;
  }
}

@media (max-width: 480px) {
  .device {
    height: var(--phone-viewport, 100svh);
  }
  .app-content:has(.chat-shell) {
    padding-bottom: max(16px, env(safe-area-inset-bottom));
  }
}
#contacts-root:has(.contact-message) {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-height: 100%;
}

.contact-message {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  margin-top: auto;
}