body {
  background: black;
}

.card {
  background: #1e1e1e;
  box-shadow: 0 0 20px rgba(0, 255, 255, 0.05), 0 0 60px rgba(0, 255, 255, 0.02);
}

.full-wrapper {
  display: flex;
  flex-direction: column;
  height: 99.6vh;
}

.card-body {
  flex-grow: 1;
  overflow-y: auto;

  /* Firefox scrollbar */
  scrollbar-width: thin;
  scrollbar-color: #00f5d4 #ffffff00;

  /* Futuristic glass background */
  background: rgba(20, 20, 30, 0.6);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.1);

  /* Subtle neon glow */
  box-shadow: 0 0 20px rgba(0, 255, 200, 0.3), 0 0 40px rgba(0, 200, 255, 0.15),
    inset 0 0 10px rgba(0, 255, 200, 0.05);

  /* Smooth scroll */
  scroll-behavior: smooth;
}

/* WebKit-based browsers scrollbar */
.card-body::-webkit-scrollbar {
  width: 10px;
}

.card-body::-webkit-scrollbar-track {
  background: rgba(15, 15, 25, 0.8);
  border-radius: 6px;
}

.card-body::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #00f5d4, #00bbf9);
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0, 255, 200, 0.6);
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

.card-body::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #00bbf9, #4361ee);
  box-shadow: 0 0 15px rgba(0, 187, 249, 0.8);
}

@media (max-width: 480px) {
  .card-header {
    padding: 10px;
  }
  .fw-medium {
    font-size: 0.9rem;
  }
  .fs-small {
    font-size: 0.75rem;
  }
  .input {
    padding: 8px;
  }
  #send-btn {
    padding: 8px 12px;
  }
}

/* Chat conversation */
#chat-conversation {
  flex: 1 1 auto;
  overflow-y: auto;
}

img {
  box-shadow: 0 0 20px rgba(0, 255, 255, 0.2);
}

.input {
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(8px);
  border-radius: 14px;
  padding: 10px 16px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 0 10px rgba(0, 255, 255, 0.2);
  animation: glowPulse 3s ease-in-out infinite;
  transition: transform 0.2s ease;
}

.input::placeholder {
  color: rgb(245, 245, 245);
}

.form-check-input:checked {
  background-color: #000000;
  border-color: #4067a2;
}

.input:disabled {
  background: rgba(255, 255, 255, 0.02);
  color: rgba(255, 255, 255, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.05);
  box-shadow: none;
  cursor: not-allowed;
  animation: none;
  transform: none;
}

.input:disabled::placeholder {
  color: rgba(255, 255, 255, 0.3);
}

/* Send Button */
button {
  color: #e0e0e0;
  padding: 3px 22px;
  border-radius: 0.5em;
  background: #1f1f1f;
  border: 1px solid rgba(0, 255, 255, 0.1);
  cursor: pointer;
  box-shadow: 0 0 10px rgba(0, 255, 255, 0.2);
  transition: all 0.3s ease;
}

/* button:hover {
  background: #222;
  box-shadow: 0 0 20px rgba(0, 255, 255, 0.4);
} */

button:active {
  color: #666;
  box-shadow: inset 4px 4px 10px var(--accent-color-1),
    inset -4px -4px 10px rgba(255, 255, 255, 0.03);
  transform: translateY(0);
}

button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  background: #1f1f1f;
  color: #888;
  box-shadow: none;
  border: 1px solid rgba(255, 255, 255, 0.1);
  transform: none;
}

.input:disabled {
  background: rgba(255, 255, 255, 0.02);
  color: rgba(255, 255, 255, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.05);
  box-shadow: none;
  cursor: not-allowed;
  animation: none;
  transform: none;
}

.input:disabled::placeholder {
  color: rgba(255, 255, 255, 0.3);
}

#message-input {
  font-size: 16px;
}

/* Messages */
.message-container {
  display: flex;
  flex-direction: column;
}

.name {
  font-weight: bold;
  color: #00ffff;
}

.time {
  font-size: 12px;
  color: #aaa;
}

.message-box {
  padding: 10px 15px;
  border-radius: 10px;
  max-width: 60%;
  font-size: 14px;
  background: #1a1a1a;
}

/* User and Bot Messages */
.user .message-box {
  backdrop-filter: blur(10px);
  border-radius: 20px;
  padding: 12px 18px;
  color: #ffffff;
  font-size: 14px;
  box-shadow: 0 0 12px #00ffcc, 0 0 24px #00ffcc88;
  border: 1px solid rgba(0, 255, 204, 0.3);
}

.bot .message-box {
  background: rgba(127, 90, 240, 0.1);
  backdrop-filter: blur(10px);
  border-radius: 20px;
  padding: 12px 18px;
  color: #e0d7ff;
  box-shadow: 0 0 12px #7f5af0, 0 0 24px #a56cf488;
  border: 1px solid rgba(127, 90, 240, 0.3);
}

/* Numbered Doctor List */
.numbered-doctor-list {
  list-style: decimal;
  padding-left: 20px;
  margin-top: 10px;
}

.numbered-doctor-list li {
  background: #1e1e1e;
  border: 1px solid rgba(0, 255, 255, 0.1);
  padding: 10px;
  margin-bottom: 6px;
  border-radius: 8px;
}

.numbered-doctor-list li strong {
  color: #00ffff;
}

.clickable-numbered-list {
  list-style: decimal;
  list-style-type: none;
  padding-left: 20px;
  margin-top: 10px;
}

.clickable-numbered-list li {
  background: #00ff2d47;
  border: 1px solid rgba(0, 255, 255, 0.1);
  padding: 10px;
  margin-bottom: 6px;
  border-radius: 8px;
}

/* Value inside numbered list */
.clickable-numbered-list .value-text {
  color: #00ff22b8;
  font-weight: 600;
}

/* Quick Replies */
.quick-replies {
  display: flex;
  margin-top: 10px;
  flex-wrap: wrap;
}

.quick-reply-bubble {
  background: #1f1f1f;
  border: 1px solid rgba(0, 255, 255, 0.2);
  color: #00ffff;
  cursor: pointer;
  padding: 6px 14px;
  margin: 4px;
  border-radius: 30px;
  transition: all 0.3s;
}

.quick-reply-bubble:hover {
  background: rgba(0, 255, 255, 0.1);
  box-shadow: 0 0 10px rgba(0, 255, 255, 0.3);
}

.privacy-banner {
  padding: 1px;
  border-radius: 5px;
  text-align: center;
  margin-bottom: 10px;
}

.privacy-banner h4 {
  margin: 0;
}

.policy-section {
  background: black;
  padding: 10px;
  border-radius: 5px;
  scrollbar-width: thin;
  scrollbar-color: #00f5d4 #ffffff00;
  margin-bottom: 10px;
  text-align: left;
  max-height: 120px;
  overflow-y: auto;
}

.policy-section h5 {
  margin-top: 0;
  color: #333;
}

.policy-section ol {
  padding-left: 20px;
  font-size: 14px;
  list-style-type: decimal;
}

.policy-section ol li {
  margin-bottom: 5px;
  text-align: left;
}

.consent-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  justify-content: center;
  align-items: center;
}
.consent-content {
  background: #1e1e1e;
  padding: 20px;
  border-radius: 5px;
  box-shadow: 0 0 10px rgba(0, 255, 255, 0.3);
  min-width: 50px;
  max-width: 30rem;
}

p {
  color: white;
  font-size: 14px;
  margin: 0;
}

small {
  color: white;
}

.consent-content h3 {
  margin-bottom: 10px;
}

@keyframes charSlideFadeIn {
  0% {
    opacity: 0;
    transform: translateX(20px);
  }
  100% {
    opacity: 1;
    transform: translateX(0);
  }
}

.custom-online-text {
  font-size: 0.8em;
  font-weight: 600;
  display: inline-block;
  white-space: nowrap;
}

.custom-offline-text {
  font-size: 0.8em;
  font-weight: 600;
  display: inline-block;
  white-space: nowrap;
}

.custom-online-text span {
  color: #38c963 !important;
}

.custom-offline-text span,
.custom-offline-text {
  color: #e74c3c !important;
}

.custom-online-text span,
.custom-offline-text span {
  display: inline-block;
  opacity: 0;
  animation: charSlideFadeIn 0.4s ease-out forwards;
}

/* Staggered animation delay for each character */
.custom-online-text span:nth-child(1) {
  animation-delay: 0s;
}
.custom-online-text span:nth-child(2) {
  animation-delay: 0.05s;
}
.custom-online-text span:nth-child(3) {
  animation-delay: 0.1s;
}
.custom-online-text span:nth-child(4) {
  animation-delay: 0.15s;
}
.custom-online-text span:nth-child(5) {
  animation-delay: 0.2s;
}
.custom-online-text span:nth-child(6) {
  animation-delay: 0.25s;
}
.custom-online-text span:nth-child(7) {
  animation-delay: 0.3s;
}
.custom-online-text span:nth-child(8) {
  animation-delay: 0.35s;
}
.custom-online-text span:nth-child(9) {
  animation-delay: 0.4s;
}
.custom-online-text span:nth-child(10) {
  animation-delay: 0.45s;
}

.custom-offline-text span:nth-child(1) {
  animation-delay: 0s;
}
.custom-offline-text span:nth-child(2) {
  animation-delay: 0.05s;
}

.online-dot {
  width: 10px;
  height: 10px;
  background-color: #28a745;
  border-radius: 50%;
  display: inline-block;
  margin-left: 8px;
  margin-right: 5px;
}
.offline-dot {
  width: 10px;
  height: 10px;
  background-color: #a72828;
  border-radius: 50%;
  display: inline-block;
  margin-left: 8px;
  margin-right: 5px;
}

@keyframes rotate {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

@keyframes glow {
  0%,
  100% {
    box-shadow: 0 0 10px rgba(52, 152, 219, 0.7),
      0 0 20px rgba(52, 152, 219, 0.5);
  }

  50% {
    box-shadow: 0 0 30px rgba(52, 152, 219, 1), 0 0 40px rgba(52, 152, 219, 0.8);
  }
}

.clickable-list-item {
  position: relative;
  overflow: hidden;
  filter: drop-shadow(2px 4px 6px black);
  cursor: pointer;
  user-select: none;
  transition: all 0.25s ease;
  z-index: 0;
}

.clickable-list-item::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background-color: #77dd7787;
  z-index: -1;
  transition: left 0.3s ease;
}

.clickable-list-item:hover::before {
  left: 0;
}

.clickable-list-item:hover {
  color: #fff;
  transform: translateY(-3px);
  box-shadow: 0 14px 30px rgba(25, 179, 83, 0.4);
}

.clickable-list-item:active {
  transform: translateY(1px) scale(0.98);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.08);
}
/* === Typing Indicator === */
.typing-indicator {
  display: flex;
  align-items: center;
}
.dot {
  font-size: 12px;
  opacity: 0.3;
  animation: typing-bounce 1.4s infinite ease-in-out;
}
.dot:nth-child(1) {
  animation-delay: 0s;
}
.dot:nth-child(2) {
  animation-delay: 0.2s;
}
.dot:nth-child(3) {
  animation-delay: 0.4s;
}
@keyframes typing-bounce {
  0%,
  100% {
    opacity: 0.3;
    transform: translateY(0);
  }
  50% {
    opacity: 1;
    transform: translateY(-5px);
  }
}

/* Fade animation */
@keyframes blink {
  0%,
  80%,
  100% {
    opacity: 0.3;
    transform: scale(1);
  }
  40% {
    opacity: 1;
    transform: scale(1.1);
  }
}
.clickable-list-item.disabled {
  pointer-events: none;
  opacity: 0.5;
  cursor: default;
}

@keyframes typing-bounce {
  0%,
  100% {
    opacity: 0.3;
    transform: translateY(0);
  }
  50% {
    opacity: 1;
    transform: translateY(-5px);
  }
}

.conversation-ended-notice {
  text-align: center;
  font-size: 11px;
  font-weight: 400;
  color: #ffffff;
  margin: 16px auto;
  padding: 8px 0;
  border-top: 1px solid #efefef;
  opacity: 0.8;
  padding-bottom: 0px;
}

.d-none {
  display: none !important;
}

.inactivity-popup-design {
  position: fixed;
  top: 30%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: black;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
  z-index: 9999;
}

.fade-out {
  opacity: 1;
  transform: translateY(0);
  max-height: 1000px;
  padding: 1rem;
  margin-bottom: 0.5rem;
  transition: opacity 0.6s ease, transform 0.6s ease, max-height 0.6s ease,
    margin 0.6s ease, padding 0.6s ease;
  overflow: hidden;
  will-change: opacity, transform, max-height, margin, padding;
  border-radius: 0.5rem;
  background-color: #e1e1e1db;
}

.fade-out.hide {
  opacity: 0;
  transform: translateY(-15px);
  max-height: 0;
  padding-top: 0;
  padding-bottom: 0;
  margin-bottom: 0;
}

/* custom popuop wevsocket */ /* Make sure your overlay remains centered */
.custom-popup-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  flex-grow: 1;
  overflow-y: auto;

  /* Firefox scrollbar */
  scrollbar-width: thin;
  scrollbar-color: #00f5d4 #ffffff00;

  /* Futuristic glass background */
  background: rgba(20, 20, 30, 0.6);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.1);

  /* Subtle neon glow */
  box-shadow: 0 0 20px rgba(0, 255, 200, 0.3), 0 0 40px rgba(0, 200, 255, 0.15),
    inset 0 0 10px rgba(0, 255, 200, 0.05);

  /* Smooth scroll */
  scroll-behavior: smooth;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

/* Reuse the consent-content styling for consistency */
.custom-popup-overlay .consent-content {
  background: #1e1e1e;
  padding: 20px;
  border-radius: 5px;
  box-shadow: 0 0 10px rgba(0, 255, 255, 0.3);
  min-width: 50px;
  max-width: 30rem;
  display: flex;
  flex-direction: column;
}

/* Scrollable content area */
.custom-popup-overlay .policy-section {
  background: #000 !important;
  padding: 10px;
  border-radius: 5px;
  max-height: 120px;
  overflow-y: auto;
  text-align: left;
}

.wave-group {
  position: relative;
}

.wave-group .inputConsent {
  font-size: 16px;
  padding: 10px 10px 0px 5px;
  display: block;
  width: 200px;
  border: none;
  border-bottom: 1px solid #515151;
  background: transparent;
}

.wave-group .inputConsent:focus {
  outline: none;
}

.wave-group .label {
  color: #999;
  font-size: 13px;
  font-weight: normal;
  position: absolute;
  pointer-events: none;
  left: 5px;
  top: 10px;
  display: flex;
}

.wave-group .label-char {
  transition: 0.2s ease all;
  transition-delay: calc(var(--index) * 0.05s);
}

.wave-group .inputConsent:focus ~ label .label-char,
.wave-group .inputConsent:valid ~ label .label-char {
  transform: translateY(-20px);
  font-size: 14px;
  color: #5264ae;
}

.wave-group .bar {
  position: relative;
  display: block;
  width: 200px;
}

.wave-group .bar:before,
.wave-group .bar:after {
  content: "";
  height: 2px;
  width: 0;
  bottom: 1px;
  position: absolute;
  background: #5264ae;
  transition: 0.2s ease all;
  -moz-transition: 0.2s ease all;
  -webkit-transition: 0.2s ease all;
}

.wave-group .bar:before {
  left: 50%;
}

.wave-group .bar:after {
  right: 50%;
}

.wave-group .inputConsent:focus ~ .bar:before,
.wave-group .inputConsent:focus ~ .bar:after {
  width: 50%;
}

@keyframes snapInSmooth {
  0% {
    opacity: 0;
    transform: scale(0.4) rotate(-25deg) translateY(40px);
  }
  70% {
    opacity: 1;
    transform: scale(1.1) rotate(8deg) translateY(-5px);
  }
  100% {
    transform: scale(1) rotate(0deg) translateY(0);
  }
}

.animated-logo {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: inline-block;
  animation: snapInSmooth 0.7s cubic-bezier(0.4, 0, 0.2, 1) forwards;
  transform-origin: center bottom;
  cursor: pointer;
  user-select: none;
  transition: transform 0.3s ease, filter 0.3s ease;
}

/* 3D tilt effect on hover */
.animated-logo:hover {
  transform: scale(1.05) rotateX(8deg) rotateY(12deg);
  filter: drop-shadow(0 6px 10px rgba(0, 0, 0, 0.15));
}

.policy-section span {
  color: black;
}

:root {
  color-scheme: dark;
}

body.light-mode {
  background-color: #ffffff !important;
  color: #000000 !important;
}

body.light-mode .card,
body.light-mode .card-body,
body.light-mode .message-box,
body.light-mode .input,
body.light-mode .consent-content,
body.light-mode .policy-section,
body.light-mode .custom-popup-overlay,
body.light-mode .numbered-doctor-list li,
body.light-mode .clickable-numbered-list li {
  background-color: #f9f9f9 !important;
  color: #000 !important;
  border: 1px solid #ddd !important;
}

body.light-mode .inactivity-popup-design {
  background: #ffffff !important;
  color: #000 !important;
  border: 1px solid #00bcd4 !important;
}

body.light-mode .user .message-box {
  box-shadow: 0 0 12px #00ffcc, 0 0 24px #00ffcc88 !important;
}

body.light-mode .bot .message-box {
  box-shadow: 0 0 12px #7f5af0, 0 0 24px #a56cf488 !important;
}

body.light-mode .wave-group .inputConsent {
  color: black !important;
}

body.light-mode .input::placeholder,
body.light-mode small,
body.light-mode p {
  color: #222 !important;
}

.theme-toggle-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 10000;
  background: #000000;
  color: #ffee00;
  border: 1px solid rgba(0, 255, 255, 0.2);
  border-radius: 20px;
  padding: 6px 12px;
  font-size: 0.875rem;
  cursor: pointer;
}

.neon-border-wrapper {
  position: relative;
  border-radius: 5px;
  padding: 4px;
  z-index: 0;
}

.neon-border-wrapper::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 5px;
  border: 4px solid transparent;
  background: linear-gradient(
    90deg,
    transparent 0%,
    #0011ffcc 5%,
    transparent 10%,
    transparent 20%,
    #00ff1acc 30%,
    transparent 40%,
    #d000f7cc 50%,
    transparent 60%,
    #0011ffcc 80%,
    transparent 90%,
    #00ff1acc 100%
  );

  background-size: 300% 100%;

  background-clip: border-box;
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask-composite: exclude;
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  pointer-events: none;
  animation: slide-gradient 13s linear infinite;
}
@keyframes slide-gradient {
  0% {
    background-position: 0% 50%;
  }
  25% {
    background-position: 50% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  75% {
    background-position: 50% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}
.neu-button {
  background: #e0e0e0;
  border-radius: 50px;
  color: #4d4d4d;
  cursor: pointer;
  font-size: 12px;
  transition: all 0.2s ease-in-out;
  border: none;
}
