:root {
    --primary-color: #c08226;
    --primary-hover: #e09a2e;
    --bg-light: #252525;
    --border-light: #3d3d3d;
    --text-primary: #e0e0e0;
    --text-secondary: #a0a0a0;
    --shadow-sm: 0 1px 2px -2px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
    --radius-sm: 8px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --danger: #ef4444;
    --danger-hover: #dc2626;
    --coin-color: #f0a202;
    --bot-bg: #333333;
    --send-btn-size: 40px;
}
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: system-ui, -apple-system, sans-serif;
    user-select: none;
}
body {
    background-color: var(--bg-light);
    height: 100vh;
    overflow: hidden;
    font-size: 13px;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    color: var(--text-primary);
}
.message-bot, .chat-messages {
    -webkit-touch-callout: text;
    -webkit-user-select: text;
    -khtml-user-select: text;
    -moz-user-select: text;
    -ms-user-select: text;
    user-select: text;
}
.message-user {
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}
a {
  color: #e09a2e;
  text-decoration: none;
  font-weight: bold;
  transition: color 0.2s ease;
}
a:hover {
  color: #f0a202;
}
.message-input-wrapper {
  display: flex;
  align-items: center;
  position: relative;
}
#message-input {
  flex: 1;
  height: 40px;
  padding: 0 16px;
  border: 1px solid var(--border-light);
  border-radius: 24px 0 0 24px;
  font-size: 13px;
  line-height: 40px;
  background-color: #333333;
  color: var(--text-primary);
  border-right: none;
  transition: box-shadow 0.2s ease-in-out;
}
#message-input::placeholder {
  color: var(--text-secondary);
}
#message-input:focus {
  outline: none;
  box-shadow: inset 0px -2px 12px 0px rgba(0, 0, 0, 0.2);
}
.send-btn {
  width: var(--send-btn-size);
  height: 40px;
  border: none;
  border-radius: 0 24px 24px 0;
  background-color: var(--primary-color);
  display: flex;
  color: #252525;
  font-size: 18px;
  padding-right: 7px;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 0.15s ease;
}
.send-btn:hover {
  background-color: var(--primary-hover);
}
.menu-toggle {
    background: none;
    border: none;
    font-size: 18px;
    color: var(--primary-color);
    cursor: pointer;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}
.menu-toggle:hover {
    background-color: rgba(192, 130, 38, 0.2);
}
.chat-container {
    display: flex;
    height: 100vh;
    width: 100%;
    overflow: hidden;
    position: relative;
}
.main-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(3px);
    z-index: 100;
    display: none;
}
.main-overlay.active {
    display: block;
}
.chat-main {
   flex-grow: 1;
   display: flex;
   flex-direction: column;
   background-color: var(--bg-light);
   min-width: 0;
   position: relative;
   height: 100%;
}
.welcome-screen {
   position: absolute;
   top: 0;
   left: 0;
   right: 0;
   bottom: 0;
   display: flex;
   flex-direction: column;
   justify-content: center;
   align-items: center;
   background-color: #333333;
   z-index: 9;
   padding: 20px;
   text-align: center;
   margin-top: -50px;
   pointer-events: auto;
}
.welcome-icon-container {
   width: 60px;
   height: 60px;
   background-color: #414141;
   border-radius: 50%;
   display: flex;
   align-items: center;
   justify-content: center;
   margin-bottom: 8px;
}
.welcome-icon {
   width: 30px;
   height: 30px;
   filter: invert(1);
}
.welcome-screen h1 {
   font-size: 20px;
   color: var(--text-primary);
   margin-bottom: 10px;
}
.welcome-screen p {
   color: var(--text-secondary);
   margin-bottom: 20px;
   max-width: 230px;
   font-size: 12px;
}
.welcome-questions {
   display: flex;
   flex-wrap: wrap;
   justify-content: center;
   gap: 10px;
   width: 100%;
   max-width: 450px;
}
.welcome-quick-question {
   background: linear-gradient(135deg, rgba(192, 130, 38, 0.15) 0%, rgba(224, 154, 46, 0.15) 100%);
   color: var(--primary-color);
   padding: 8px 12px;
   border-radius: var(--radius-lg);
   cursor: pointer;
   font-size: 11px;
   font-weight: 500;
   border: 1px solid rgba(192, 130, 38, 0.3);
   text-align: center;
   display: inline-block;
   max-width: fit-content;
}
.welcome-quick-question:hover {
   background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-hover) 100%);
   color: #252525;
   box-shadow: var(--shadow-sm);
}
.fade-out {
   opacity: 0;
   transform: translateY(20px);
   transition: opacity 0.3s ease, transform 0.3s ease;
}
.chat-messages {
   flex-grow: 1;
   padding-left: 15px;
   padding-right: 15px;
   padding-top: 15px;
   padding-bottom: 70px;
   overflow-y: auto;
   display: flex;
   flex-direction: column;
   gap: 14px;
}
.chat-messages::-webkit-scrollbar {
   width: 6px;
}
.chat-messages::-webkit-scrollbar-track {
   background: transparent;
}
.chat-messages::-webkit-scrollbar-thumb {
   background: #444444;
   border-radius: 3px;
}
.message {
   max-width: 75%;
   padding: 10px 14px;
   border-radius: var(--radius-lg);
   line-height: 1.5;
   animation: messageAppear 0.3s ease-out forwards;
   opacity: 0;
   transform: translateY(20px);
}
.message-content {
   display: flex;
   flex-direction: column;
}
.star-rating-container {
   display: inline-flex;
   align-items: center;
   margin-top: 5px;
   gap: 5px;
}
@keyframes messageAppear {
   to {
       opacity: 1;
       transform: translateY(0);
   }
}

pre, code {
    background-color: #333333;
    color: #e0e0e0;
    border-radius: 4px;
    padding: 2px 4px;
}

pre code {
    background-color: transparent;
    padding: 0;
}

blockquote {
    border-left: 3px solid var(--primary-color);
    padding-left: 10px;
    margin-left: 5px;
    color: var(--text-secondary);
}

table {
    border-collapse: collapse;
    width: 100%;
    margin-bottom: 15px;
}

table, th, td {
    border: 1px solid var(--border-light);
}

th {
    background-color: #333333;
    padding: 8px;
    text-align: left;
}

td {
    padding: 6px 8px;
    background-color: #252525;
}

img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
}

[contenteditable=true]:empty:before {
    content: attr(placeholder);
    color: var(--text-secondary);
    display: block;
}

::selection {
    background-color: rgba(192, 130, 38, 0.3);
    color: var(--text-primary);
}

::-moz-selection {
    background-color: rgba(192, 130, 38, 0.3);
    color: var(--text-primary);
}
.message-user {
   align-self: flex-end;
   background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-hover) 100%);
   color: #252525;
   border-bottom-right-radius: 4px;
}
.message-bot {
   align-self: flex-start;
   background-color: var(--bot-bg);
   color: var(--text-primary);
   border-bottom-left-radius: 4px;
   box-shadow: var(--shadow-sm);
}
.loading-indicator {
   align-self: flex-start;
   background-color: var(--bot-bg);
   border-radius: var(--radius-lg);
   border-bottom-left-radius: 4px;
   padding: 15px 19px;
   box-shadow: var(--shadow-sm);
}
.loading-dots {
   display: flex;
   gap: 6px;
}
.loading-dot {
   width: 6px;
   height: 6px;
   background-color: var(--text-secondary);
   border-radius: 50%;
   animation: loading 1.4s ease-in-out infinite both;
}
.loading-dot:nth-child(1) {
   animation-delay: -0.32s;
}
.loading-dot:nth-child(2) {
   animation-delay: -0.16s;
}
@keyframes loading {
   0%, 80%, 100% {
       transform: scale(0);
   }
   40% {
       transform: scale(1);
   }
}
.rating-star {
   cursor: pointer;
   color: var(--primary-color);
   font-size: 18px;
   transition: transform 0.2s;
}
.rating-star:hover {
   transform: scale(1.2);
}
.rating-star .far {
   color: var(--text-secondary);
}
.rating-star .fas {
   color: var(--primary-color);
}
.rating-feedback {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(-100px);
    background-color: var(--primary-color);
    color: #252525;
    padding: 12px 20px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    z-index: 1000;
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
}
.rating-feedback.active {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}
.rating-message {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
}
.rating-message i {
    font-size: 17px;
}
.input-container {
   padding: 12px 15px;
   background-color: #2e2e2e;
   border-top: 1px solid var(--border-light);
   z-index: 10;
   position: absolute;
   bottom: 0;
   left: 0;
   right: 0;
}
.sr-only {
 position: absolute;
 width: 1px;
 height: 1px;
 padding: 0;
 margin: -1px;
 overflow: hidden;
 clip: rect(0, 0, 0, 0);
 white-space: nowrap;
 border-width: 0;
}
@media (max-width: 480px) {
  .welcome-screen h1 {
      font-size: 18px;
  }
  
  .welcome-icon-container {
      width: 50px;
      height: 50px;
  }
  
  .welcome-icon {
      width: 25px;
      height: 25px;
  }
  
  #message-input {
      height: 38px;
      font-size: 13px;
  }
  
  .send-btn {
      height: 38px;
      width: 38px;
  }
}
@media (max-width: 359px) {
  .welcome-quick-question {
      font-size: 10px;
      padding: 6px 10px;
  }
}
@media (max-width: 768px) {
  .input-container {
      padding: 12px 12px;
  }
  
  body {
      position: fixed;
      height: 100%;
      width: 100%;
      overflow: hidden;
  }
  
  .chat-container {
      height: 100%;
      overflow: hidden;
  }
}