/**
 * 医院访问统计插件 - 前端样式
 */

.hvs-widget-stats {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.hvs-stats-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.hvs-stat-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
}

.hvs-stat-item:last-child {
    border-bottom: none;
}

.hvs-stat-label {
    font-size: 14px;
    color: #666;
    font-weight: 500;
}

.hvs-stat-value {
    font-size: 18px;
    font-weight: 700;
    color: #22a6b3;
}

.hvs-stat-item.hvs-online .hvs-stat-value {
    color: #10b981;
}

.hvs-stat-item.hvs-online::before {
    content: '';
    display: inline-block;
    width: 8px;
    height: 8px;
    background: #10b981;
    border-radius: 50%;
    margin-right: 8px;
    animation: hvs-pulse 2s infinite;
}

@keyframes hvs-pulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.2);
        opacity: 0.7;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* 短代码样式 */
.hvs-shortcode-stats {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.hvs-stats-shortcode-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.hvs-stats-shortcode-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.hvs-stats-shortcode-list li:last-child {
    border-bottom: none;
}

.hvs-stats-shortcode-list .hvs-label {
    font-size: 15px;
    color: #333;
    font-weight: 500;
}

.hvs-stats-shortcode-list .hvs-value {
    font-size: 20px;
    font-weight: 700;
    color: #22a6b3;
}

/* 在线计数样式 */
.hvs-online-count {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-weight: 700;
    color: #10b981;
    font-size: 18px;
}

.hvs-online-count::before {
    content: '';
    display: inline-block;
    width: 10px;
    height: 10px;
    background: #10b981;
    border-radius: 50%;
    animation: hvs-pulse 2s infinite;
}

/* 地域分布样式 */
.hvs-geo-distribution {
    background: #fff;
    border: 1px solid #e1e4e8;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.hvs-geo-distribution h3 {
    margin: 0 0 15px;
    font-size: 18px;
    font-weight: 600;
    color: #24292e;
}

.hvs-geo-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.hvs-geo-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid #e1e4e8;
}

.hvs-geo-list li:last-child {
    border-bottom: none;
}

.hvs-geo-name {
    font-weight: 500;
    color: #586069;
}

.hvs-geo-count {
    font-weight: 600;
    color: #22a6b3;
    font-size: 16px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .hvs-stat-item,
    .hvs-stats-shortcode-list li {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }

    .hvs-stat-value,
    .hvs-stats-shortcode-list .hvs-value {
        text-align: right;
        width: 100%;
    }
}

/* 主题适配 - 蓝绿色调 */
.hvs-widget-stats .hvs-stat-value {
    color: #22a6b3;
}

.hvs-widget-stats .hvs-stat-item.hvs-online .hvs-stat-value {
    color: #10b981;
}

/* 卡片悬停效果 */
.hvs-widget-stats {
    transition: transform 0.3s, box-shadow 0.3s;
}

.hvs-widget-stats:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}
