/* AI share buttons for SCH long-form pages. */
.ai-share {
    position: relative;
    display: flex;
    flex-wrap: wrap;
    gap: 0.7rem 0.85rem;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    box-sizing: border-box;
    margin: 1.25rem 0 0;
    padding: 0.75rem 0.875rem;
    overflow: hidden;
    color: var(--text-primary, #f8fafc);
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(12px) saturate(1.2);
    -webkit-backdrop-filter: blur(12px) saturate(1.2);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 1rem;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 4px 16px rgba(0, 0, 0, 0.2);
}

.ai-share::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(69, 244, 255, 0.055), transparent 36%);
    pointer-events: none;
}

.ai-share-copy,
.ai-share-actions {
    position: relative;
    z-index: 1;
}

.ai-share-title {
    margin: 0;
    color: #fff;
    font-family: var(--font-display, sans-serif);
    font-size: clamp(0.94rem, 1.35vw, 1.08rem);
    font-weight: 800;
    line-height: 1.1;
}

.ai-share-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.42rem;
    justify-content: flex-end;
}

.ai-share-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.38rem;
    min-height: 34px;
    padding: 0.42rem 0.58rem;
    color: #f8fafc;
    background: rgba(255, 255, 255, 0.035);
    border: 1px solid rgba(255, 255, 255, 0.095);
    border-radius: 10px;
    font-size: 0.78rem;
    font-weight: 750;
    text-decoration: none;
    white-space: nowrap;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
    transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.ai-share-btn:hover,
.ai-share-btn:focus-visible {
    transform: translateY(-1px);
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(69, 244, 255, 0.35);
    box-shadow: 0 8px 22px rgba(69, 244, 255, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.ai-share-btn:focus-visible {
    outline: 2px solid var(--accent-secondary, #45f4ff);
    outline-offset: 3px;
}

.ai-share-icon {
    width: 1.16rem;
    height: 1.16rem;
    flex: 0 0 auto;
    object-fit: contain;
}

.article-hero .ai-share,
.attack-hero .ai-share,
.hkd-hero .ai-share {
    max-width: none;
}

.attack-hero .ai-share {
    margin-top: 1.35rem;
}

.hkd-hero .ai-share {
    border-color: rgba(239, 68, 68, 0.16);
}

@media (max-width: 900px) {
    .ai-share {
        align-items: flex-start;
    }

    .ai-share-actions {
        justify-content: flex-start;
    }
}

@media (max-width: 520px) {
    .ai-share {
        margin-top: 1rem;
        padding: 0.75rem;
        border-radius: 14px;
    }

    .ai-share-actions {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        width: 100%;
    }

    .ai-share-btn {
        justify-content: center;
    }
}
