
.zzz-has-tooltip {
    position: relative;
    cursor: pointer;
}

.zzz-tooltip {
    display: none;
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    min-width: 260px;
    max-width: 400px;
    padding: 0.75rem 1rem;
    background: #1a1a2e;
    color: #eee;
    border-radius: 8px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    z-index: 9999;
    font-size: 0.8rem;
    line-height: 1.6;
    pointer-events: none;
}

.zzz-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: #1a1a2e;
}

.zzz-has-tooltip:hover > .zzz-tooltip,
.zzz-has-tooltip:focus > .zzz-tooltip {
    display: block;
}

.zzz-tooltip p {
    margin: 0 0 0.3rem 0;
}

.zzz-tooltip p:last-child {
    margin-bottom: 0;
}

.zzz-tooltip .zzz-keyword {
    color: var(--color-accent, #FFC731);
}

.zzz-tooltip__title {
    font-weight: 700;
    font-size: 0.85rem;
    margin-bottom: 0.4rem;
    color: #fff;
}

@media (max-width: 767px) {
    .zzz-tooltip {
        left: 0;
        transform: none;
        min-width: 220px;
    }

    .zzz-tooltip::after {
        left: 24px;
        transform: none;
    }
}



.zzz-tooltip__cat {
    display: inline-block;
    font-size: 0.65rem;
    padding: 0.1rem 0.4rem;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.12);
    color: #aaa;
    margin-bottom: 0.3rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.zzz-tooltip__portrait {
    display: block;
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 50%;
    margin: 0.4rem auto;
    border: 2px solid rgba(255, 255, 255, 0.15);
}

.zzz-tooltip__icon {
    display: inline-block;
    width: 20px;
    height: 20px;
    vertical-align: middle;
    margin-right: 0.3rem;
}

span.zzz-has-tooltip {
    text-decoration-line: underline;
    text-decoration-style: dotted;
    text-decoration-color: rgba(100, 100, 120, 0.4);
    text-underline-offset: 2px;
}


span.zzz-agent-name.zzz-has-tooltip {
    font-weight: 700;
    text-decoration-style: solid;
    text-decoration-color: rgba(100, 100, 120, 0.3);
    margin: 0 0.20em;
}

.zzz-tooltip__desc {
    display: block;
    margin: 0.3rem 0 0;
}

.zzz-tooltip__inactive {
    opacity: 0.45;
}

span.zzz-wengine-name.zzz-has-tooltip {
    font-weight: 600;
    text-decoration-style: solid;
    text-decoration-color: rgba(180, 140, 60, 0.35);
    margin: 0 0.15em;
}

span.zzz-disc-name.zzz-has-tooltip {
    font-weight: 600;
    text-decoration-style: solid;
    text-decoration-color: rgba(60, 140, 180, 0.35);
    margin: 0 0.15em;
}

span.zzz-attr-text[data-attr] { font-weight: 600; }

.zzz-we-var { color: var(--zzz-we-var-color, #1A8300); font-weight: 700; font-variant-numeric: tabular-nums; }

.zzz-prerelease-notice { display: flex; align-items: center; gap: 10px; margin: 0 0 14px; padding: 10px 14px; border-radius: 8px; background: rgba(245, 136, 40, .10); border: 1px solid rgba(245, 136, 40, .45); font-size: 13px; line-height: 1.5; color: #3a4050; }
.zzz-prerelease-notice__tag { flex: none; font-size: 11px; font-weight: 700; letter-spacing: .04em; padding: 3px 8px; border-radius: 4px; background: var(--preset-color-accent, #f58828); color: #fff; }

.zzz-nanoka-term {
    text-decoration: underline dotted;
    text-underline-offset: 3px;
    text-decoration-color: color-mix(in srgb, currentColor 55%, transparent);
}
.zzz-nanoka-term > .zzz-tooltip { white-space: normal; text-align: left; }
