/**
 * Claude Chat Widget Styles
 * Version: 7.2.0 - Complete with Scale Animations
 */

#claude-chat-container {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
}

#chat-button {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: #000ad7;
    color: white;
    padding: 3px 20px 3px 3px;
    border-radius: 30px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 9999;
    transition: transform 0.3s, box-shadow 0.3s;
    font-size: 16px;
    font-weight: 500;
    min-height: 38px;
}

#chat-button:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 16px rgba(0,0,0,0.2);
}

#chat-box {
    position: fixed;
    bottom: 90px;
    right: 20px;
    width: 380px;
    height: 500px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.15);
    z-index: 10000;
    display: flex;
    flex-direction: column;
    resize: both;
    overflow: auto;
    min-width: 300px;
    min-height: 400px;
    max-width: 600px;
    max-height: 80vh;
    transform-origin: bottom right;
}

/* Scale animations */
#chat-box.scale-up {
    animation: scaleUp 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

#chat-box.scale-down {
    animation: scaleDown 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes scaleUp {
    from {
        transform: scale(0);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes scaleDown {
    from {
        transform: scale(1);
        opacity: 1;
    }
    to {
        transform: scale(0);
        opacity: 0;
    }
}

#chat-messages::-webkit-scrollbar {
    width: 6px;
}

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

#chat-messages::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 3px;
}

#chat-messages::-webkit-scrollbar-thumb:hover {
    background: #555;
}

.message-user {
    margin-bottom: 15px;
    text-align: right;
}

.message-user > div {
    background: #000ad7;
    color: white;
    padding: 12px 16px;
    border-radius: 18px;
    border-bottom-right-radius: 4px;
    max-width: 80%;
    display: inline-block;
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
    text-align: left;
}

.message-bot {
    margin-bottom: 15px;
}

.message-bot > div {
    background: white;
    padding: 12px 16px;
    border-radius: 18px;
    border-bottom-left-radius: 4px;
    max-width: 80%;
    display: inline-block;
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.typing-indicator {
    display: inline-flex;
    padding: 12px 16px;
    background: white;
    border-radius: 18px;
    border-bottom-left-radius: 4px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.typing-indicator span {
    height: 8px;
    width: 8px;
    background: #999;
    border-radius: 50%;
    display: inline-block;
    margin: 0 2px;
    animation: typing 1.4s infinite;
}

.typing-indicator span:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-indicator span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typing {
    0%, 60%, 100% { 
        transform: translateY(0); 
    }
    30% { 
        transform: translateY(-10px); 
    }
}

@media (max-width: 500px) {
    #chat-box {
        width: calc(100vw - 40px);
        right: 20px;
        left: 20px;
    }
}