* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
  background-color: #d1d7db;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
}

.app-container {
  display: flex;
  width: 90vw;
  height: 90vh;
  background-color: #fff;
  box-shadow: 0 1px 1px 0 rgba(0,0,0,.06), 0 2px 5px 0 rgba(0,0,0,.2);
}

.sidebar {
  width: 30%;
  border-right: 1px solid #ddd;
  display: flex;
  flex-direction: column;
}

.chat-area {
  width: 70%;
  display: flex;
  flex-direction: column;
  background-color: #efeae2;
}

header {
  height: 60px;
  background-color: #f0f2f5;
  display: flex;
  align-items: center;
  padding: 10px 16px;
}

.avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: #dfe5e7;
}

.header-sender-select {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}

#sender-select {
  padding: 4px 8px;
  border-radius: 4px;
  border: 1px solid #ccc;
  background: #fff;
  font-size: 14px;
  outline: none;
  cursor: pointer;
  max-width: 140px;
}

#add-sender-btn {
  background-color: #25D366;
  color: white;
  border: none;
  border-radius: 50%;
  width: 26px;
  height: 26px;
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.search-bar {
  padding: 10px;
  background-color: #fff;
  border-bottom: 1px solid #f2f2f2;
}

.search-bar input {
  width: 100%;
  padding: 8px 12px;
  border: none;
  border-radius: 8px;
  background-color: #f0f2f5;
  outline: none;
}

.contact-list {
  flex-grow: 1;
  overflow-y: auto;
}

.contact {
  display: flex;
  align-items: center;
  padding: 12px 16px;
  cursor: pointer;
}

.contact:hover, .contact.active {
  background-color: #f5f6f6;
}

.contact-info {
  margin-left: 15px;
  width: 100%;
  overflow: hidden;
}

.contact-info p {
  color: #667781;
  font-size: 13px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 2px;
}

.contact-info h4 {
  font-weight: 400;
  color: #111b21;
}

.chat-header-info {
  margin-left: 15px;
}

.messages-container {
  flex-grow: 1;
  padding: 20px 5%;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
  background-image: url('https://user-images.githubusercontent.com/15075759/28719144-86dc0f70-73b1-11e7-911d-60d70fcded21.png');
  background-color: #efeae2;
}

.message {
  max-width: 65%;
  padding: 6px 7px 8px 9px;
  border-radius: 7.5px;
  font-size: 14.2px;
  line-height: 19px;
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  box-shadow: 0 1px 0.5px rgba(11,20,26,.13);
}

.message-content {
  padding-right: 15px;
  word-wrap: break-word;
  max-width: 100%;
}

.timestamp {
  font-size: 11px;
  color: #667781;
  margin-left: auto;
  white-space: nowrap;
  line-height: 15px;
}

.message.sent {
  align-self: flex-end;
  background-color: #d9fdd3;
  border-top-right-radius: 0;
}

.message.received {
  align-self: flex-start;
  background-color: #fff;
  border-top-left-radius: 0;
}

.chat-footer {
  height: 62px;
  background-color: #f0f2f5;
  display: flex;
  align-items: center;
  padding: 10px 16px;
  gap: 10px;
}

.chat-footer input[type="text"] {
  flex-grow: 1;
  padding: 10px;
  border: none;
  border-radius: 8px;
  outline: none;
  font-size: 15px;
}

.icon-btn {
  background: none;
  border: none;
  font-size: 20px;
  cursor: pointer;
  color: #54656f;
  padding: 5px;
}

.splash-screen {
  width: 70%;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: #f8f9fa;
  border-bottom: 6px solid #25D366;
}

.splash-content {
  text-align: center;
  color: #41525d;
}

.splash-content h2 {
  font-weight: 300;
  font-size: 32px;
  margin-bottom: 16px;
}

.splash-content p {
  font-size: 14px;
  color: #667781;
}
