@media (min-width: 768px) {
    .chat-container { width: min(98vw, 1920px); height: min(98vh, 1080px); }
    .header { padding: 24px 32px; }
    .messages { padding: 35px; }
    .message { padding: 14px 28px; font-size: 18px; max-width: 88%; line-height:1.5;} /* size was 20; padding was 18,28... padding now 14, change to 13?*/
    .input-area { padding: 24px; gap: 16px; }
    #user-input { padding: 20px 28px; font-size: 20px; border-radius: 50px; }
}

/* ================= MOBILE FIX ================= */
@media (max-width: 767px) {
    html, body {
        width: 100%;
        height: 100%;
        overflow: hidden;
    }

    body {
        display: flex;
        align-items: stretch;
        justify-content: stretch;
        height: 100dvh;
    }

    .chat-container {
        width: 100vw;
        height: 100dvh;
        max-width: none;
        max-height: none;
        border: none;
        border-radius: 0;
        box-shadow: none;
    }

    .header {
        height: 82px !important;
        min-height: 82px !important;
        padding: 4px 8px !important;
        border-bottom: 2px solid #3a4150;
    }
    
    .header .logo-part {
        left: 8px !important;
        top: auto !important;
        bottom: 2px !important;
        transform: none !important;
    }
    
    .header .logo-part .aou-logo {
        width: 108px !important;
        height: auto !important;
    }
    
    .header .text-part {
        left: 50% !important;
        top: auto !important;
        bottom: 2px !important;
        transform: translateX(-50%) !important;
    }
    
    .steve-logo img {
        width: 140px !important;
        height: auto !important;
        margin-top: 0 !important;
    }

    /* Mobile header buttons */
    
    /* Hide buttons not needed on mobile */
    .exit-btn,
    #contact-btn,
    #email-btn {
        display: none !important;
    }
    
    /* Keep only: mute, search, website, info */
    #mute-btn,
    #search-btn,
    #website-btn,
    #info-btn {
        position: absolute !important;
        top: 48px !important;
        bottom: auto !important;
        width: 24px !important;
        height: 24px !important;
        padding: 0 !important;
    }
    
    /* Bottom row, same area where X/contact/email/info were */
    #info-btn {
        right: 8px !important;
    }
    
    #website-btn {
        right: 38px !important;
    }
    
    #search-btn {
        right: 68px !important;
    }
    
    #mute-btn {
        right: 98px !important;
    }
    
    /* Mobile icon size */
    #info-btn img,
    #website-btn img,
    #search-btn img,
    #mute-btn img {
        width: 18px !important;
        height: 18px !important;
    }
    
    /* Mobile logout button */
    #logout-btn {
        top: 6px !important;
        right: 8px !important;
        padding: 5px 13px !important;
        font-size: 90% !important;
        border-radius: 6px !important;
    }

    .messages {
        padding: 12px;
        scrollbar-gutter: auto;
    }

    .message {
        max-width: 92%;
        font-size: 15px;
        line-height: 1.4;
        margin-bottom: 10px;
    }

    .user,
    .bot {
        padding: 10px 13px;
        max-width: 92%;
    }

    .input-area {
        padding: 9px;
        gap: 7px;
        align-items: center;
    }

    #user-input {
        min-width: 0;
        font-size: 15px;
        padding: 12px 13px;
        border-radius: 26px;
    }

    #mic-btn,
    #send-btn {
        width: 52px;
        height: 52px;
        min-width: 52px;
        padding: 0;
    }

    .mic-gif {
        width: 58%;
        height: 58%;
    }

    .send-icon {
        width: 31px;
        height: 31px;
        transform: translateX(2px);
    }

    #waveform {
        width: 34px;
        height: 25px;
        bottom: 5px;
        right: 58px;
    }

    #waveform .bar {
        width: 4px;
    }
}