/*Write your custom css in this file.*/

/* =============================================================
   Klienz Loader — animated circular ring around the K icon.
   Used as the full-page pre-loader and as the inline loader for
   .app-loader, .table-loader, and .form-group .app-loader.
   ============================================================= */
#pre-loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: #fff9f6;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
}
.klienz-loader {
  position: relative;
  width: 100px;
  height: 100px;
}
.klienz-loader-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 50px;
  height: 50px;
  border-radius: 12px;
  z-index: 2;
}
.klienz-loader-ring {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 4px solid transparent;
  border-top-color: #019AF8;
  border-right-color: #03cff4;
  border-bottom-color: #db8d2e;
  border-left-color: #a22749;
  animation: klienz-spin 1s linear infinite;
  box-shadow:
    0 0 15px rgba(1, 154, 248, 0.3),
    0 0 15px rgba(219, 141, 46, 0.3) inset;
}
.klienz-loader-ring::before {
  content: '';
  position: absolute;
  top: -4px;
  left: -4px;
  right: -4px;
  bottom: -4px;
  border-radius: 50%;
  border: 3px solid transparent;
  border-top-color: #152c5b;
  border-bottom-color: #03cff4;
  animation: klienz-spin 1.5s linear reverse infinite;
  opacity: 0.6;
}
@keyframes klienz-spin {
  0%   { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Inline app-loader (modals, ajax containers) */
.app-loader .loading { display: none; }
.app-loader .klienz-loader { width: 70px; height: 70px; }
.app-loader .klienz-loader .klienz-loader-ring { width: 70px; height: 70px; }

/* Table loader (datatables empty state during fetch) */
.table-loader .loading { display: none; }
.table-loader .klienz-loader { width: 50px; height: 50px; margin: 0 auto; }
.table-loader .klienz-loader .klienz-loader-ring { width: 50px; height: 50px; }

/* Form-group inline loader (validation/submit spinners) */
.form-group .app-loader .klienz-loader { width: 40px; height: 40px; }
.form-group .app-loader .klienz-loader .klienz-loader-ring {
  width: 40px;
  height: 40px;
  border-width: 3px;
}
.form-group .app-loader .klienz-loader .klienz-loader-ring::before { border-width: 2px; }

/* =============================================================
   Sidebar: hide every unread-count badge inside the left menu.
   Counts now live exclusively in the floating notifications panel
   (right edge of the screen) so the sidebar stays clean.
   ============================================================= */
#sidebar-menu .badge { display: none !important; }

/* =============================================================
   Sidebar active state — replaces the stock #6690F4 blue block
   with a warm orange gradient (parent) + subtle left-bar accent
   (submenu) so both states are visible without competing.
   ============================================================= */
/* Parent / top-level item active (e.g. "Ventas" when on /invoices) */
#sidebar-menu > li.active > a,
#sidebar-menu > li.main.active > a {
    background: linear-gradient(90deg, #ff9a3c 0%, #ff6b35 100%) !important;
    color: #ffffff !important;
    box-shadow: 0 2px 10px rgba(255, 107, 53, 0.35);
}
/* Submenu leaf active (e.g. "Facturas" within "Ventas") — lighter,
   with a left orange bar instead of a full block so the parent's
   block stays the dominant indicator. */
#sidebar-menu li.expand > ul > li.active > a {
    background: rgba(255, 154, 60, 0.12) !important;
    color: #ff6b35 !important;
    border-left: 3px solid #ff6b35;
    padding-left: calc(2rem - 3px);
    font-weight: 600;
}
/* Dark theme tuning */
html.klz-dark #sidebar-menu li.expand > ul > li.active > a {
    background: rgba(255, 154, 60, 0.18) !important;
    color: #ffb874 !important;
    border-left-color: #ffb874;
}

/* =============================================================
   Floating notifications button (Vuexy-style)
   Pinned to the right edge of the viewport, vertically centered.
   Replaces the navbar bell. Click → opens
   #js-floating-panel-notifications (handled by the script in
   includes/floating_notifications_button.php).
   ============================================================= */
.klz-floating-notif-btn {
    position: fixed;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    border: none;
    background: #7367f0;
    color: #fff;
    border-radius: 10px 0 0 10px;
    box-shadow: -3px 4px 14px rgba(115, 103, 240, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 1040;
    transition: width 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}
.klz-floating-notif-btn:hover {
    width: 50px;
    box-shadow: -3px 4px 18px rgba(115, 103, 240, 0.5);
}
.klz-floating-notif-btn:active { transform: translateY(-50%) scale(0.96); }
.klz-floating-notif-btn img {
    width: 22px;
    height: 22px;
    /* CSS mask: silhouette the bell.svg and fill it with a theme-aware
       light-orange. The mask URL is set inline on the element via
       `style="--klz-bell-mask: url(...)"` so this rule stays portable
       even if the SVG path changes. */
    background-color: #ffb74d;
    -webkit-mask-image: var(--klz-bell-mask, none);
    mask-image: var(--klz-bell-mask, none);
    -webkit-mask-size: contain;
    mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
}
html.klz-dark .klz-floating-notif-btn img { background-color: #ffcc80; }

/* Inline klienz-loader used by the notifications drawer body. Sits
   centered with breathing room, slightly smaller than the full-page
   pre-loader. Overrides .app-loader's default absolute bottom-right
   positioning so the K appears in the middle of the drawer body. */
.klz-notif-inline-loader.app-loader,
.klz-notif-inline-loader {
    position: static !important;
    width: 100% !important;
    height: 100% !important;
    min-height: 300px;
    bottom: auto !important;
    right: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    background: transparent;
}
/* Make the drawer body itself a flex container so the loader can fill
   it vertically. Notifications list rendering keeps its own flow once
   loaded (block content overrides this naturally). */
.klz-notif-drawer .floating-notifications-body:has(.klz-notif-inline-loader) {
    display: flex;
}
.klz-notif-inline-loader .klienz-loader { width: 64px; height: 64px; }
.klz-notif-inline-loader .klienz-loader-ring { width: 64px; height: 64px; border-width: 3px; }
.klz-notif-inline-loader .klienz-loader-icon { width: 32px; height: 32px; }
.klz-floating-notif-badge {
    position: absolute;
    top: -6px;
    left: -8px;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    background: #ea5455;
    color: #fff;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    line-height: 20px;
    text-align: center;
    box-shadow: 0 0 0 2px #fff;
    display: none;
}
.klz-floating-notif-badge.show { display: inline-block; }
html.klz-dark .klz-floating-notif-badge { box-shadow: 0 0 0 2px #1e202d; }

/* Hide the floating trigger button while the drawer is open. */
body.klz-notif-drawer-open .klz-floating-notif-btn { display: none; }

/* =============================================================
   Vuexy-style notifications DRAWER — slides in from the right edge,
   full viewport height, fixed width. Closes via ✕ button, backdrop
   click, or Escape key.
   ============================================================= */
.klz-notif-drawer {
    position: fixed;
    top: 0;
    right: 0;
    width: 400px;
    max-width: 100vw;
    height: 100vh;
    background: #ffffff;
    color: #2f2b3d;
    box-shadow: -8px 0 30px rgba(15, 18, 38, 0.18);
    z-index: 1060;
    display: flex;
    flex-direction: column;
    transform: translateX(0);
    transition: transform 0.28s cubic-bezier(.2,.8,.2,1);
}
.klz-notif-drawer.hidden { transform: translateX(100%); }
.klz-notif-drawer .floating-inbox-header,
.klz-notif-drawer-header {
    flex: 0 0 auto;
    padding: 16px 18px;
    border-bottom: 1px solid #e9ecef;
}
.klz-notif-drawer .dropdown-details,
.klz-notif-drawer .floating-notifications-body {
    flex: 1 1 auto;
    overflow-y: auto;
    background: #fbfbfd;
}
.klz-notif-drawer .floating-notifications-footer {
    flex: 0 0 auto;
    border-top: 1px solid #e9ecef;
    padding: 10px 0;
    background: #ffffff;
}

/* Dark theme — match the rest of the app (body #1c1f26, cards #252932) */
html.klz-dark .klz-notif-drawer {
    background: #1c1f26;
    color: #f7f7fb;
    box-shadow: -8px 0 30px rgba(0, 0, 0, 0.5);
}
html.klz-dark .klz-notif-drawer .floating-inbox-header,
html.klz-dark .klz-notif-drawer .floating-notifications-footer {
    border-color: #2f3541;
    background: #252932;
}
html.klz-dark .klz-notif-drawer .dropdown-details,
html.klz-dark .klz-notif-drawer .floating-notifications-body { background: #1c1f26; }
html.klz-dark .klz-notif-drawer .list-group-item {
    background: #252932;
    border-color: #2f3541;
    color: #d1d5db;
    margin-bottom: 4px;
}
html.klz-dark .klz-notif-drawer .list-group-item:hover {
    background: #2f3541;
}
html.klz-dark .klz-notif-drawer .list-group-item.unread-notification {
    background: #2a3045;
    border-left: 3px solid #6366f1;
}

/* Backdrop — translucent overlay behind the drawer */
.klz-notif-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 18, 38, 0.45);
    z-index: 1050;
    opacity: 1;
    transition: opacity 0.25s ease;
}
.klz-notif-backdrop.hidden {
    opacity: 0;
    pointer-events: none;
}

/* Narrow viewports — make the drawer take the full screen */
@media (max-width: 575px) {
    .klz-notif-drawer { width: 100vw; }
}

/* =============================================================
   Morning briefing modal — six compact cards with the user's
   actionable counts for the day. Opens once per login.
   ============================================================= */
.klz-briefing-modal { position: fixed; inset: 0; z-index: 1080; }
.klz-briefing-modal.hidden { display: none; }
body.klz-briefing-open { overflow: hidden; }

.klz-briefing-backdrop {
    position: absolute; inset: 0;
    background: rgba(15, 18, 38, 0.55);
    backdrop-filter: blur(2px);
}
.klz-briefing-dialog {
    position: relative;
    max-width: 720px;
    width: calc(100% - 32px);
    margin: 5vh auto;
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 30px 60px rgba(15, 18, 38, 0.4);
    padding: 28px 28px 20px;
    animation: klz-briefing-pop 0.3s cubic-bezier(.2,.8,.25,1);
}
@keyframes klz-briefing-pop {
    from { opacity: 0; transform: translateY(20px) scale(0.96); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}
.klz-briefing-close {
    position: absolute; top: 14px; right: 14px;
    width: 32px; height: 32px;
    border-radius: 50%;
    border: none; background: rgba(15, 18, 38, 0.06);
    font-size: 22px; line-height: 1; cursor: pointer;
    color: #2f2b3d;
}
.klz-briefing-close:hover { background: rgba(15, 18, 38, 0.12); }
.klz-briefing-header { padding-right: 40px; margin-bottom: 18px; }
.klz-briefing-greeting { font-size: 22px; font-weight: 700; margin: 0 0 4px; color: #2f2b3d; }
.klz-briefing-sub { margin: 0; font-size: 13px; color: #6e6b7b; }

.klz-briefing-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}
@media (max-width: 600px) {
    .klz-briefing-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .klz-briefing-dialog { padding: 20px; margin: 2vh auto; }
}
@media (max-width: 380px) {
    .klz-briefing-grid { grid-template-columns: 1fr; }
}

.klz-briefing-card {
    display: flex; align-items: center; gap: 12px;
    padding: 14px;
    border-radius: 12px;
    background: #f8f8fc;
    border: 1px solid transparent;
    text-decoration: none; color: inherit;
    transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}
.klz-briefing-card:hover {
    transform: translateY(-2px);
    border-color: rgba(115, 103, 240, 0.25);
    box-shadow: 0 6px 20px rgba(115, 103, 240, 0.15);
    text-decoration: none; color: inherit;
}
.klz-bc-icon {
    flex: 0 0 44px;
    width: 44px; height: 44px;
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    background: #eef0ff;
}
.klz-bc-icon img { width: 24px; height: 24px; }
.klz-bc-body { flex: 1 1 auto; min-width: 0; }
.klz-bc-count {
    font-size: 22px; font-weight: 700; line-height: 1;
    color: #2f2b3d; margin-bottom: 4px;
}
.klz-bc-label { font-size: 12px; font-weight: 600; color: #2f2b3d; line-height: 1.2; }
.klz-bc-sub { font-size: 11px; color: #6e6b7b; margin-top: 4px; line-height: 1.3; }

/* Pill-shaped sub-count chips — each chip is its own clickable link
   navigating to a filtered sub-view (vencidas, pedidos, etc.). */
.klz-bc-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 6px;
}
.klz-bc-chip {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 8px;
    border-radius: 999px;
    background: rgba(15, 18, 38, 0.06);
    color: #2f2b3d;
    font-size: 11px;
    font-weight: 500;
    text-decoration: none;
    transition: background 0.15s ease, transform 0.1s ease;
    white-space: nowrap;
    line-height: 1.4;
}
.klz-bc-chip:hover {
    background: rgba(115, 103, 240, 0.18);
    color: #2f2b3d;
    text-decoration: none;
    transform: translateY(-1px);
}
.klz-bc-chip b { font-weight: 700; color: inherit; }

html.klz-dark .klz-bc-chip { background: rgba(255, 255, 255, 0.08); color: #f7f7fb; }
html.klz-dark .klz-bc-chip:hover { background: rgba(115, 103, 240, 0.32); color: #f7f7fb; }

/* Highlighted chip for actions that need immediate review (e.g. pagos
   por verificar). Subtle orange tint so the eye lands here first. */
.klz-bc-chip.klz-chip-hot { background: rgba(255, 107, 53, 0.18); color: #c2410c; }
.klz-bc-chip.klz-chip-hot:hover { background: rgba(255, 107, 53, 0.32); color: #c2410c; }
html.klz-dark .klz-bc-chip.klz-chip-hot { background: rgba(255, 154, 60, 0.25); color: #ffb874; }
html.klz-dark .klz-bc-chip.klz-chip-hot:hover { background: rgba(255, 154, 60, 0.4); color: #ffb874; }

/* Category tints — keep them subtle */
.klz-bc-comm     .klz-bc-icon { background: rgba(34, 197, 94, 0.15); }
.klz-bc-sales    .klz-bc-icon { background: rgba(234, 179, 8, 0.18); }
.klz-bc-support  .klz-bc-icon { background: rgba(239, 68, 68, 0.15); }
.klz-bc-pipeline .klz-bc-icon { background: rgba(115, 103, 240, 0.18); }
.klz-bc-tasks    .klz-bc-icon { background: rgba(16, 185, 129, 0.15); }
.klz-bc-events   .klz-bc-icon { background: rgba(244, 114, 182, 0.18); }

.klz-briefing-footer {
    display: flex; justify-content: space-between; align-items: center;
    margin-top: 22px; padding-top: 16px;
    border-top: 1px solid #e9ecef;
}
.klz-briefing-skip { font-size: 12px; color: #6e6b7b; text-decoration: none; }
.klz-briefing-skip:hover { color: #2f2b3d; }
.klz-briefing-go { padding: 8px 22px; font-weight: 600; }

/* Dark mode */
html.klz-dark .klz-briefing-dialog { background: #222734; box-shadow: 0 30px 60px rgba(0, 0, 0, 0.65); }
html.klz-dark .klz-briefing-close { background: rgba(255, 255, 255, 0.08); color: #f7f7fb; }
html.klz-dark .klz-briefing-close:hover { background: rgba(255, 255, 255, 0.16); }
html.klz-dark .klz-briefing-greeting,
html.klz-dark .klz-bc-count,
html.klz-dark .klz-bc-label { color: #f7f7fb; }
html.klz-dark .klz-briefing-sub,
html.klz-dark .klz-bc-sub,
html.klz-dark .klz-briefing-skip { color: #9da4c0; }
html.klz-dark .klz-briefing-card { background: #1c202b; }
html.klz-dark .klz-briefing-card:hover { border-color: rgba(115, 103, 240, 0.45); }
html.klz-dark .klz-briefing-footer { border-color: rgba(255, 255, 255, 0.08); }

/* Sidebar brand: swap light/dark logo based on theme.
   RISE uses body[data-color="XXXXXX"] for theme color. The inline
   script in left_menu.php computes the luminance and adds .klz-dark
   to <html> when the active theme is dark, so this CSS can stay simple.
*/
.sidebar-brand.brand-logo .klz-logo-dark { display: none; }
html.klz-dark .sidebar-brand.brand-logo .klz-logo-light { display: none; }
html.klz-dark .sidebar-brand.brand-logo .klz-logo-dark  { display: inline-block; }

/* Same swap for the collapsed mini K icon (sidebar-toggled). */
.sidebar-brand.brand-logo-mini .klz-mini-dark { display: none; }
html.klz-dark .sidebar-brand.brand-logo-mini .klz-mini-light { display: none; }
html.klz-dark .sidebar-brand.brand-logo-mini .klz-mini-dark  { display: inline-block; }

/* =============================================================
   Klienz Chat Panel — floating chat-box opened from the navbar
   mail icon. These rules were originally inlined in app.all.css
   but were lost when we reverted to RISE original. Restored here
   so the panel renders as a 430px floating box (not full width).
   ============================================================= */
.klienz-chat-wrapper {
  width: 430px;
  height: calc(100% - 170px);
  background: #fff;
  z-index: 10;
  position: fixed;
  top: 86px;
  right: 20px;
  border-radius: 5px;
  box-shadow: rgba(0, 0, 0, 0.3) 0px 0px 30px 0px;
  animation: slideInRight 0.3s ease-in-out;
  /* Flex column: header (natural) + body (grow) + footer (natural) — elimina gap */
  display: flex;
  flex-direction: column;
}
.klienz-chat-wrapper > .klienz-chat-body {
  /* Absorbe el alto restante entre header y footer, sin importar el wrapper height */
  flex: 1 1 auto;
  min-height: 0;
}
.klienz-chat-wrapper > .klienz-chat-body.full-height {
  /* Override del height:413px fijo — flex-grow se encarga */
  height: auto;
}
.klienz-chat-wrapper > .klienz-chat-footer {
  /* Participa en el flex column — evita que se monte encima del body */
  position: relative;
  bottom: auto;
  flex: 0 0 auto;
}
.klienz-chat-wrapper.full-screen {
  width: auto !important;
  height: auto !important;
  top: 66px !important;
  right: 0 !important;
  bottom: 0 !important;
  left: 250px !important;
  z-index: 11;
}
.klienz-chat-wrapper .message-row {
  border-bottom: 1px solid #f1f1f5;
  cursor: pointer;
}
.klienz-chat-wrapper .message-row .time {
  font-size: 0.7em;
  width: 60px;
  text-align: right;
}
.klienz-chat-wrapper .message-row:hover {
  background: #f0f0f0;
}
.klienz-chat-wrapper .nav-tabs li .active, .klienz-chat-wrapper .nav-tabs li.active {
  border-bottom: none !important;
}
.klienz-chat-wrapper .chat-topbar,
.klienz-chat-wrapper .klienz-chat-header {
  height: 62px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid #f1f1f5;
  cursor: default;
}
.klienz-chat-wrapper .chat-topbar .chat-topbar-btn,
.klienz-chat-wrapper .klienz-chat-header .chat-topbar-btn {
  cursor: pointer;
  padding: 10px;
  position: absolute;
}
.klienz-chat-wrapper .chat-topbar .chat-topbar-btn.chat-back,
.klienz-chat-wrapper .klienz-chat-header .chat-topbar-btn.chat-back {
  left: 10px;
}
.klienz-chat-wrapper .chat-topbar .chat-topbar-btn.chat-close,
.klienz-chat-wrapper .klienz-chat-header .chat-topbar-btn.chat-close {
  right: 10px;
}
.klienz-chat-wrapper .chat-topbar .chat-topbar-btn.more-options,
.klienz-chat-wrapper .klienz-chat-header .chat-topbar-btn.more-options {
  right: 50px;
}

.klienz-chat-header {
  border-bottom: 1px solid #f1f1f5;
}
.klienz-chat-header .nav-tabs > li {
  display: table-cell;
  float: none;
  width: 100%;
}

.chat-tab {
  display: flex;
  justify-content: space-around;
}
.chat-tab .btn {
  transition: color 0.15s ease, background-color 0.15s ease, transform 0.08s ease;
}
.chat-tab .btn.active, .chat-tab .btn:hover, .chat-tab .btn:focus, .chat-tab .btn:active {
  background-color: transparent !important;
  color: #6690F4;
}
.chat-tab .btn:active {
  transform: scale(0.96);
}

.chat-title {
  text-align: center;
  padding: 15px 7px;
  font-weight: 700;
}

.chat-bars {
  width: 30px;
  text-align: center;
  cursor: pointer;
  opacity: 0.5;
}

.chat-back {
  opacity: 0.7;
  cursor: pointer;
  width: 40px;
  padding: 20px 10px;
}

.chat-bars:hover,
.chat-back:hover {
  opacity: 1;
}

.klienz-chat-body {
  height: auto;
  overflow-y: scroll;
  overflow-x: hidden;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}
.klienz-chat-body.full-height {
  height: 413px;
}
.klienz-chat-body.long {
  height: 412px;
}

.klienz-chat-footer {
  background: #fff;
  width: 100%;
  bottom: 0;
  position: absolute;
  border-top: 1px solid #f1f1f5;
  border-radius: 0 0 5px 5px;
}
.klienz-chat-footer.footer-buttons-section {
  box-shadow: rgba(9, 14, 21, 0.06) 0px 0px 25px 0px;
}
.klienz-chat-footer.footer-buttons-section .btn {
  padding: 15px !important;
}
.klienz-chat-footer .post-file-dropzone-scrollbar {
  margin-top: -90px;
}
.klienz-chat-footer textarea {
  width: 100%;
  padding: 15px;
  border: none;
  height: 52px;
  resize: none;
}
.klienz-chat-footer textarea:focus {
  outline: none;
}
.klienz-chat-footer .help-block {
  height: 0px;
  display: none !important;
}
.klienz-chat-footer .chat-message-textarea {
  display: flex;
}
.klienz-chat-footer .chat-button-section {
  padding: 4px;
  margin-top: -4px;
}
.klienz-chat-footer .chat-button-section .upload-file-button {
  margin-right: 5px !important;
}
.klienz-chat-footer .chat-button-section svg {
  width: 18px;
  height: 18px;
}
.klienz-chat-footer .stop-recording {
  display: inline-block;
  width: 11px;
  height: 11px;
}
.klienz-chat-footer .btn {
  padding: 8px 10px;
  margin: 0 !important;
  border: 0;
  text-align: center;
}
.klienz-chat-footer .recording-text {
  display: none;
}

.chat-msg {
  padding: 8px 10px;
  display: inline-block;
  max-width: 75%;
  text-align: left;
  word-break: break-word;
}
.chat-msg img {
  max-width: 100%;
}

.chat-other {
  padding: 2px 10px;
}
.chat-other .avatar {
  float: left;
  margin-top: 2px;
}
.chat-other .chat-msg {
  border-radius: 0 10px 10px 10px;
  background-color: #f0f0f0;
}
.chat-other.single-message {
  padding-bottom: 10px;
}
.chat-other.single-message .chat-msg {
  border-radius: 15px;
}
.chat-other.first-message .chat-msg {
  border-radius: 15px 15px 15px 2px;
}
.chat-other.first-message .avatar .avatar-link {
  display: none;
}
.chat-other.middle-message .chat-msg {
  border-radius: 2px 15px 15px 2px;
}
.chat-other.middle-message .avatar .avatar-link {
  display: none;
}
.chat-other.last-message {
  padding-bottom: 10px;
}
.chat-other.last-message .chat-msg {
  border-radius: 2px 15px 15px 15px;
}

.chat-me {
  text-align: right;
  padding-right: 10px;
  margin-top: 2px;
}
.chat-me:nth-last-of-type(1):not(:nth-last-child(1)) {
  padding-bottom: 10px;
}
.chat-me.single-message {
  padding-bottom: 10px;
}
.chat-me.single-message .chat-msg {
  border-radius: 15px;
}
.chat-me.first-message .chat-msg {
  border-radius: 15px 15px 2px 15px;
}
.chat-me.middle-message .chat-msg {
  border-radius: 15px 2px 2px 15px;
}
.chat-me.last-message {
  padding-bottom: 10px;
}
.chat-me.last-message .chat-msg {
  border-radius: 15px 2px 15px 15px;
}
.chat-me .chat-msg {
  border-radius: 15px 0 15px 15px;
  background-color: #6d81f5;
  color: #fff;
}
.chat-me .chat-msg a {
  color: #fff;
}

.init-chat-icon {
  width: 50px;
  height: 50px;
  background-color: #fff;
  z-index: 10;
  position: fixed;
  bottom: 20px;
  right: 20px;
  box-shadow: 0px 3px 4px 4px rgba(0, 0, 0, 0.1);
  border-radius: 50%;
  text-align: center;
  padding: 15px;
  cursor: pointer;
}
.init-chat-icon.has-message {
  background-color: #f5325c;
  color: #fff;
}

