/* Asisten pustakawan LLG — overlay + modal pengumuman */

.llg-ai-launcher {
    position: fixed;
    right: 16px;
    bottom: 16px;
    z-index: 1040;
    width: 88px;
    height: 88px;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
    border-radius: 50%;
    transform-origin: center;
    transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

.llg-ai-launcher::after {
    content: "";
    position: absolute;
    inset: -6px;
    border-radius: 50%;
    border: 2px solid rgba(234, 170, 15, 0.55);
    animation: llg-launcher-pulse 2.4s ease-out infinite;
    pointer-events: none;
}

.llg-ai-launcher.is-panel-open::after {
    animation: none;
    opacity: 0;
}

.llg-ai-launcher.is-panel-open {
    transform: scale(0.92);
}

.llg-ai-launcher img {
    width: 88px;
    height: 88px;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 8px 14px rgba(97, 30, 41, 0.28));
    transition: transform 0.28s ease;
}

.llg-ai-launcher:hover img {
    transform: translateY(-3px);
}

.llg-ai-launcher:focus-visible {
    outline: 3px solid #EAAA0F;
    outline-offset: 3px;
}

.llg-ai-root.llg-ai--survey-open .llg-ai-launcher,
.llg-ai-root.llg-ai--survey-open .llg-ai-panel {
    bottom: calc(16px + var(--llg-survey-h, 180px));
}

body.llg-ai-ready .back-to-top {
    right: 112px;
}

.llg-ai-panel {
    position: fixed;
    right: 16px;
    bottom: 112px;
    z-index: 1041;
    width: 400px;
    max-width: calc(100vw - 24px);
    max-height: min(74vh, 620px);
    display: flex;
    flex-direction: column;
    background: #fff;
    color: #333;
    border-radius: 20px;
    box-shadow:
        0 0 0 1px rgba(97, 30, 41, 0.08),
        0 20px 48px rgba(97, 30, 41, 0.2);
    overflow: hidden;
    opacity: 0;
    transform: translateY(18px) scale(0.96);
    transform-origin: bottom right;
    transition: opacity 0.28s ease, transform 0.36s cubic-bezier(0.22, 1, 0.36, 1);
}

.llg-ai-panel.is-open {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.llg-ai-panel.is-closing {
    pointer-events: none;
}

.llg-ai-panel[hidden] {
    display: none !important;
}

.llg-ai-panel__head {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 12px 12px 14px;
    background: linear-gradient(165deg, #7a2835 0%, #611e29 55%, #3f1219 100%);
    color: #fff;
    flex-shrink: 0;
}

.llg-ai-panel__avatar {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
    box-shadow: 0 0 0 2px rgba(234, 170, 15, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.llg-ai-panel__avatar img {
    width: 44px;
    height: 44px;
    object-fit: contain;
}

.llg-ai-panel__heading {
    flex: 1;
    min-width: 0;
}

.llg-ai-panel__kicker {
    margin: 0;
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #EAAA0F;
}

.llg-ai-panel__title {
    margin: 1px 0 0;
    font-size: 0.98rem;
    font-weight: 700;
    color: #fff;
    line-height: 1.2;
}

.llg-ai-panel__status {
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 3px 0 0;
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.82);
}

.llg-ai-panel__dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #EAAA0F;
    box-shadow: 0 0 0 0 rgba(234, 170, 15, 0.7);
    animation: llg-status-pulse 2s ease-out infinite;
}

.llg-ai-panel.is-thinking .llg-ai-panel__dot {
    background: #fff;
    animation-duration: 0.9s;
}

.llg-ai-icon-btn {
    min-width: 34px;
    height: 34px;
    padding: 0 8px;
    border: 0;
    background: rgba(255, 255, 255, 0.1);
    color: inherit;
    font-size: 0.75rem;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    border-radius: 999px;
    transition: background 0.18s ease;
}

.llg-ai-icon-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.llg-ai-icon-btn--close {
    font-size: 1.35rem;
    font-weight: 400;
}

.llg-ai-icon-btn:focus-visible {
    outline: 2px solid #EAAA0F;
    outline-offset: 2px;
}

.llg-ai-panel__body {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 14px 12px;
    background:
        linear-gradient(180deg, rgba(97, 30, 41, 0.04), transparent 48px),
        #faf6f4;
}

.llg-ai-msg {
    margin-bottom: 12px;
    padding: 10px 12px;
    border-radius: 16px;
    font-size: 0.93rem;
    line-height: 1.45;
}

.llg-ai-msg p {
    margin: 0;
}

.llg-ai-msg--user {
    background: linear-gradient(165deg, #7a2835, #611e29);
    color: #fff;
    margin-left: 36px;
    border-bottom-right-radius: 6px;
}

.llg-ai-msg--bot {
    background: #fff;
    border: 1px solid #efe4dc;
    margin-right: 20px;
    border-bottom-left-radius: 6px;
    box-shadow: 0 4px 12px rgba(97, 30, 41, 0.05);
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 12px;
}

.llg-ai-msg--in {
    animation: llg-msg-in 0.32s cubic-bezier(0.22, 1, 0.36, 1);
}

.llg-ai-msg--typing {
    display: inline-flex;
    width: fit-content;
    padding: 12px 16px;
}

.llg-ai-typing {
    display: flex;
    align-items: center;
    gap: 5px;
    height: 14px;
}

.llg-ai-typing span {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #611e29;
    opacity: 0.3;
    animation: llg-typing 1.1s ease-in-out infinite;
}

.llg-ai-typing span:nth-child(2) {
    animation-delay: 0.16s;
}

.llg-ai-typing span:nth-child(3) {
    animation-delay: 0.32s;
}

.llg-ai-answer {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.llg-ai-answer p {
    margin: 0;
    line-height: 1.55;
}

.llg-ai-answer strong {
    font-weight: 700;
    color: #3a1a20;
}

.llg-ai-answer em {
    font-style: italic;
}

.llg-ai-answer__kicker {
    margin: 0;
    font-size: 0.82rem;
    font-weight: 700;
    line-height: 1.4;
    color: #611e29;
}

.llg-ai-answer__heading {
    margin: 4px 0 0;
    font-size: 0.92rem;
    font-weight: 700;
    line-height: 1.4;
    color: #611e29;
}

.llg-ai-answer__list {
    margin: 0;
    padding-left: 1.15em;
}

.llg-ai-answer__list li + li {
    margin-top: 4px;
}

.llg-ai-answer__doc {
    margin: 0;
    padding: 10px 12px;
    background: #faf6f4;
    border: 1px solid #efe4dc;
    border-radius: 10px;
    font-size: 0.82rem;
    line-height: 1.5;
    white-space: pre-wrap;
    color: #3f2e32;
}

.llg-ai-fold {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
}

.llg-ai-fold__body.is-clamp {
    display: -webkit-box;
    -webkit-line-clamp: 6;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.llg-ai-fold__toggle {
    border: 0;
    background: transparent;
    color: #c74724;
    font: inherit;
    font-size: 0.78rem;
    font-weight: 700;
    padding: 0;
    cursor: pointer;
}

.llg-ai-fold__toggle:hover,
.llg-ai-fold__toggle:focus-visible {
    text-decoration: underline;
    outline: 0;
}

.llg-ai-block-title {
    margin: 0 0 8px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #8a6a6e;
}

.llg-ai-quotes {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.llg-ai-quote {
    padding: 10px 12px;
    background: #faf6f4;
    border: 1px solid #efe4dc;
    border-left: 3px solid #c74724;
    border-radius: 0 12px 12px 0;
}

.llg-ai-quote__title {
    display: block;
    margin: 0 0 6px;
    font-size: 0.86rem;
    font-weight: 700;
    color: #611e29;
    text-decoration: none;
    line-height: 1.35;
}

a.llg-ai-quote__title:hover,
a.llg-ai-quote__title:focus-visible {
    color: #c74724;
    text-decoration: underline;
    outline: 0;
}

.llg-ai-quote__excerpt {
    margin: 0;
    font-size: 0.82rem;
    line-height: 1.5;
    color: #4a3a3d;
    white-space: pre-wrap;
}

.llg-ai-quote .llg-ai-fold + .llg-ai-fold,
.llg-ai-quote .llg-ai-fold + .llg-ai-quote__excerpt,
.llg-ai-quote .llg-ai-quote__excerpt + .llg-ai-fold {
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px dashed #e6d8d2;
}

.llg-ai-docs {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.llg-ai-doc-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 8px 10px;
    background: #fff;
    border: 1px solid #efe4dc;
    border-radius: 12px;
    color: #611e29;
    text-decoration: none;
    transition: border-color 0.16s ease, background 0.16s ease;
}

.llg-ai-doc-link:hover,
.llg-ai-doc-link:focus-visible {
    background: #fff8f4;
    border-color: #c74724;
    outline: 0;
}

.llg-ai-doc-link__name {
    font-size: 0.82rem;
    font-weight: 600;
    line-height: 1.35;
}

.llg-ai-doc-link__hint {
    flex-shrink: 0;
    font-size: 0.72rem;
    font-weight: 700;
    color: #c74724;
}

.llg-ai-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 8px;
}

.llg-ai-chip {
    display: inline-block;
    padding: 5px 11px;
    background: #fff;
    border: 1px solid #611e29;
    color: #611e29;
    border-radius: 999px;
    font-size: 0.82rem;
    text-decoration: none;
    transition: background 0.16s ease, color 0.16s ease;
}

.llg-ai-chip:hover,
.llg-ai-chip:focus-visible {
    background: #611e29;
    color: #fff;
    outline: 0;
}

.llg-ai-disclaimer {
    margin: 0;
    padding: 8px 10px;
    background: #faf6f4;
    border-radius: 10px;
    font-size: 0.74rem;
    line-height: 1.45;
    color: #6b5a5c;
}

.llg-ai-examples {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 0 0 8px;
}

.llg-ai-examples button {
    border: 1px solid rgba(199, 71, 36, 0.35);
    background: #fff;
    color: #611e29;
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 0.78rem;
    cursor: pointer;
    text-align: left;
    transition: background 0.16s ease, border-color 0.16s ease, transform 0.16s ease;
}

.llg-ai-examples button:hover {
    background: #fff4ef;
    border-color: #c74724;
    transform: translateY(-1px);
}

.llg-ai-examples button:focus-visible {
    outline: 2px solid #EAAA0F;
}

.llg-ai-panel__form {
    display: flex;
    align-items: flex-end;
    gap: 8px;
    padding: 10px 12px 12px;
    border-top: 1px solid #efe4dc;
    background: #fff;
    flex-shrink: 0;
}

.llg-ai-panel__form textarea {
    flex: 1;
    min-height: 44px;
    max-height: 96px;
    resize: vertical;
    border: 1px solid #e0d4cc;
    border-radius: 14px;
    padding: 10px 12px;
    font: inherit;
    background: #faf6f4;
    transition: border-color 0.16s ease, background 0.16s ease, box-shadow 0.16s ease;
}

.llg-ai-panel__form textarea:focus-visible {
    outline: 0;
    border-color: #611e29;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(234, 170, 15, 0.35);
}

.llg-ai-panel__form button[type="submit"] {
    background: #c74724;
    color: #fff;
    border: 0;
    border-radius: 14px;
    min-width: 52px;
    height: 44px;
    padding: 0 14px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 6px 14px rgba(199, 71, 36, 0.28);
    transition: background 0.16s ease, transform 0.16s ease;
}

.llg-ai-panel__form button[type="submit"]:hover {
    background: #b13d1e;
    transform: translateY(-1px);
}

.llg-ai-panel__form button[type="submit"]:focus-visible {
    outline: 2px solid #EAAA0F;
    outline-offset: 2px;
}

.llg-ai-panel__form button[type="submit"]:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

@keyframes llg-launcher-pulse {
    0% { transform: scale(0.92); opacity: 0.7; }
    70% { transform: scale(1.12); opacity: 0; }
    100% { transform: scale(1.12); opacity: 0; }
}

@keyframes llg-status-pulse {
    0% { box-shadow: 0 0 0 0 rgba(234, 170, 15, 0.55); }
    70% { box-shadow: 0 0 0 6px rgba(234, 170, 15, 0); }
    100% { box-shadow: 0 0 0 0 rgba(234, 170, 15, 0); }
}

@keyframes llg-msg-in {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes llg-typing {
    0%, 80%, 100% {
        opacity: 0.28;
        transform: translateY(0);
    }
    40% {
        opacity: 1;
        transform: translateY(-3px);
    }
}

.llg-ai-intro {
    position: fixed;
    inset: 0;
    z-index: 1050;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.llg-ai-intro[hidden] {
    display: none !important;
}

.llg-ai-intro__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(33, 20, 18, 0.52);
    opacity: 0;
    transition: opacity 0.28s ease;
}

.llg-ai-intro.is-open .llg-ai-intro__backdrop {
    opacity: 1;
}

.llg-ai-intro__dialog {
    position: relative;
    z-index: 1;
    width: min(840px, 100%);
    max-height: 90vh;
    overflow: hidden;
    background: #fff;
    color: #333;
    border-radius: 20px;
    box-shadow:
        0 0 0 1px rgba(97, 30, 41, 0.08),
        0 24px 48px rgba(97, 30, 41, 0.22);
    opacity: 0;
    transform: translateY(28px) scale(0.96);
    transition: opacity 0.32s ease, transform 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}

.llg-ai-intro.is-open .llg-ai-intro__dialog {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.llg-ai-intro__close {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 2;
    width: 36px;
    height: 36px;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.92);
    color: #611e29;
    font-size: 1.4rem;
    line-height: 1;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.llg-ai-intro__close:hover {
    background: #fff;
    color: #c74724;
}

.llg-ai-intro__close:focus-visible {
    outline: 2px solid #EAAA0F;
    outline-offset: 2px;
}

.llg-ai-intro__grid {
    display: grid;
    grid-template-columns: 320px 1fr;
    min-height: 280px;
}

.llg-ai-intro__stage {
    position: relative;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 12px 8px 0;
    background: linear-gradient(165deg, #7a2835 0%, #611e29 52%, #3f1219 100%);
    overflow: hidden;
}

.llg-ai-intro__glow {
    position: absolute;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(234, 170, 15, 0.42) 0%, rgba(234, 170, 15, 0) 70%);
    animation: llg-intro-glow 3.2s ease-in-out infinite;
}

.llg-ai-intro__mascot {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: none;
    height: auto;
    max-height: 100%;
    object-fit: contain;
    object-position: bottom center;
    filter: drop-shadow(0 10px 16px rgba(0, 0, 0, 0.28));
    animation: llg-intro-float 3.6s ease-in-out infinite;
}

.llg-ai-intro__body {
    padding: 28px 28px 22px;
    overflow-y: auto;
    max-height: 90vh;
}

.llg-ai-intro__kicker {
    margin: 0 0 6px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #c74724;
}

.llg-ai-intro__dialog h2 {
    margin: 0 0 10px;
    color: #611e29;
    font-size: 1.45rem;
    line-height: 1.25;
    font-weight: 700;
}

.llg-ai-intro__welcome {
    margin: 0 0 10px;
    color: #444;
    font-size: 0.98rem;
}

.llg-ai-intro__lead {
    margin: 0 0 14px;
    color: #5a5a5a;
    font-size: 0.92rem;
    line-height: 1.5;
}

.llg-ai-intro__actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 18px;
}

.llg-ai-intro__actions a,
.llg-ai-intro__actions button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 40px;
    padding: 8px 10px;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.84rem;
    line-height: 1.2;
    text-align: center;
    white-space: nowrap;
    cursor: pointer;
    border: 1px solid #611e29;
    background: #fff;
    color: #611e29;
    transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.llg-ai-intro__actions a:hover,
.llg-ai-intro__actions button:hover {
    background: #f7f1ef;
}

.llg-ai-intro__actions .llg-ai-intro__primary {
    background: #c74724;
    border-color: #c74724;
    color: #fff;
    box-shadow: 0 6px 14px rgba(199, 71, 36, 0.28);
}

.llg-ai-intro__actions .llg-ai-intro__primary:hover {
    background: #b13d1e;
    color: #fff;
    transform: translateY(-1px);
}

.llg-ai-intro__actions a:focus-visible,
.llg-ai-intro__actions button:focus-visible {
    outline: 2px solid #EAAA0F;
    outline-offset: 2px;
}

.llg-ai-limits {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 8px;
}

.llg-ai-limits li {
    position: relative;
    padding: 10px 12px 10px 36px;
    border-radius: 10px;
    background: #faf6f4;
    color: #4a3d3f;
    font-size: 0.88rem;
    line-height: 1.4;
    opacity: 0;
    transform: translateY(8px);
}

.llg-ai-intro.is-open .llg-ai-limits li {
    animation: llg-intro-rise 0.4s ease forwards;
}

.llg-ai-intro.is-open .llg-ai-limits li:nth-child(1) { animation-delay: 0.18s; }
.llg-ai-intro.is-open .llg-ai-limits li:nth-child(2) { animation-delay: 0.28s; }
.llg-ai-intro.is-open .llg-ai-limits li:nth-child(3) { animation-delay: 0.38s; }

.llg-ai-limits li::before {
    content: "";
    position: absolute;
    left: 12px;
    top: 14px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #EAAA0F;
    box-shadow: inset 0 0 0 3px #fff;
}

@keyframes llg-intro-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

@keyframes llg-intro-glow {
    0%, 100% { transform: scale(1); opacity: 0.85; }
    50% { transform: scale(1.12); opacity: 1; }
}

@keyframes llg-intro-rise {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 575.98px) {
    .llg-ai-panel {
        right: 0;
        left: 0;
        bottom: 0;
        width: 100%;
        max-width: 100%;
        max-height: min(88vh, 720px);
        border-radius: 20px 20px 0 0;
        transform-origin: bottom center;
    }

    .llg-ai-root.llg-ai--survey-open .llg-ai-panel {
        bottom: 0;
    }

    .llg-ai-panel__head {
        position: relative;
        padding-top: 18px;
        border-radius: 20px 20px 0 0;
    }

    .llg-ai-panel__head::before {
        content: "";
        position: absolute;
        top: 8px;
        left: 50%;
        width: 36px;
        height: 4px;
        margin-left: -18px;
        border-radius: 999px;
        background: rgba(255, 255, 255, 0.38);
    }

    .llg-ai-intro {
        padding: 12px;
        align-items: flex-end;
    }

    .llg-ai-intro__dialog {
        width: 100%;
        max-height: min(92vh, 720px);
        border-radius: 20px 20px 12px 12px;
        overflow-y: auto;
    }

    .llg-ai-intro__grid {
        grid-template-columns: 1fr;
    }

    .llg-ai-intro__stage {
        min-height: 220px;
        padding: 8px 8px 0;
        border-radius: 0;
    }

    .llg-ai-intro__mascot {
        max-width: 200px;
        max-height: 240px;
    }

    .llg-ai-intro__body {
        padding: 16px 16px 18px;
    }

    .llg-ai-intro__lead {
        font-size: 0.86rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .llg-ai-launcher,
    .llg-ai-launcher img,
    .llg-ai-panel,
    .llg-ai-intro__backdrop,
    .llg-ai-intro__dialog,
    .llg-ai-intro__actions a,
    .llg-ai-intro__actions button,
    .llg-ai-examples button,
    .llg-ai-chip,
    .llg-ai-panel__form button[type="submit"] {
        transition: none;
    }

    .llg-ai-launcher::after,
    .llg-ai-panel__dot,
    .llg-ai-msg--in,
    .llg-ai-typing span,
    .llg-ai-intro__mascot,
    .llg-ai-intro__glow,
    .llg-ai-intro.is-open .llg-ai-limits li {
        animation: none;
    }

    .llg-ai-panel,
    .llg-ai-panel.is-open {
        opacity: 1;
        transform: none;
    }

    .llg-ai-intro__dialog,
    .llg-ai-intro.is-open .llg-ai-intro__dialog {
        transform: none;
        opacity: 1;
    }

    .llg-ai-intro__backdrop,
    .llg-ai-intro.is-open .llg-ai-intro__backdrop,
    .llg-ai-limits li {
        opacity: 1;
        transform: none;
    }
}

.llg-ai-ask-this {
    height: 35px;
    padding: 0 12px;
    border: 1px solid #611e29;
    background: #fff;
    color: #611e29;
    border-radius: 5px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
}

.llg-ai-ask-this:focus-visible {
    outline: 2px solid #EAAA0F;
    outline-offset: 2px;
}

.llg-ai-ask-this:hover {
    background: #611e29;
    color: #fff;
}

.llg-ai-facts {
    margin-bottom: 12px;
    padding: 10px 12px;
    background: #fff;
    border: 1px solid #efe4dc;
    border-left: 3px solid #EAAA0F;
    border-radius: 12px;
    font-size: 0.8rem;
    line-height: 1.4;
    max-height: 140px;
    overflow-y: auto;
    box-shadow: 0 4px 12px rgba(97, 30, 41, 0.04);
}

.llg-ai-facts__title {
    margin: 0 0 6px;
    font-weight: 700;
    color: #611e29;
}

.llg-ai-facts p {
    margin: 0 0 4px;
}

.llg-ai-facts a {
    color: #611e29;
}

.llg-ai-scope {
    margin: 0 0 8px;
    padding: 6px 10px;
    border-radius: 999px;
    background: #611e29;
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    line-height: 1.35;
    width: fit-content;
    max-width: 100%;
}

.llg-ai-scope.is-pulse {
    animation: llg-scope-pulse 1.2s ease;
}

@keyframes llg-scope-pulse {
    0%, 100% { box-shadow: none; }
    40% { box-shadow: 0 0 0 4px rgba(234, 170, 15, 0.45); }
}

.llg-ai-prefill-banner {
    margin: 0 0 16px;
    padding: 10px 12px;
    background: #fff8e6;
    border: 1px solid #EAAA0F;
    border-left: 4px solid #611e29;
    color: #611e29;
    font-size: 0.88rem;
    line-height: 1.45;
    border-radius: 4px;
}

.llg-ai-compare,
.llg-ai-outline {
    margin: 0;
    padding: 10px 12px;
    background: #faf6f4;
    border: 1px solid #efe4dc;
    border-left: 3px solid #611e29;
    border-radius: 0 12px 12px 0;
    font-size: 0.82rem;
    line-height: 1.45;
    max-height: 240px;
    overflow-y: auto;
}

.llg-ai-compare__pair {
    margin: 8px 0 0;
    padding-top: 8px;
    border-top: 1px solid #efe7df;
}

.llg-ai-compare__pair p {
    margin: 0 0 4px;
}

.llg-ai-compare__changed {
    color: #c74724;
    font-weight: 600;
}

.llg-ai-outline ul {
    margin: 6px 0 0;
    padding: 0;
    list-style: none;
}

.llg-ai-outline li {
    margin: 0 0 2px;
}

.llg-ai-visual {
    margin: 0 0 20px;
    padding: 16px 18px;
    border: 1px solid #efe4dc;
    border-radius: 12px;
    background: #fff;
}

.llg-ai-visual__head {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.llg-ai-visual__title {
    margin: 0 0 6px;
    font-size: 1.05rem;
    font-weight: 700;
    color: #611e29;
}

.llg-ai-visual__lead {
    margin: 0;
    max-width: 52ch;
    font-size: 0.88rem;
    line-height: 1.5;
    color: #5a4548;
}

.llg-ai-visual__run {
    height: 36px;
    padding: 0 14px;
    border: 0;
    border-radius: 999px;
    background: #c74724;
    color: #fff;
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
}

.llg-ai-visual__run:hover {
    background: #b13d1e;
}

.llg-ai-visual__run:disabled {
    opacity: 0.65;
    cursor: wait;
}

.llg-ai-visual__run:focus-visible {
    outline: 2px solid #EAAA0F;
    outline-offset: 2px;
}

.llg-ai-visual__status {
    margin: 10px 0 0;
    font-size: 0.88rem;
    color: #611e29;
}

.llg-ai-visual__status.is-error {
    color: #c74724;
}

.llg-ai-visual__meta {
    margin-top: 12px;
}

.llg-ai-visual__badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 999px;
    background: #611e29;
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.llg-ai-visual__why,
.llg-ai-visual__caption {
    margin: 8px 0 0;
    font-size: 0.88rem;
    line-height: 1.5;
    color: #3a1a20;
}

.llg-ai-visual__why {
    color: #7a6568;
}

.llg-ai-visual__canvas {
    margin-top: 12px;
    overflow: auto;
    padding: 8px;
    border-radius: 10px;
    background: #faf6f4;
}

.llg-ai-visual__svg {
    display: block;
    width: 100%;
    min-width: 320px;
    height: auto;
}

.llg-ai-visual__note {
    margin: 10px 0 0;
    font-size: 0.8rem;
    color: #7a6568;
}

@media (max-width: 768px) {
    .llg-ai-visual__run {
        width: 100%;
    }
}
