:root {
    --primary-color: #4f6df5;
    --secondary-color: #7986cb;
    --success-color: #4caf50;
    --warning-color: #ff9800;
    --light-bg: #f8f9fa;
    --dark-text: #000000;
    --light-text: #666;
    --border-color: #e0e0e0;
    --card-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    --transition: all 0.3s ease;
}

.custom-comments-system * {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", sans-serif;
}

.custom-comments-container {
    max-width: 800px;
    margin: 0 auto;
}

.comment-section {
    background: white;
    border-radius: 12px;
    box-shadow: var(--card-shadow);
    padding: 5px;
    margin-bottom: 25px;
    transition: var(--transition);
}

.comment-section:hover {
    box-shadow: 0px 6px 16px rgba(0, 0, 0, 0.12);
}

.section-title {
    font-size: 3.5rem;
    margin-bottom: 20px;
    color: #552583;
    display: flex;
    align-items: center;
}

.elementor-kit-886 .section-title {
    font-size: 3.5rem;
}

.form-row {
    display: flex;
    gap: 1px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.input-group {
    flex: 1;
    min-width: 250px;
}

.input-group label {
    display: block;
    margin-bottom: 1px;
    font-weight: 600;
    color: #552583;
    font-size: clamp(0.8125rem, 2.5vw, 3.0625rem);
}

/* 合并重复的输入框样式 */
#custom-comments-system .input-group input,
#custom-comments-system .input-group textarea {
    width: 100%;
    padding: 6px 6px;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    font-size: 3rem;
    transition: var(--transition);
    resize: none;
    min-height: 12px;
    max-height: 400px;
    overflow-y: hidden;
    white-space: pre-wrap;
    word-wrap: break-word;
}

/* 特定输入框样式 */
#custom-comments-system #username {
    font-size: 20px;
    padding: 8px 12px;
    background-color: rgba(248, 249, 250, 0.9);
    min-height: 50px;
    width: 400px;
}

#custom-comments-system #email {
    font-size: 20px;
    padding: 10px 15px;
    background-color: rgba(248, 249, 250, 0.9);
    min-height: 50px;
    width: 400px;
}

#custom-comments-system #comment {
    font-size: 20px;
    padding: 12px 18px;
    border-radius: 8px;
    background-color: rgba(255, 255, 255, 0.95);
    min-height: 150px;
    max-height: 400px;
}

/* 焦点状态 */
#custom-comments-system .input-group input:focus,
#custom-comments-system .input-group textarea:focus {
    outline: none;
    border-color: #552583;
    box-shadow: 0 0 0 3px rgba(85, 37, 131, 0.1);
}

#username:focus {
    border-color: #4CAF50;
    box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.1);
}

#email:focus {
    border-color: #2196F3;
    box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.1);
}

#comment:focus {
    border-color: #FF9800;
    box-shadow: 0 0 0 3px rgba(255, 152, 0, 0.1);
}

#custom-comments-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

#custom-comments-form button {
    align-self: center;
    background-color: #FDB927;
    color: white;
    border: none;
    border-radius: 8px;
    width: 300px; /* 固定宽度 */
    height: 80px; /* 固定高度 */
    font-size: 30px; /* 可以自由调整，不会影响按钮大小 */
    font-weight: 900;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center; /* 水平居中文字 */
    box-sizing: border-box;
}

#custom-comments-form button:hover {
    background-color: #552583;
    transform: translateY(-2px);
}

#comment-message {
    margin-top: 15px;
    padding: 12px 15px;
    border-radius: 8px;
    font-weight: 500;
}

#comment-message.success {
    background-color: rgba(76, 175, 80, 0.1);
    color: var(--success-color);
    border: 1px solid rgba(76, 175, 80, 0.2);
}

#comment-message.error {
    background-color: rgba(255, 152, 0, 0.1);
    color: var(--warning-color);
    border: 1px solid rgba(255, 152, 0, 0.2);
}

.stats-container {
    display: flex;
    gap:24px;
    flex-wrap: wrap;
}

.stat-card {
    flex: 1;
    min-width: 200px;
    background: linear-gradient(135deg, #FDB927, #552583);
    color: white;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    box-shadow: var(--card-shadow);
}

.stat-number {
    font-size: 5rem;
    font-weight: 700;
    margin: 10px 0;
}

.stat-label {
    font-size: 3rem;
    opacity: 0.9;
}


/* 评论列表样式 */
.comment-list {
    padding: 0;
    background-color: white;
}

.comment-item {
    padding: 15px;
    background-color: white;
    border-bottom: 1px solid var(--border-color);
    border-radius: 0px;
}

.comment-item:hover {
    background-color: rgba(79, 109, 245, 0.03);
}

.comment-item:last-child {
    border-bottom: none;
}

/* 评论元数据样式 - 合并重复项 */
.comment-meta {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
    gap: 8px;
    flex-wrap: nowrap;
    width: 100%;
}

.comment-author {
    font-weight: 600;
    font-size: 2.5rem;
    color: var(--primary-color);
    white-space: nowrap;
    flex-shrink: 0;
    width: auto !important;
    display: inline !important;
    max-width: none !important;
}

.comment-email {
    color: var(--secondary-color);
    font-size: 1.5rem;
    white-space: nowrap;
    flex-shrink: 0;
}

.comment-date {
    color: var(--light-text);
    font-size: 1.5rem;
    white-space: nowrap;
    flex-shrink: 0;
}

.comment-content {
    color: var(--dark-text);
    line-height: 1.6;
    font-size: 30px;
}

.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* 精选评论样式 */
.featured-comment {
    border-left: 4px solid #ffcc00 !important;
    background-color: #fff9e6 !important;
    position: relative;
}

.featured-comment:before {
    content: "\f005";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    position: absolute;
    top: 10px;
    right: 10px;
    color: #ffcc00;
    font-size: 1.2rem;
}

/* 评论列表容器样式 */
.comments-list-container {
    margin-bottom: 15px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background-color: #fff;
}

/* 自定义滚动条样式 */
.comments-list-container::-webkit-scrollbar {
    width: 8px;
}

.comments-list-container::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.comments-list-container::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

.comments-list-container::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-color);
}

/* 滚动提示样式 */
.scroll-hint {
    text-align: center;
    color: var(--light-text);
    font-size: 0.9rem;
    padding: 8px;
    background-color: rgba(79, 109, 245, 0.05);
    border-radius: 4px;
}

.scroll-hint i {
    margin-right: 5px;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .comments-list-container {
        max-height: 400px !important;
    }
    
    .form-row {
        flex-direction: column;
        gap: 10px;
    }
    
    .input-group {
        min-width: 100%;
    }
    
    .stats-container {
        flex-direction: column;
    }
    
    .comment-meta {
        flex-wrap: wrap;
    }
    
    .comment-author,
    .comment-email,
    .comment-date {
        font-size: 0.8rem;
    }
}