/* SEO Influencer Profile 样式文件 */

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    background: #f6f7fb;
    color: #222;
    line-height: 1.6;
}

/* Header */
.top-bar {
    background: linear-gradient(90deg, #ff3b6a, #8b1d6b);
    padding: 16px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: white;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6px 12px;
    height: 100%;
}

.logo svg {
    height: 1em;
    width: auto;
    display: block;
}

.cta {
    background: white;
    color: #8b1d6b;
    border: none;
    padding: 10px 20px;
    border-radius: 20px;
    font-weight: 600;
    cursor: pointer;
    font-size: 14px;
    transition: transform 0.2s;
    text-decoration: none;
    display: inline-block;
}

.cta:hover {
    transform: scale(1.05);
    text-decoration: none;
    color: #8b1d6b;
}

/* Breadcrumb */
.breadcrumb {
    padding: 12px 24px;
    font-size: 14px;
    color: #666;
    background: white;
    border-bottom: 1px solid #eee;
}

.breadcrumb a {
    color: #666;
    text-decoration: none;
}

.breadcrumb a:hover {
    color: #ff3b6a;
}

/* Container */
.container {
    padding: 24px;
    max-width: 1400px;
    margin: 0 auto;
}

/* Profile Card */
.profile-card {
    background: white;
    border-radius: 12px;
    padding: 32px;
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 32px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    margin-bottom: 24px;
}

.profile-left {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    overflow: visible; /* 允许 tooltip 显示 */
}

.avatar-wrapper {
    position: relative;
    margin-bottom: 16px;
}

.avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.tiktok-badge {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 32px;
    height: 32px;
    background: #000;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 3px solid white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.tiktok-badge::before {
    content: '♫';
    color: white;
    font-size: 16px;
    font-weight: bold;
}

.profile-left h1 {
    font-size: 28px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 4px;
    max-width: 100%;
    /* 移除 overflow: hidden 和 text-overflow: ellipsis，由 JavaScript 处理截断 */
    white-space: nowrap;
    position: relative;
}

/* CSS Tooltip for nickname - 显示在右侧，避免被 overflow: hidden 裁剪 */
/* 使用更具体的选择器确保样式优先级 */
.profile-left h1.nickname-tooltip {
    overflow: visible; /* 允许 tooltip 显示 */
    position: relative;
    cursor: pointer;
}

.nickname-tooltip::after {
    content: attr(data-tooltip);
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
    margin-left: 8px;
    padding: 6px 10px;
    background: #333;
    color: #fff;
    font-size: 12px;
    white-space: nowrap;
    border-radius: 4px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.1s ease-in-out;
    z-index: 1000;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.nickname-tooltip::before {
    content: '';
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
    margin-left: 2px;
    border: 5px solid transparent;
    border-right-color: #333;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.1s ease-in-out;
    z-index: 1001;
}

.nickname-tooltip:hover::after,
.nickname-tooltip:hover::before {
    opacity: 1;
}


.profile-left h2 {
    font-size: 28px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 4px;
}

.username {
    color: #777;
    font-size: 16px;
    margin-bottom: 12px;
    max-width: 100%;
    /* 移除 overflow: hidden 和 text-overflow: ellipsis，由 JavaScript 处理截断 */
    white-space: nowrap;
    position: relative;
}

/* CSS Tooltip for username - 显示在右侧，避免被 overflow: hidden 裁剪 */
.username-tooltip {
    cursor: pointer;
    overflow: visible; /* 允许 tooltip 显示 */
}

.username-tooltip::after {
    content: attr(data-tooltip);
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
    margin-left: 8px;
    padding: 6px 10px;
    background: #333;
    color: #fff;
    font-size: 12px;
    white-space: nowrap;
    border-radius: 4px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.1s ease-in-out;
    z-index: 1000;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.username-tooltip::before {
    content: '';
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
    margin-left: 2px;
    border: 5px solid transparent;
    border-right-color: #333;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.1s ease-in-out;
    z-index: 1001;
}

.username-tooltip:hover::after,
.username-tooltip:hover::before {
    opacity: 1;
}


.meta {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 16px;
    font-size: 14px;
    color: #666;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.meta-icon {
    width: 16px;
    height: 16px;
    display: inline-block;
}

.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
}

.tags span {
    display: inline-block;
    background: #ffe3ea;
    color: #d92c5c;
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 12px;
    font-weight: 500;
}

/* Profile Right */
.profile-right {
    display: flex;
    flex-direction: column;
}

.bio {
    font-size: 15px;
    color: #444;
    line-height: 1.6;
    margin-bottom: 24px;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.stat {
    background: #fafbff;
    padding: 20px;
    border-radius: 10px;
    transition: transform 0.2s, box-shadow 0.2s;
}

.stat:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.stat h4 {
    font-size: 13px;
    font-weight: 500;
    color: #4a4a4a;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.stat h4.red {
    color: #e62e4d;
    font-weight: 600;
}

.info-icon {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #e0e0e0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    color: #666;
    cursor: pointer;
    margin-left: 6px;
    position: relative;
    z-index: 10;
    pointer-events: auto;
    flex-shrink: 0;
    vertical-align: middle;
}

.info-icon:hover {
    background: #d0d0d0;
}

/* 自定义tooltip - 立即显示，无延迟，横向显示，单行显示 */
.info-icon::after {
    content: attr(data-tooltip);
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
    margin-left: 8px;
    padding: 6px 10px;
    background: #333;
    color: #fff;
    font-size: 12px;
    white-space: nowrap;
    border-radius: 4px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.1s ease-in-out;
    z-index: 1000;
    font-weight: normal;
    line-height: 1.4;
    text-align: left;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.info-icon::before {
    content: '';
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
    margin-left: 2px;
    border: 5px solid transparent;
    border-right-color: #333;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.1s ease-in-out;
    z-index: 1001;
}

.info-icon:hover::after,
.info-icon:hover::before {
    opacity: 1;
}

.stat p {
    font-size: 32px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 8px;
    line-height: 1.2;
}

.stat p.light-gray {
    color: #b0b0b0;
    font-weight: 600;
}

.stat small {
    font-size: 12px;
    color: #777;
    display: flex;
    align-items: center;
    gap: 6px;
}

.stat small.positive {
    color: #1dbf73;
    font-weight: 500;
}

/* Icons */
.arrow-up {
    width: 0;
    height: 0;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-bottom: 7px solid #1dbf73;
    margin-top: 2px;
}

.icon-video {
    width: 14px;
    height: 14px;
    background: #1dbf73;
    border-radius: 2px;
    position: relative;
    flex-shrink: 0;
}

.icon-video::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-40%, -50%);
    width: 0;
    height: 0;
    border-left: 4px solid white;
    border-top: 2.5px solid transparent;
    border-bottom: 2.5px solid transparent;
}

.icon-people {
    width: 14px;
    height: 14px;
    background: #1dbf73;
    border-radius: 50%;
    position: relative;
    flex-shrink: 0;
}

.icon-people::before,
.icon-people::after {
    content: '';
    position: absolute;
    background: white;
    border-radius: 50%;
}

.icon-people::before {
    width: 5px;
    height: 5px;
    top: 2px;
    left: 2px;
}

.icon-people::after {
    width: 5px;
    height: 5px;
    top: 2px;
    right: 2px;
}

.unlock-button {
    width: 100%;
    margin-top: 12px;
    padding: 10px 16px;
    border: 1.5px solid #ffc0cb;
    background: white;
    border-radius: 6px;
    color: #e62e4d;
    font-weight: 600;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.2s;
    text-decoration: none;
}

a.unlock-button {
    color: #e62e4d;
}

a.unlock-button:hover {
    color: #e62e4d;
}

.unlock-button:hover {
    background: #fff5f7;
    border-color: #ff91a4;
}

.lock-icon {
    width: 14px;
    height: 14px;
    position: relative;
}

.lock-icon::before {
    content: '';
    position: absolute;
    width: 10px;
    height: 8px;
    border: 2px solid currentColor;
    border-radius: 2px;
    top: 4px;
    left: 2px;
}

.lock-icon::after {
    content: '';
    position: absolute;
    width: 6px;
    height: 4px;
    border: 2px solid currentColor;
    border-top: none;
    border-radius: 0 0 2px 2px;
    top: 0;
    left: 4px;
}

/* Contact Section */
.contact-similar-section {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.contact-card,
.similar-card {
    background: white;
    padding: 24px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    width: 100%;
}

/* Bottom Image Container */
.bottom-image-container {
    position: relative;
    width: 100%;
    margin-top: 24px;
    overflow: hidden;
    border-radius: 12px;
}

.bottom-image {
    width: 100%;
    height: auto;
    display: block;
    filter: blur(3px);
    transform: scale(1.05);
    transition: filter 0.3s ease;
}

.bottom-image-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 1;
}

.bottom-image-container .contact-card {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-width: 700px;
    width: calc(100% - 48px);
    margin: 0;
    z-index: 10;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.35), 0 0 0 1px rgba(255, 255, 255, 0.95);
    border: none;
    backdrop-filter: blur(10px);
    animation: fadeInUp 0.5s ease-out;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.bottom-image-container:hover .contact-card {
    transform: translate(-50%, -50%) scale(1.02);
    box-shadow: 0 20px 56px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(255, 255, 255, 1);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translate(-50%, -40%);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%);
    }
}

.contact-card h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 20px;
    color: #1a1a1a;
}

.input-group {
    margin-bottom: 16px;
}

.input-group label {
    display: block;
    font-size: 12px;
    color: #777;
    margin-bottom: 6px;
    font-weight: 500;
}

.input-group input {
    width: 100%;
    padding: 10px 12px;
    border-radius: 8px;
    border: 1px solid #eee;
    background: #f8f9fc;
    font-size: 14px;
}

.unlock-btn {
    width: 100%;
    background: #e62e4d;
    color: white;
    border: none;
    padding: 12px;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    font-size: 14px;
    margin-top: 8px;
    transition: background 0.2s;
}

.unlock-btn:hover {
    background: #d92c5c;
}

.hint {
    text-align: center;
    font-size: 12px;
    color: #888;
    margin-top: 12px;
}

.similar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.similar-header h3 {
    font-size: 18px;
    font-weight: 600;
    color: #1a1a1a;
}

.verified {
    font-size: 12px;
    color: #4caf50;
    font-weight: 500;
}

.creator-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: min-content;
    gap: 16px;
    overflow: visible; /* 允许 tooltip 显示 */
}

.creator {
    background: #fafbff;
    padding: 16px;
    border-radius: 10px;
    transition: transform 0.2s;
    overflow: visible; /* 允许 tooltip 显示 */
}

.creator:hover {
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.creator-top {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-bottom: 10px;
}

.creator-top img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.creator-top > div {
    flex: 1;
    min-width: 0;
    overflow: hidden;
}

.creator-top strong {
    display: block;
    font-size: 12px;
    color: #1a1a1a;
    margin-bottom: 2px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.creator-top small {
    display: block;
    font-size: 11px;
    color: #777;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.creator p {
    font-size: 11px;
    color: #555;
    line-height: 1.4;
    /* 移除 -webkit-line-clamp，由 JavaScript 处理截断 */
    overflow: visible; /* 允许 tooltip 显示 */
    margin: 0;
}

/* CSS Tooltip for recommend reason - 显示在下方，支持多行文本 */
.recommend-reason-tooltip {
    position: relative;
    cursor: pointer;
}

.recommend-reason-tooltip::after {
    content: attr(data-tooltip);
    position: absolute;
    left: 50%;
    bottom: 100%;
    transform: translateX(-50%);
    margin-bottom: 8px;
    padding: 8px 12px;
    background: #333;
    color: #fff;
    font-size: 12px;
    white-space: normal;
    max-width: 400px;
    min-width: 300px;
    word-wrap: break-word;
    border-radius: 4px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.1s ease-in-out;
    z-index: 10000;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    text-align: left;
    line-height: 1.4;
    display: block;
}

.recommend-reason-tooltip::before {
    content: '';
    position: absolute;
    left: 50%;
    bottom: 100%;
    transform: translateX(-50%);
    margin-bottom: 2px;
    border: 5px solid transparent;
    border-top-color: #333;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.1s ease-in-out;
    z-index: 10001;
}

.recommend-reason-tooltip:hover::after,
.recommend-reason-tooltip:hover::before {
    opacity: 1;
}


/* Modal */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal.show {
    display: flex;
}

.modal-content {
    background: white;
    padding: 32px;
    border-radius: 16px;
    text-align: center;
    max-width: 420px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.modal-content h2 {
    font-size: 24px;
    margin-bottom: 12px;
    color: #1a1a1a;
}

.modal-content span {
    color: #ff3b6a;
}

.modal-content p {
    color: #666;
    margin-bottom: 24px;
}

.primary {
    background: #ff3b6a;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 24px;
    font-weight: 600;
    cursor: pointer;
    font-size: 14px;
    margin-right: 8px;
}

.secondary {
    background: none;
    border: none;
    color: #666;
    cursor: pointer;
    font-size: 14px;
}

/* Responsive */
@media (max-width: 1024px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .creator-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .profile-card {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .profile-left {
        align-items: center;
    }
    
    .profile-left h1 {
        text-align: center;
        max-width: 100%;
    }
    
    .profile-left .username {
        text-align: center;
        max-width: 100%;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }


    .creator-grid {
        grid-template-columns: 1fr;
    }
    
    .contact-card {
        position: relative;
        top: auto;
        left: auto;
        transform: none;
        width: 100%;
        margin: 24px auto 0;
    }
    
    .bottom-image-container {
        margin-top: 24px;
    }
}

