.g3-chatbot {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 9999;
    font-family: inherit;
}

.g3-chatbot-toggle {
    width: 58px;
    height: 58px;
    border-radius: 50%;
    border: 1px solid rgba(79, 70, 229, 0.2);
    background: #ffffff;
    color: #0f172a;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 18px 45px rgba(92, 86, 226, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.g3-chatbot-icon {
    width: 38px;
    height: 38px;
    background: url("../img/g3-chatbot-icon.svg") center/contain no-repeat;
}

.g3-chatbot-label {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

.g3-chatbot-panel {
    position: absolute;
    right: 0;
    bottom: 70px;
    width: min(360px, calc(100vw - 40px));
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 16px;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.18);
    display: none;
    flex-direction: column;
    overflow: hidden;
}

.g3-chatbot-panel.is-open {
    display: flex;
}

.g3-chatbot-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 14px;
    background: linear-gradient(135deg, rgba(29, 78, 216, 0.12), rgba(124, 58, 237, 0.12));
    font-weight: 700;
}

.g3-chatbot-close {
    border: none;
    background: transparent;
    font-size: 20px;
    cursor: pointer;
    color: var(--text);
}

.g3-chatbot-body {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 12px 14px;
    max-height: 260px;
    overflow-y: auto;
}

.g3-chatbot-msg {
    padding: 8px 10px;
    border-radius: 10px;
    font-size: 0.92rem;
    line-height: 1.4;
    max-width: 85%;
}

.g3-chatbot-msg.bot {
    background: #f1f5f9;
    color: var(--text);
    align-self: flex-start;
}

.g3-chatbot-msg.user {
    background: linear-gradient(135deg, var(--accent), var(--accent-2));
    color: #ffffff;
    align-self: flex-end;
}

.g3-chatbot-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.g3-chatbot-chip {
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text);
    border-radius: 999px;
    padding: 6px 12px;
    font-size: 0.82rem;
    cursor: pointer;
}

.g3-chatbot-chip:hover {
    border-color: rgba(124, 58, 237, 0.4);
}

.g3-chatbot-form {
    display: flex;
    gap: 8px;
    padding: 12px 14px 14px;
    border-top: 1px solid var(--border);
}

.g3-chatbot-links {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 0 14px 8px;
}

.g3-chatbot-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 10px;
    border-radius: 10px;
    border: 1px solid var(--border);
    color: var(--text);
    text-decoration: none;
    background: var(--surface);
    font-size: 0.9rem;
}

.g3-chatbot-link--highlight {
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.08), rgba(99, 102, 241, 0.12));
    border-color: rgba(79, 70, 229, 0.35);
    box-shadow: 0 10px 24px rgba(79, 70, 229, 0.15);
    font-weight: 600;
}

.g3-chatbot-link:hover {
    border-color: rgba(124, 58, 237, 0.4);
}

.g3-chatbot-input {
    flex: 1;
    border-radius: 10px;
    border: 1px solid var(--border);
    padding: 8px 10px;
    font-size: 0.92rem;
}

.g3-chatbot-send {
    border: none;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--accent), var(--accent-2));
    color: #ffffff;
    font-weight: 700;
    padding: 8px 12px;
    cursor: pointer;
}

@media (max-width: 640px) {
    .g3-chatbot {
        right: 16px;
        bottom: 16px;
    }

    .g3-chatbot-panel {
        bottom: 68px;
    }
}
