/* Parcours & guide messagerie OkDak */

.page-messages .msg-studio[hidden] {
  display: none !important;
}

.page-messages .msg-studio {
  flex: 0 0 auto;
  margin: 0;
  padding: 0.65rem 0.85rem 0.55rem;
  border-bottom: 0.5px solid rgba(84, 84, 88, 0.48);
  background: rgba(28, 28, 30, 0.98);
}

.page-messages .msg-studio__head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.45rem;
}

.page-messages .msg-studio__title {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.02em;
}

.page-messages .msg-studio__hint {
  margin: 0.15rem 0 0;
  font-size: 0.72rem;
  color: rgba(235, 235, 245, 0.55);
  line-height: 1.4;
}

.page-messages .msg-studio__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
}

.page-messages .msg-onboarding-reopen,
.page-messages .msg-intro-reopen,
.page-messages .msg-nav__guide {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.3rem 0.55rem;
  border-radius: 999px;
  border: 1px solid rgba(10, 132, 255, 0.45);
  background: rgba(10, 132, 255, 0.14);
  color: #64b5ff;
  font-size: 0.7rem;
  font-weight: 600;
  cursor: pointer;
}

.page-messages .msg-onboarding-reopen {
  border-color: rgba(48, 209, 88, 0.4);
  background: rgba(48, 209, 88, 0.12);
  color: #9edfb5;
}

.page-messages .msg-intro-reopen {
  border-color: rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.65);
}

.page-messages .msg-status {
  font-size: 0.68rem;
  font-weight: 600;
  padding: 0.25rem 0.55rem;
  border-radius: 999px;
  background: rgba(255, 159, 10, 0.15);
  color: #ffc46b;
  border: 1px solid rgba(255, 159, 10, 0.25);
}

.page-messages .msg-status.is-complete {
  background: rgba(48, 209, 88, 0.15);
  color: #7ddea0;
  border-color: rgba(48, 209, 88, 0.3);
}

.page-messages .msg-progress {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.4rem;
}

.page-messages .msg-progress__track {
  flex: 1;
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.page-messages .msg-progress__fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #0a84ff, #5e5ce6);
  transition: width 0.45s ease;
}

.page-messages .msg-progress__pct {
  font-size: 0.65rem;
  font-weight: 700;
  color: #64b5ff;
  min-width: 2.2rem;
  text-align: right;
}

.page-messages .msg-flow {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  list-style: none;
  margin: 0 0 0.45rem;
  padding: 0;
}

.page-messages .msg-flow__step {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.28rem 0.55rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.25);
  font-size: 0.68rem;
  color: rgba(235, 235, 245, 0.7);
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}

.page-messages .msg-flow__step.is-active {
  border-color: rgba(10, 132, 255, 0.55);
  background: rgba(10, 132, 255, 0.18);
  color: #fff;
}

.page-messages .msg-flow__step.is-done {
  border-color: rgba(48, 209, 88, 0.35);
}

.page-messages .msg-flow__step.is-tour-focus {
  box-shadow: 0 0 0 2px rgba(10, 132, 255, 0.45);
}

.page-messages .msg-flow__num {
  width: 1rem;
  height: 1rem;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.6rem;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.1);
}

.page-messages .msg-nav-shell {
  margin-bottom: 0.35rem;
}

.page-messages .msg-nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.page-messages .msg-nav__context {
  margin: 0;
  font-size: 0.68rem;
  color: rgba(235, 235, 245, 0.48);
  flex: 1 1 auto;
  min-width: 0;
}

.page-messages .msg-quick-start {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.45rem 0.55rem;
  border-radius: 10px;
  background: rgba(10, 132, 255, 0.1);
  border: 1px solid rgba(10, 132, 255, 0.22);
  margin-bottom: 0.35rem;
}

.page-messages .msg-quick-start[hidden] {
  display: none !important;
}

.page-messages .msg-quick-start__text {
  font-size: 0.72rem;
  color: rgba(235, 235, 245, 0.75);
  line-height: 1.4;
}

.page-messages .msg-quick-start__text strong {
  display: block;
  color: #fff;
  margin-bottom: 0.1rem;
}

.page-messages .msg-quick-start__btn {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.35rem 0.65rem;
  border-radius: 8px;
  border: none;
  background: #0a84ff;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
}

.page-messages .msg-success-banner {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.4rem 0.55rem;
  border-radius: 10px;
  background: rgba(48, 209, 88, 0.12);
  border: 1px solid rgba(48, 209, 88, 0.28);
  font-size: 0.72rem;
  color: #b8f0c8;
}

.page-messages .msg-success-banner[hidden] {
  display: none !important;
}

.page-messages .msg-success-banner__close {
  margin-left: auto;
  background: none;
  border: none;
  color: inherit;
  font-size: 1rem;
  cursor: pointer;
  opacity: 0.8;
}

body.messages-app.page-messages #tab-conversations .conversations-list-wrap {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
}

.page-messages .conversations-list-wrap {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
}

.page-messages #conversationList {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
}

.page-messages .msg-tour-demo-convo {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  text-align: left;
  padding: 10px 12px;
  margin: 0;
  border: none;
  border-top: 0.5px solid rgba(84, 84, 88, 0.35);
  background: rgba(10, 132, 255, 0.08);
  color: inherit;
  cursor: default;
  position: relative;
}

.page-messages .msg-tour-demo-convo[hidden] {
  display: none !important;
}

.page-messages .msg-tour-demo-convo__badge {
  position: absolute;
  top: 6px;
  right: 8px;
  font-size: 0.58rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #64b5ff;
  opacity: 0.9;
}

.page-messages .msg-tour-target-pulse {
  animation: msg-pulse 1.2s ease infinite;
}

@keyframes msg-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(10, 132, 255, 0.5); }
  50% { box-shadow: 0 0 0 8px rgba(10, 132, 255, 0); }
}

/* Onboarding modal */
body.page-messages.msg-onboarding-open {
  overflow: hidden;
}

.page-messages .msg-onboarding {
  position: fixed;
  inset: 0;
  z-index: 12000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.page-messages .msg-onboarding[hidden] {
  display: none !important;
}

.page-messages .msg-onboarding__backdrop {
  position: absolute;
  inset: 0;
  border: none;
  background: rgba(0, 0, 0, 0.72);
  cursor: pointer;
}

.page-messages .msg-onboarding__card {
  position: relative;
  z-index: 1;
  width: min(26rem, 100%);
  max-height: min(90vh, 640px);
  overflow: auto;
  padding: 1.1rem;
  border-radius: 16px;
  border: 1px solid rgba(10, 132, 255, 0.35);
  background: rgba(28, 28, 30, 0.98);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
}

.page-messages .msg-onboarding__head {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
}

.page-messages .msg-onboarding__kicker {
  margin: 0 0 0.2rem;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #64b5ff;
}

.page-messages .msg-onboarding__title {
  margin: 0 0 0.25rem;
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
}

.page-messages .msg-onboarding__lead {
  margin: 0;
  font-size: 0.82rem;
  color: rgba(235, 235, 245, 0.6);
  line-height: 1.45;
}

.page-messages .msg-onboarding__badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.5rem;
  padding: 0.25rem 0.55rem;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 600;
  color: #64b5ff;
  background: rgba(10, 132, 255, 0.12);
  border: 1px solid rgba(10, 132, 255, 0.25);
}

.page-messages .msg-onboarding__close {
  flex-shrink: 0;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  cursor: pointer;
}

.page-messages .msg-onboarding__steps {
  list-style: none;
  margin: 0 0 0.85rem;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.page-messages .msg-onboarding__steps li {
  display: flex;
  gap: 0.65rem;
  align-items: flex-start;
  padding: 0.55rem 0.65rem;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.page-messages .msg-onboarding__steps strong {
  display: block;
  font-size: 0.85rem;
  color: #fff;
  margin-bottom: 0.1rem;
}

.page-messages .msg-onboarding__steps p {
  margin: 0;
  font-size: 0.75rem;
  color: rgba(235, 235, 245, 0.55);
  line-height: 1.4;
}

.page-messages .msg-onboarding__icon {
  flex-shrink: 0;
  width: 2rem;
  height: 2rem;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.page-messages .msg-onboarding__icon--discover { background: rgba(10, 132, 255, 0.22); color: #64b5ff; }
.page-messages .msg-onboarding__icon--write { background: rgba(48, 209, 88, 0.18); color: #7ddea0; }
.page-messages .msg-onboarding__icon--search { background: rgba(255, 159, 10, 0.18); color: #ffc46b; }
.page-messages .msg-onboarding__icon--call { background: rgba(94, 92, 230, 0.22); color: #a5a3ff; }

.page-messages .msg-onboarding__foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  padding-top: 0.65rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.page-messages .msg-onboarding__skip {
  font-size: 0.72rem;
  color: rgba(235, 235, 245, 0.55);
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.page-messages .msg-onboarding__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-left: auto;
}

.page-messages .msg-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.45rem 0.75rem;
  border-radius: 8px;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
}

.page-messages .msg-btn--ghost {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.1);
  color: rgba(235, 235, 245, 0.85);
}

.page-messages .msg-btn--primary {
  background: #0a84ff;
  color: #fff;
}

/* Tour spotlight */
body.page-messages.msg-tour-open {
  overflow: hidden;
}

.page-messages .msg-tour {
  position: fixed;
  inset: 0;
  z-index: 12500;
  pointer-events: none;
}

.page-messages .msg-tour[hidden] {
  display: none !important;
}

.page-messages .msg-tour__highlight {
  position: fixed;
  border-radius: 10px;
  border: 2px solid #0a84ff;
  box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.68), 0 0 24px rgba(10, 132, 255, 0.35);
  transition: top 0.35s ease, left 0.35s ease, width 0.35s ease, height 0.35s ease;
  pointer-events: none;
  z-index: 1;
}

.page-messages .msg-tour__card {
  position: fixed;
  z-index: 2;
  width: min(22rem, calc(100vw - 24px));
  padding: 1rem 1.1rem;
  border-radius: 14px;
  border: 1px solid rgba(10, 132, 255, 0.4);
  background: rgba(28, 28, 30, 0.98);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
  pointer-events: auto;
}

.page-messages .msg-tour__progress {
  display: flex;
  gap: 0.35rem;
  margin-bottom: 0.55rem;
}

.page-messages .msg-tour__head {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  margin-bottom: 0.45rem;
}

.page-messages .msg-tour__icon {
  width: 2.1rem;
  height: 2.1rem;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: rgba(10, 132, 255, 0.15);
  color: #64b5ff;
}

.page-messages .msg-tour__dot {
  width: 0.5rem;
  height: 0.5rem;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  cursor: pointer;
  transition: transform 0.15s, background 0.15s;
}

.page-messages .msg-tour__dot.is-active {
  background: #0a84ff;
  transform: scale(1.2);
}

.page-messages .msg-tour__dot.is-done {
  background: rgba(48, 209, 88, 0.7);
}

.page-messages .msg-tour__kicker {
  margin: 0 0 0.15rem;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #64b5ff;
}

.page-messages .msg-tour__title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
}

.page-messages .msg-tour__text {
  margin: 0 0 0.5rem;
  font-size: 0.85rem;
  line-height: 1.5;
  color: rgba(235, 235, 245, 0.88);
}

.page-messages .msg-tour__text .msg-tour__ctx {
  display: block;
  margin-top: 0.45rem;
  font-size: 0.75rem;
  color: #7ddea0;
  font-style: normal;
}

.page-messages .msg-tour__keys {
  margin: 0 0 0.5rem;
  font-size: 0.68rem;
  color: rgba(180, 190, 220, 0.65);
  text-align: center;
}

.page-messages .msg-tour__keys kbd {
  display: inline-block;
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
  font-size: 0.65rem;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.page-messages .msg-tour__hint {
  margin: 0 0 0.65rem;
  padding: 0.45rem 0.55rem;
  border-radius: 8px;
  font-size: 0.75rem;
  color: #ffc46b;
  background: rgba(255, 159, 10, 0.12);
  border: 1px solid rgba(255, 159, 10, 0.22);
}

.page-messages .msg-tour__hint[hidden] {
  display: none !important;
}

.page-messages .msg-tour__action-btn {
  width: 100%;
  margin-bottom: 0.65rem;
  padding: 0.5rem;
  border-radius: 8px;
  border: 1px solid rgba(10, 132, 255, 0.45);
  background: rgba(10, 132, 255, 0.2);
  color: #dce8ff;
  font-weight: 600;
  font-size: 0.82rem;
  cursor: pointer;
}

.page-messages .msg-tour__action-btn[hidden] {
  display: none !important;
}

.page-messages .msg-tour__actions {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.page-messages .msg-tour__skip {
  align-self: center;
  background: none;
  border: none;
  color: rgba(180, 190, 220, 0.7);
  font-size: 0.78rem;
  cursor: pointer;
  text-decoration: underline;
}

.page-messages .msg-tour__nav {
  display: flex;
  gap: 0.5rem;
  justify-content: flex-end;
}

@media (max-width: 768px) {
  .page-messages .msg-studio__hint {
    display: none;
  }

  .page-messages .msg-flow__label {
    display: none;
  }

  .page-messages .msg-quick-start__text span {
    display: none;
  }
}

@media (min-width: 900px) {
  .page-messages .msg-studio {
    padding: 0.75rem 1rem;
  }
}
