body { font-family: Arial, sans-serif; margin: 0; padding: 0; height: 100vh; display: flex; flex-direction: column; overflow: hidden; } /* Blurred background image */ body::before { content: ""; position: fixed; top: 0; left: 0; width: 100vw; height: 100vh; z-index: -1; background: rgb(23, 23, 23); } .chat-container { flex: 1; display: flex; flex-direction: column; padding: 15px; overflow-y: auto; overflow-x: hidden; /* prevent horizontal scrolling */ margin-bottom: 70px; background: transparent; width: 100%; max-width: 95%; /* wider to accommodate terminal output */ margin-left: auto; /* center align */ margin-right: auto; /* center align */ scroll-behavior: smooth; /* Smooth scrolling */ height: calc(100vh - 70px); /* Full height minus input area */ } .message { width: fit-content; /* shrink to text */ max-width: 100%; /* allow full width for terminal output */ margin-bottom: 12px; padding: 12px 15px; border-radius: 15px; line-height: 1.4; } /* Special styling for bot messages with pre-formatted text */ .message.bot.pre-formatted { width: 100%; /* full width for terminal output */ max-width: 100%; /* no width restriction */ white-space: pre-wrap; /* wrap text to prevent horizontal scroll */ overflow-wrap: break-word; /* break long words if needed */ } .user { align-self: flex-end; /* right side */ background: #414141; color: #fff; border-bottom-right-radius: 5px; } .bot { align-self: flex-start; /* left side */ background: transparent; color: #ffffff; border-bottom-left-radius: 5px; } /* Terminal output style - matching exactly what appears in the terminal */ .message.bot pre { font-family: monospace; background-color: transparent; /* No background color */ color: inherit; /* Use the same text color as the parent */ padding: 0; border: none; width: 100%; max-height: none; /* No height limit */ overflow-x: visible; /* No horizontal scrolling */ white-space: pre-wrap; /* Wrap text to prevent horizontal scrolling */ font-size: inherit; line-height: 1.4; } .input-area { position: fixed; bottom: 1rem; left: 50%; transform: translateX(-50%); width: 100%; max-width: 95%; /* Match the width of chat container */ display: flex; padding: 10px; background: rgba(54, 54, 54, 0.7); /* make input area semi-transparent */ box-shadow: 0 -2px 5px rgba(0,0,0,0.05); border-radius: 30px; z-index: 10; /* Ensure input stays on top */ } .input-area input { flex: 1; padding: 14px 18px; border: 1px solid #1b1b1b; box-shadow: #414141; border-radius: 25px; outline: none; font-size: 1rem; } .input-area button { margin-left: 10px; padding: 0 20px; border: none; background: #1f1f1f; color: white; border-radius: 25px; cursor: pointer; font-size: 1rem; transition: background 0.2s ease; } .input-area button:hover { background: #6a6a6a; } .loader { font-size: 0.9rem; color: gray; margin: 5px 0; } .chat-background{ position: fixed; font-family: 'Courier New', Courier, monospace; top: 40%; left: 50%; transform: translate(-50%, -50%); font-weight: bold; color: rgba(255, 255, 255, 0.8); /* semi-transparent */ text-align: center; z-index: 0; /* below chat messages */ pointer-events: none; /* makes it "untouchable" */ transition: all 0.4s ease; } .chat-background{ display: inline-block; text-align: left; } .chat-background #p1 { font-size: 4rem; } .chat-background #p2 { font-size: 3rem; } /* When blurred */ .chat-background.blurred { filter: blur(12px); /* strong blur */ opacity: 0.4; /* fade slightly for readability */ transition: all 0.4s ease; } @media (max-width: 600px) { .message { max-width: 85%; } .chat-container { padding: 10px; max-width: 100%; } .input-area { max-width: 95%; bottom: 0.5rem; } .chat-background #p1 { font-size: 3rem; } .chat-background #p2 { font-size: 2rem; } }