html, body {
    height: 100%;
    margin: 0;
    padding: 0;
    background: linear-gradient(to right, #f2f6fc, #e9eafc);
    font-family: 'Inter', 'Open Sans', Arial, sans-serif;
    color: #232946;
    min-height: 100vh;
}

.main-container {
    max-width: 700px;
    margin: 40px auto 20px auto;
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 8px 32px 0 rgba(36, 50, 93, 0.14);
    padding: 36px 28px 24px 28px;
}

header {
    text-align: center;
    margin-bottom: 28px;
}

header h1 {
    margin: 0;
    font-size: 2.2em;
    font-weight: 600;
    letter-spacing: -1px;
    color: #3553ad;
}

.subtitle {
    color: #667;
    font-size: 1.08em;
    margin-top: 7px;
}

section {
    margin-bottom: 32px;
}

h2 {
    color: #507be8;
    margin-top: 0;
    margin-bottom: 14px;
    font-weight: 600;
    letter-spacing: -0.5px;
}

.thoughts-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 4px;
}

#toggle-thoughts {
    font-size: 1em;
    color: #507be8;
    background: #e4eafe;
    border: none;
    border-radius: 7px;
    padding: 7px 14px;
    cursor: pointer;
    transition: background 0.2s;
}

#toggle-thoughts:hover, #toggle-thoughts:focus {
    background: #c6d3ff;
}

.chat-box {
    background: #f8faff;
    border: 1px solid #dce3f0;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(56,56,105,0.09);
    min-height: 60px;
    max-height: 200px;
    padding: 18px 15px;
    margin-bottom: 12px;
    overflow-y: auto;
    font-size: 1.06em;
    transition: background 0.2s;
}

.user-box {
    background: #f0f7ef;
}

.speech-msg {
    background: #e4eafe;
    color: #233a66;
    padding: 7px 12px;
    border-radius: 8px;
    margin-bottom: 7px;
    max-width: 90%;
}

.user-msg {
    background: #d3f8d3;
    color: #246634;
    padding: 7px 12px;
    border-radius: 8px;
    margin-bottom: 7px;
    max-width: 90%;
    margin-left: auto;
}

.thought-msg {
    background: #fff3cd;
    color: #98732c;
    padding: 7px 12px;
    border-radius: 8px;
    margin-bottom: 7px;
    max-width: 98%;
}

#assistant-thoughts.collapsed {
    display: none;
}

#user-input-section {
    display: flex;
    gap: 12px;
    margin-top: 8px;
    align-items: flex-end;
    flex-wrap: wrap;
}

textarea {
    flex: 1;
    min-height: 48px;
    max-height: 140px;
    padding: 10px 13px;
    border: 1px solid #b8c0db;
    border-radius: 8px;
    font-size: 1em;
    resize: vertical;
    font-family: inherit;
    outline: none;
    background: #f8faff;
    transition: border-color 0.2s;
}

textarea:focus {
    border-color: #507be8;
}

#send-button {
    padding: 11px 24px;
    font-weight: bold;
    background: linear-gradient(90deg, #507be8 60%, #233a66 100%);
    color: #fff;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s, box-shadow 0.2s, transform 0.1s;
    box-shadow: 0 2px 6px rgba(80,123,232,0.10);
}

#send-button:hover, #send-button:focus {
    background: linear-gradient(90deg, #3553ad 70%, #3553ad 100%);
    box-shadow: 0 4px 12px rgba(80,123,232,0.17);
    transform: translateY(-1px) scale(1.04);
}

footer {
    text-align: center;
    margin: 40px 0 15px 0;
    color: #aab2c8;
    font-size: 0.99em;
    letter-spacing: 0.01em;
}

@media (max-width: 700px) {
    .main-container {
        padding: 16px 2vw 12px 2vw;
        margin: 20px auto 10px auto;
    }
    .chat-box {
        font-size: 0.97em;
        padding: 12px 5px;
        min-width: 0;
    }
    h1 { font-size: 1.4em; }
    h2 { font-size: 1.07em; }
    #send-button {
        padding: 9px 15px;
        font-size: 0.95em;
    }
}

::-webkit-scrollbar {
    width: 8px;
    background: #f2f6fc;
    border-radius: 8px;
}
::-webkit-scrollbar-thumb {
    background: #e4eafe;
    border-radius: 8px;
}
