help@rskworld.in +91 93305 39277
RSK World
  • Home
  • Development
    • Web Development
    • Mobile Apps
    • Software
    • Games
    • Project
  • Technologies
    • Data Science
    • AI Development
    • Cloud Development
    • Blockchain
    • Cyber Security
    • Dev Tools
    • Testing Tools
  • Blog
  • About
  • Contact

Theme Settings

Color Scheme
Display Options
Font Size
100%
Back to Project
RSK World
voice-assistant-chatbot
RSK World
voice-assistant-chatbot
Voice Assistant Chatbot - JavaScript + Web Speech API + Speech Recognition + Text-to-Speech + Voice Commands + AI
voice-assistant-chatbot
  • .gitignore470 B
  • DATA_STORAGE.md6.2 KB
  • ERROR_FIXES.md4.1 KB
  • GITHUB_RELEASE_INSTRUCTIONS.md5.9 KB
  • LICENSE1.2 KB
  • README.md8.1 KB
  • RELEASE_NOTES.md6.5 KB
  • config.js2.3 KB
  • index.html7 KB
  • script.js41.6 KB
  • styles.css9.7 KB
styles.css
styles.css
Raw Download
Find: Go to:
/*
    Voice Assistant Chatbot - Styles
    Developed by: RSK World
    Website: https://rskworld.in
    Email: help@rskworld.in
    Phone: +91 93305 39277
    Year: 2026
*/

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
    color: #333;
    transition: background 0.3s ease;
}

body.dark-mode {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
}

.container {
    width: 100%;
    max-width: 900px;
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: calc(100vh - 100px);
    max-height: 800px;
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

body.dark-mode .container {
    background: #2d2d44;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}

header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 25px;
    text-align: center;
}

header h1 {
    font-size: 2rem;
    margin-bottom: 5px;
}

header h1 i {
    margin-right: 10px;
    color: #ffc107;
}

.subtitle {
    font-size: 0.9rem;
    opacity: 0.9;
}

.chat-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    background: #f8f9fa;
    transition: background 0.3s ease;
}

body.dark-mode .chat-messages {
    background: #1e1e2e;
}

.message {
    margin-bottom: 15px;
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.message-content {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 15px;
    border-radius: 15px;
    max-width: 80%;
    word-wrap: break-word;
}

.message-content i {
    font-size: 1.2rem;
    margin-top: 2px;
}

.user-message .message-content {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    margin-left: auto;
    flex-direction: row-reverse;
}

.bot-message .message-content {
    background: white;
    color: #333;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: background 0.3s ease, color 0.3s ease;
}

body.dark-mode .bot-message .message-content {
    background: #3a3a5c;
    color: #e0e0e0;
}

.bot-message .message-content i {
    color: #667eea;
}

.user-message .message-content i {
    color: #ffc107;
}

.message-content p {
    margin: 0;
    line-height: 1.5;
}

.input-container {
    padding: 20px;
    background: white;
    border-top: 1px solid #e0e0e0;
}

.input-wrapper {
    display: flex;
    gap: 10px;
    align-items: center;
}

#textInput {
    flex: 1;
    padding: 15px 20px;
    border: 2px solid #e0e0e0;
    border-radius: 25px;
    font-size: 1rem;
    outline: none;
    transition: border-color 0.3s;
}

#textInput:focus {
    border-color: #667eea;
}

.btn-send, .btn-voice {
    width: 50px;
    height: 50px;
    border: none;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: transform 0.2s, box-shadow 0.2s;
}

.btn-send:hover, .btn-voice:hover {
    transform: scale(1.1);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.btn-voice.recording {
    background: #dc3545;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

.voice-status {
    margin-top: 10px;
    text-align: center;
    font-size: 0.9rem;
    color: #666;
    min-height: 20px;
}

.voice-status.listening {
    color: #dc3545;
    font-weight: bold;
}

.voice-status.processing {
    color: #667eea;
    font-weight: bold;
}

.controls {
    display: flex;
    gap: 10px;
    padding: 15px 20px;
    background: #f8f9fa;
    border-top: 1px solid #e0e0e0;
    justify-content: center;
    flex-wrap: wrap;
    transition: background 0.3s ease, border-color 0.3s ease;
}

body.dark-mode .controls {
    background: #252538;
    border-top-color: #3a3a5c;
}

.btn-clear, .btn-settings, .btn-export, .btn-stats, .btn-dark {
    padding: 10px 20px;
    border: none;
    border-radius: 25px;
    background: white;
    color: #667eea;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    gap: 5px;
}

.btn-clear:hover, .btn-settings:hover, .btn-export:hover, .btn-stats:hover, .btn-dark:hover {
    background: #667eea;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(102, 126, 234, 0.3);
}

body.dark-mode .btn-clear, 
body.dark-mode .btn-settings, 
body.dark-mode .btn-export, 
body.dark-mode .btn-stats, 
body.dark-mode .btn-dark {
    background: #3a3a5c;
    color: #e0e0e0;
}

body.dark-mode .btn-dark.active {
    background: #ffc107;
    color: #1a1a2e;
}

.settings-panel {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    min-width: 300px;
    display: none;
}

.settings-panel.active, .stats-panel.active {
    display: block;
}

.stats-panel {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    min-width: 300px;
    display: none;
}

body.dark-mode .stats-panel {
    background: #2d2d44;
    color: #e0e0e0;
}

.stats-content {
    margin-bottom: 20px;
}

.stat-item {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid #e0e0e0;
}

body.dark-mode .stat-item {
    border-bottom-color: #3a3a5c;
}

.stat-label {
    font-weight: 500;
}

.stat-value {
    font-weight: bold;
    color: #667eea;
}

body.dark-mode .stat-value {
    color: #ffc107;
}

.settings-panel h3 {
    margin-bottom: 20px;
    color: #667eea;
    text-align: center;
}

.setting-item {
    margin-bottom: 20px;
}

.setting-item label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 500;
}

.setting-item select, .setting-item input[type="text"] {
    width: 100%;
    padding: 10px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1rem;
    outline: none;
    transition: border-color 0.3s;
}

body.dark-mode .setting-item select, 
body.dark-mode .setting-item input[type="text"] {
    background: #3a3a5c;
    color: #e0e0e0;
    border-color: #4a4a6c;
}

.setting-item input[type="checkbox"] {
    margin-right: 8px;
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.setting-item label {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.setting-item input[type="range"] {
    width: calc(100% - 60px);
    margin-right: 10px;
}

.setting-item span {
    display: inline-block;
    width: 50px;
    text-align: right;
    color: #667eea;
    font-weight: bold;
}

.btn-close {
    width: 100%;
    padding: 12px;
    border: none;
    border-radius: 8px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    cursor: pointer;
    font-size: 1rem;
    margin-top: 10px;
    transition: transform 0.2s;
}

.btn-close:hover {
    transform: scale(1.05);
}

footer {
    margin-top: 20px;
    text-align: center;
    color: white;
    font-size: 0.9rem;
}

footer a {
    color: white;
    text-decoration: none;
    font-weight: bold;
}

footer a:hover {
    text-decoration: underline;
}

/* Scrollbar styling */
.chat-messages::-webkit-scrollbar {
    width: 8px;
}

.chat-messages::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.chat-messages::-webkit-scrollbar-thumb {
    background: #667eea;
    border-radius: 4px;
}

.chat-messages::-webkit-scrollbar-thumb:hover {
    background: #764ba2;
}

/* Responsive design */
@media (max-width: 768px) {
    .container {
        height: calc(100vh - 40px);
        max-height: none;
    }

    header h1 {
        font-size: 1.5rem;
    }

    .message-content {
        max-width: 90%;
    }

    .settings-panel {
        width: 90%;
        max-width: 400px;
    }
}

body.dark-mode .settings-panel {
    background: #2d2d44;
    color: #e0e0e0;
}

.audio-visualizer {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 200px;
    height: 60px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 10px;
    padding: 10px;
    display: none;
    z-index: 100;
}

.audio-visualizer.active {
    display: block;
}

body.dark-mode .audio-visualizer {
    background: rgba(0, 0, 0, 0.3);
}

#visualizerCanvas {
    width: 100%;
    height: 100%;
    border-radius: 5px;
}

.message-time {
    font-size: 0.7rem;
    opacity: 0.6;
    margin-top: 5px;
}

body.dark-mode .message-time {
    opacity: 0.5;
}

526 lines•9.7 KB
css

About RSK World

Founded by Molla Samser, with Designer & Tester Rima Khatun, RSK World is your one-stop destination for free programming resources, source code, and development tools.

Founder: Molla Samser
Designer & Tester: Rima Khatun

Development

  • Game Development
  • Web Development
  • Mobile Development
  • AI Development
  • Development Tools

Legal

  • Terms & Conditions
  • Privacy Policy
  • Disclaimer

Contact Info

Nutanhat, Mongolkote
Purba Burdwan, West Bengal
India, 713147

+91 93305 39277

hello@rskworld.in
support@rskworld.in

© 2026 RSK World. All rights reserved.

Content used for educational purposes only. View Disclaimer