/* =========================================
   1. Core Variables & Base Reset
   ========================================= */
:root {
    --rapid-navy: #002A54;
    --rapid-blue: #004985;
    --text-dark: #222222;
    --bg-light: #F4F6F8;
    --white: #ffffff;
    --transition-speed: 0.3s;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, Helvetica, sans-serif;
}

body {
    color: var(--text-dark);
    line-height: 1.5;
    background-color: var(--white);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

img {
    max-width: 100%;
    display: block;
}

/* =========================================
   2. Header & Navigation
   ========================================= */
.utility-bar {
    background-color: var(--bg-light);
    font-size: 12px;
    padding: 10px 0;
    border-bottom: 1px solid #ddd;
}

.utility-flex {
    display: flex;
    justify-content: space-between;
}

.utility-bar a {
    color: #555;
    text-decoration: none;
    margin-left: 15px;
    transition: color var(--transition-speed);
}

.utility-bar a:hover,
.utility-bar a:focus {
    color: var(--rapid-blue);
}

.main-header {
    position: sticky;
    top: 0;
    background: var(--white);
    padding: 20px 0;
    border-bottom: 1px solid #eaeaea;
    z-index: 1000;
}

.nav-flex {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

.logo-blue {
    color: var(--rapid-blue);
    font-size: 32px;
    font-weight: 900;
    text-transform: lowercase;
    letter-spacing: -1px;
    text-decoration: none;
}

.main-nav ul {
    display: flex;
    list-style: none;
    gap: 35px;
}

.main-nav a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: bold;
    font-size: 18px;
    transition: color var(--transition-speed);
}

.main-nav a:hover,
.main-nav a:focus {
    color: var(--rapid-blue);
}

.mobile-menu-toggle {
    display: none;
    font-size: 28px;
    color: var(--rapid-blue);
    cursor: pointer;
}

/* =========================================
   3. Global Buttons & Forms
   ========================================= */
.btn-blue, .btn-blue-outline {
    padding: 15px 30px;
    text-decoration: none;
    font-weight: bold;
    display: inline-block;
    border-radius: 4px;
    transition: all var(--transition-speed);
    cursor: pointer;
    border: 2px solid transparent;
    text-align: center;
}

.btn-blue {
    background: var(--rapid-blue);
    color: var(--white);
}

.btn-blue:hover, .btn-blue:focus {
    background: var(--rapid-navy);
}

.btn-blue-outline {
    background: transparent;
    color: var(--rapid-blue);
    border-color: var(--rapid-blue);
}

.btn-blue-outline:hover, .btn-blue-outline:focus {
    background: var(--rapid-blue);
    color: var(--white);
}

/* =========================================
   4. Hero & Call to Action (Dealer Bar)
   ========================================= */
.hero-section {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)),
                url('../images/pic03.JPG') center/cover no-repeat;
    height: 600px;
    display: flex;
    align-items: center;
}

.hero-box h1 {
    font-size: 42px;
    color: var(--white);
    line-height: 1.1;
    margin-bottom: 20px;
}

.hero-box p {
    font-size: 18px;
    margin-bottom: 30px;
    color: var(--white);
}

.dealer-bar {
    background: var(--rapid-navy);
    color: var(--white);
    padding: 40px 0;
}

.dealer-flex {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 30px;
    flex-wrap: wrap;
}

.dealer-flex h2 {
    font-size: 24px;
    font-weight: normal;
}

.dealer-form {
    display: flex;
}

.dealer-form input {
    padding: 15px;
    width: 300px;
    border: none;
    outline: none;
    font-size: 16px;
    border-radius: 4px 0 0 4px;
}

.dealer-form input:focus {
    box-shadow: inset 0 0 0 2px var(--rapid-blue);
}

.dealer-form button {
    padding: 15px 25px;
    background: var(--rapid-blue);
    border: none;
    color: var(--white);
    font-size: 18px;
    border-radius: 0 4px 4px 0;
    transition: background var(--transition-speed);
    cursor: pointer;
}

.dealer-form button:hover, .dealer-form button:focus {
    background: #005bb5;
}

/* =========================================
   5. General Layouts & Grids
   ========================================= */
.section-title {
    color: var(--rapid-navy);
    font-size: 36px;
    margin-bottom: 50px;
    text-align: center;
}

.section-title-large {
    font-size: 42px;
    font-weight: 300;
    color: var(--text-dark);
    margin-bottom: 40px;
}

/* Product Categories Grid (Home) */
.product-categories {
    padding: 80px 0;
    text-align: center;
    background: var(--white);
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.category-item {
    cursor: pointer;
    text-decoration: none;
    display: block;
}

.cat-circle {
    width: 150px;
    height: 150px;
    background: var(--bg-light);
    border-radius: 50%;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 50px;
    color: var(--rapid-blue);
    transition: transform var(--transition-speed), box-shadow var(--transition-speed);
}

.category-item:hover .cat-circle,
.category-item:focus .cat-circle {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.category-item h3 {
    font-size: 18px;
    color: var(--text-dark);
}

/* Resources Section */
.resources-section {
    background-color: #FAFAFA;
    padding: 100px 0;
}

.resources-container {
    display: flex;
    gap: 40px;
    align-items: flex-start;
}

.resources-sidebar {
    flex: 0 0 250px;
}

.resources-sidebar h2 {
    font-size: 18px;
    font-weight: 400;
    color: var(--text-dark);
    margin-bottom: 25px;
}

.btn-pill {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border: 1px solid var(--rapid-blue);
    color: var(--text-dark);
    border-radius: 50px;
    padding: 5px 5px 5px 20px;
    text-decoration: none;
    font-size: 14px;
    transition: background var(--transition-speed);
}

.btn-pill:hover, .btn-pill:focus {
    background-color: #eef5fc;
}

.icon-circle {
    background-color: var(--rapid-blue);
    color: white;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: 15px;
}

.resources-grid {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
}

.resource-card {
    padding: 40px 30px;
    display: flex;
    flex-direction: column;
    height: 250px;
    background: transparent;
    cursor: pointer;
    text-decoration: none;
    border: 1px solid transparent;
    transition: all var(--transition-speed);
}

.resource-card:hover, .resource-card:focus {
    background: var(--white);
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    border-color: #eaeaea;
}

.resource-card h3 {
    font-size: 22px;
    font-weight: 300;
    color: var(--text-dark);
    margin-top: auto;
    line-height: 1.2;
}

.line-icon {
    font-size: 36px;
    color: var(--rapid-blue);
}

/* Feature Articles */
.articles-section {
    padding: 100px 0;
    background-color: var(--white);
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
}

.article-card {
    display: flex;
    flex-direction: column;
    text-decoration: none;
}

.article-img-wrapper {
    overflow: hidden;
    border-radius: 24px;
    margin-bottom: 25px;
}

.article-img {
    aspect-ratio: 16/10;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.article-card:hover .article-img, .article-card:focus .article-img {
    transform: scale(1.05);
}

.overline {
    font-size: 13px;
    color: #666;
    display: block;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.article-card h3 {
    font-size: 26px;
    font-weight: 400;
    margin-bottom: 15px;
    color: var(--text-dark);
}

.article-card p {
    font-size: 16px;
    line-height: 1.6;
    color: #444;
    margin-bottom: 25px;
    padding-right: 20px;
}

.learn-more {
    color: var(--rapid-blue);
    text-decoration: none;
    font-size: 16px;
    font-weight: bold;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: gap var(--transition-speed);
}

.article-card:hover .learn-more, .learn-more:hover, .learn-more:focus {
    gap: 15px;
}

/* =========================================
   6. Specific Pages (Systems, About, Services)
   ========================================= */

/* Page Hero Header */
.page-hero {
    background: linear-gradient(135deg, var(--rapid-navy) 0%, var(--rapid-blue) 100%);
    color: var(--white);
    padding: 80px 20px;
    margin-bottom: 60px;
}

.page-hero .text-center {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.page-hero h1 {
    font-size: 2.5rem;
    margin-bottom: 20px;
}

.page-hero p {
    font-size: 1.2rem;
    opacity: 0.9;
}

/* Systems/Services Catalog Grid */
.systems-catalog {
    margin-bottom: 80px;
}

.system-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px;
}

.system-card {
    background: var(--white);
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform var(--transition-speed), box-shadow var(--transition-speed);
}

.system-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 42, 84, 0.1);
}

.system-icon {
    background: var(--bg-light);
    color: var(--rapid-blue);
    font-size: 3rem;
    padding: 40px 20px;
    text-align: center;
    border-bottom: 1px solid #e0e0e0;
}

.system-content {
    padding: 30px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.system-content h3 {
    color: var(--rapid-navy);
    font-size: 1.5rem;
    margin-bottom: 15px;
}

.system-content p {
    color: #555;
    margin-bottom: 25px;
    line-height: 1.6;
    flex-grow: 1;
}

.system-features {
    list-style: none;
    margin-bottom: 25px;
}

.system-features li {
    margin-bottom: 10px;
    color: #444;
    font-size: 0.95rem;
}

.system-features i {
    color: var(--rapid-blue);
    margin-right: 8px;
}

/* Offset for anchor links so the sticky header doesn't hide titles */
#installation, #maintenance {
    scroll-margin-top: 120px;
}

/* Services Page - Numbered Steps */
.installation-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

.step-card {
    background: var(--white);
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 30px 20px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
    transition: transform var(--transition-speed), box-shadow var(--transition-speed);
}

.step-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 42, 84, 0.08);
}

.step-number {
    background: var(--rapid-blue);
    color: var(--white);
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    font-weight: bold;
    margin: 0 auto 20px;
}

.step-card h3 {
    color: var(--rapid-navy);
    margin-bottom: 12px;
    font-size: 1.2rem;
}

.step-card p {
    color: #555;
    font-size: 0.95rem;
    line-height: 1.6;
}

/* =========================================
   7. Specific Pages (Repair or Replace)
   ========================================= */
.checklist-box {
    background: var(--white);
    border: 2px solid var(--rapid-blue);
    border-radius: 8px;
    padding: 40px;
    max-width: 800px;
    margin: 0 auto;
    box-shadow: 0 10px 30px rgba(0, 42, 84, 0.08);
}

.checklist-box h2 {
    color: var(--rapid-navy);
    margin-bottom: 15px;
    font-size: 1.8rem;
}

.checklist-box p {
    color: #555;
    margin-bottom: 25px;
}

.check-list {
    list-style: none;
    padding: 0;
}

.check-list li {
    font-size: 1.1rem;
    color: #333;
    margin-bottom: 15px;
    display: flex;
    align-items: flex-start;
}

.check-list i {
    color: var(--rapid-blue);
    font-size: 1.2rem;
    margin-right: 15px;
    margin-top: 3px;
}

.info-sections {
    max-width: 900px;
    margin: 0 auto 60px;
}

.info-row {
    padding: 40px 0;
    border-bottom: 1px solid #e0e0e0;
}

.info-text h2 {
    color: var(--rapid-navy);
    font-size: 1.6rem;
    margin-bottom: 15px;
}

.info-text p {
    color: #444;
    font-size: 1.05rem;
    line-height: 1.7;
    margin-bottom: 15px;
}

/* =========================================
   8. Specific Pages (Contact Us)
   ========================================= */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: start;
    padding: 0 0 80px 0;
}

.contact-info h2 {
    color: var(--rapid-navy);
    font-size: 2rem;
    margin-bottom: 15px;
}

.info-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 30px;
    background: var(--bg-light);
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
}

.info-icon {
    background: var(--rapid-blue);
    color: var(--white);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    margin-right: 20px;
    flex-shrink: 0;
}

.info-text-block h3 {
    color: var(--rapid-navy);
    margin-bottom: 5px;
    font-size: 1.1rem;
}

.info-text-block p {
    color: #555;
    margin: 0;
}

.contact-link {
    color: var(--rapid-blue);
    text-decoration: none;
    font-weight: bold;
    font-size: 1.1rem;
    transition: color var(--transition-speed);
}

.contact-link:hover {
    color: var(--rapid-navy);
    text-decoration: underline;
}

.styled-form {
    background: var(--white);
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    border: 1px solid #e0e0e0;
}

.form-group {
    margin-bottom: 20px;
    text-align: left;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: var(--rapid-navy);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
    font-family: inherit;
    transition: border-color var(--transition-speed);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--rapid-blue);
}

#formFeedback {
    margin-top: 15px;
    text-align: center;
    font-weight: bold;
}
#formFeedback.error { color: #d9534f; }
#formFeedback.success { color: #5cb85c; }

/* =========================================
   9. Footer Styles
   ========================================= */
.main-footer {
    background-color: var(--rapid-navy);
    color: var(--white);
    padding: 60px 0 0;
    margin-top: 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 40px;
    padding-bottom: 40px;
}

.footer-col h4 {
    position: relative;
    padding-bottom: 10px;
}

.footer-col h4::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 30px;
    height: 2px;
    background-color: var(--rapid-blue);
}

.footer-links, .footer-contact {
    list-style: none;
}

.footer-links li, .footer-contact li {
    margin-bottom: 12px;
    font-size: 0.95rem;
    color: #cbd5e0;
}

.footer-links a {
    color: #cbd5e0;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--white);
    padding-left: 5px;
}

.footer-contact i {
    color: var(--rapid-blue);
    margin-right: 10px;
    width: 15px;
}

.social-icons a {
    color: var(--white);
    background: rgba(255,255,255,0.1);
    width: 35px;
    height: 35px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    margin-right: 10px;
    transition: background 0.3s ease;
}

.social-icons a:hover {
    background: var(--rapid-blue);
}

.footer-bottom {
    background-color: rgba(0,0,0,0.2);
    padding: 20px 0;
    border-top: 1px solid rgba(255,255,255,0.05);
}

.footer-bottom-flex {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: #a0aec0;
}

.footer-legal a {
    color: #a0aec0;
    text-decoration: none;
    margin-left: 20px;
}

.footer-legal a:hover {
    color: var(--white);
}

/* =========================================
   10. Scroll Animations
   ========================================= */
.scroll-fade {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.scroll-fade.visible {
    opacity: 1;
    transform: translateY(0);
}

/* =========================================
   11. Unified Responsive Media Queries
   ========================================= */

/* Tablets & Smaller Desktops */
@media (max-width: 992px) {
    .category-grid, .contact-grid { 
        grid-template-columns: repeat(2, 1fr); 
    }
    
    .resources-container { 
        flex-direction: column; 
    }
    
    .resources-sidebar { 
        flex: none; 
        width: 100%; 
        margin-bottom: 30px; 
    }
    
    .resources-grid { 
        width: 100%; 
    }
    
    .articles-grid { 
        grid-template-columns: 1fr; 
    }
    
    .styled-form {
        padding: 30px 20px;
    }
}

/* Mobile Devices */
@media (max-width: 768px) {
    /* Header Adjustments */
    .utility-flex {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
    
    .nav-flex {
        flex-direction: row; /* Keeps them on the same line */
        justify-content: space-between; /* Spreads them apart */
        align-items: center;
        position: relative;
        width: 100%;
    }
    
    .mobile-menu-toggle {
        display: block;
        margin-left: auto; /* Forces the icon all the way to the right edge */
    }
    
    .main-nav ul {
        display: none;
        flex-direction: column;
        width: 100%;
        text-align: center;
        background: var(--bg-light);
        padding: 20px 0;
        position: absolute;
        top: 100%;
        left: 0;
        z-index: 1000;
        box-shadow: 0 10px 15px rgba(0,0,0,0.1);
        gap: 15px;
    }
    
    .main-nav.active ul {
        display: flex;
    }

    /* Page Hero Adjustments */
    .hero-section {
        justify-content: center;
        padding: 0 20px;
    }
    
    .hero-box {
        text-align: center;
        padding: 30px 20px;
    }

    .page-hero {
        padding: 50px 20px;
    }
    
    .page-hero h1 {
        font-size: 2rem;
    }
    
    /* Dealer Bar Adjustments */
    .dealer-form {
        flex-direction: column;
        width: 100%;
        max-width: 300px;
    }
    
    .dealer-form input {
        border-radius: 4px 4px 0 0;
        width: 100%;
    }
    
    .dealer-form button {
        border-radius: 0 0 4px 4px;
        width: 100%;
    }
    
    /* Grids & Cards */
    .system-grid, .contact-grid, .resources-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .resource-card {
        height: auto;
        border: 1px solid #eaeaea;
    }

    /* Repair/Replace Form Adjustments */
    .checklist-box {
        padding: 25px 20px;
    }
    
    .info-text h2 {
        font-size: 1.4rem;
    }
    
    .btn-blue-outline {
        display: block;
        margin-left: 0 !important;
        margin-top: 15px;
        width: 100%;
    }
    
    .info-text .btn-blue {
        display: block;
        width: 100%;
        text-align: center;
    }

    /* Footer Adjustments */
    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-col h4::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .footer-bottom-flex {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
}
/* =========================================
   12. Chatbot — Floating Button & Panel
   ========================================= */

/* The circular launcher button */
#chat-launcher {
  position: fixed;
  bottom: 28px;
  right: 28px;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--rapid-blue);
  color: #fff;
  border: none;
  cursor: pointer;
  box-shadow: 0 6px 24px rgba(0, 73, 133, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  z-index: 9999;
  transition: background 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
}

#chat-launcher:hover {
  background: var(--rapid-navy);
  transform: scale(1.08);
  box-shadow: 0 10px 30px rgba(0, 42, 84, 0.45);
}

/* Pulse ring to draw attention on first load */
#chat-launcher::after {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 2px solid var(--rapid-blue);
  animation: chat-pulse 2.5s ease-out infinite;
  opacity: 0;
}

@keyframes chat-pulse {
  0%   { transform: scale(1);   opacity: 0.7; }
  100% { transform: scale(1.7); opacity: 0; }
}

/* The chat panel — hidden by default, slides up when open */
#chat-container {
  position: fixed;
  bottom: 100px;
  right: 28px;
  width: 340px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 12px 40px rgba(0, 42, 84, 0.18);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  z-index: 9998;

  /* Hidden state */
  opacity: 0;
  transform: translateY(20px) scale(0.97);
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

/* Open state — toggled via JS */
#chat-container.chat-open {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: all;
}

/* Header bar */
#chat-header {
  background: linear-gradient(135deg, var(--rapid-navy) 0%, var(--rapid-blue) 100%);
  color: #fff;
  padding: 16px 18px;
  display: flex;
  align-items: center;
  gap: 12px;
}

#chat-header-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}

#chat-header-info {
  flex: 1;
}

#chat-header-name {
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.3px;
}

#chat-header-status {
  font-size: 12px;
  opacity: 0.8;
  margin-top: 1px;
}

#chat-close-btn {
  background: none;
  border: none;
  color: rgba(255,255,255,0.75);
  font-size: 18px;
  cursor: pointer;
  padding: 0;
  line-height: 1;
  transition: color 0.2s;
  flex-shrink: 0;
}

#chat-close-btn:hover {
  color: #fff;
  background: none;
}

/* Message area */
#chat-box {
  height: 280px;
  padding: 16px;
  overflow-y: auto;
  background: #f4f6f8;
  display: flex;
  flex-direction: column;
  gap: 10px;
  scrollbar-width: thin;
  scrollbar-color: #c4cdd6 transparent;
}

#chat-box::-webkit-scrollbar { width: 5px; }
#chat-box::-webkit-scrollbar-thumb { background: #c4cdd6; border-radius: 10px; }

/* Message bubbles */
.user-msg, .bot-msg {
  padding: 10px 14px;
  border-radius: 14px;
  max-width: 82%;
  word-wrap: break-word;
  font-size: 14px;
  line-height: 1.5;
}

.user-msg {
  background: var(--rapid-blue);
  color: #fff;
  align-self: flex-end;
  border-bottom-right-radius: 4px;
}

.bot-msg {
  background: #fff;
  color: var(--text-dark);
  align-self: flex-start;
  border-bottom-left-radius: 4px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
}

/* Input row */
#input-area {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 14px;
  border-top: 1px solid #e8edf2;
  background: #fff;
}

#user-input {
  flex: 1;
  padding: 10px 14px;
  border: 1px solid #dde3ea;
  border-radius: 50px;
  outline: none;
  font-size: 14px;
  font-family: inherit;
  transition: border-color 0.2s;
  background: #f4f6f8;
}

#user-input:focus {
  border-color: var(--rapid-blue);
  background: #fff;
}

#send-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--rapid-blue);
  color: #fff;
  border: none;
  cursor: pointer;
  font-size: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background 0.2s, transform 0.15s;
  padding: 0;
}

#send-btn:hover {
  background: var(--rapid-navy);
  transform: scale(1.08);
}

/* Mobile adjustments */
@media (max-width: 480px) {
  #chat-container {
    width: calc(100vw - 32px);
    right: 16px;
    bottom: 90px;
  }
  #chat-launcher {
    right: 16px;
    bottom: 16px;
  }
}