/* PyToolbox - 在线工具箱主样式 */

/* ============ 基础变量 ============ */
:root {
    /* 主色调 */
    --primary-color: #4a90e2;
    --primary-hover: #357abd;
    --primary-light: #e8f2ff;
    
    /* 辅助色 */
    --secondary-color: #6c757d;
    --success-color: #28a745;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #17a2b8;
    
    /* 中性色 */
    --text-primary: #2c3e50;
    --text-secondary: #606266;
    --text-muted: #909399;
    --border-color: #e4e7ed;
    --background-color: #f5f7fa;
    
    /* 导航宽度 */
    --nav-width: 260px;
    --nav-bg: #ffffff;
    
    /* 圆角 */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    
    /* 阴影 */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.16);
    
    /* 过渡 */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
}

/* ============ 基础重置 ============ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Roboto, Arial, sans-serif;
    font-size: 14px;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--background-color);
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--primary-hover);
}

/* ============ 布局 ============ */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.main-layout {
    display: flex;
    min-height: 100vh;
}

.content-wrapper {
    flex: 1;
    margin-left: var(--nav-width);
    padding: 24px;
    transition: margin-left var(--transition-normal);
    min-height: 100vh;
}

/* 移动端响应式 */
@media (max-width: 768px) {
    .content-wrapper {
        margin-left: 0;
        padding: 16px;
        padding-top: 60px;
    }
}

/* ============ 左侧导航 ============ */
.toolbox-nav {
    position: fixed;
    left: 0;
    top: 0;
    width: var(--nav-width);
    height: 100vh;
    background: var(--nav-bg);
    border-right: 1px solid var(--border-color);
    z-index: 1000;
    display: flex;
    flex-direction: column;
    transition: transform var(--transition-normal);
    overflow: hidden;
}

/* 导航头部 */
.nav-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    background: linear-gradient(135deg, var(--primary-color) 0%, #667eea 100%);
    color: #fff;
    flex-shrink: 0;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-brand .fa-toolbox {
    font-size: 20px;
}

.brand-text {
    font-size: 16px;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.nav-close {
    display: none;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: #fff;
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: background var(--transition-fast);
}

.nav-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* 搜索框 */
.nav-search {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-color);
    flex-shrink: 0;
}

.search-box {
    position: relative;
    display: flex;
    align-items: center;
}

.search-box .fa-search {
    position: absolute;
    left: 12px;
    color: var(--text-muted);
    font-size: 12px;
}

.search-box input {
    width: 100%;
    padding: 8px 12px 8px 36px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 13px;
    transition: all var(--transition-fast);
}

.search-box input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--primary-light);
}

/* 搜索下拉提示 */
.search-dropdown {
    margin-top: 4px;
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    max-height: 260px;
    overflow-y: auto;
}

.search-dropdown-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    color: var(--text-primary);
    font-size: 13px;
    cursor: pointer;
    transition: background 0.15s;
    border-bottom: 1px solid var(--background-color);
}

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

.search-dropdown-item:hover {
    background: var(--primary-light);
    color: var(--primary-color);
}

.search-dropdown-item .sdi-icon {
    font-size: 14px;
    color: var(--primary-color);
    width: 18px;
    text-align: center;
}

.search-dropdown-item .sdi-name { flex: 1; }

.search-dropdown-item .sdi-cat {
    font-size: 11px;
    color: var(--text-muted);
    background: var(--background-color);
    padding: 2px 8px;
    border-radius: 10px;
}

.search-dropdown-empty {
    padding: 16px;
    text-align: center;
    color: var(--text-muted);
    font-size: 13px;
}

/* 导航内容 */
.nav-content {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
}

/* 首页链接 */
.nav-home {
    padding: 8px;
    border-bottom: 1px solid var(--border-color);
}

.home-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-weight: 500;
    transition: all var(--transition-fast);
}

.home-link:hover {
    background: var(--primary-light);
    color: var(--primary-color);
}

.home-link .fa-home {
    font-size: 16px;
}

/* 分类列表 */
.nav-categories {
    padding: 8px;
}

.nav-category {
    margin-bottom: 4px;
    border-radius: var(--radius-md);
    overflow: hidden;
}

.category-header {
    display: flex;
    align-items: center;
    padding: 10px 12px;
    cursor: pointer;
    color: var(--text-primary);
    font-weight: 500;
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
    user-select: none;
}

.category-header:hover {
    background: var(--primary-light);
}

.category-icon {
    font-size: 16px;
    color: var(--primary-color);
    width: 20px;
    text-align: center;
    margin-right: 10px;
}

.category-name {
    flex: 1;
    font-size: 14px;
}

.category-count {
    font-size: 12px;
    color: var(--text-muted);
    background: var(--background-color);
    padding: 2px 8px;
    border-radius: 10px;
    margin-right: 8px;
}

.category-arrow {
    font-size: 12px;
    color: var(--text-muted);
    transition: transform var(--transition-normal);
}

.nav-category.expanded .category-arrow {
    transform: rotate(180deg);
}

/* 工具列表 */
.category-tools {
    list-style: none;
    max-height: 0;
    overflow: hidden;
    transition: max-height var(--transition-normal);
}

.nav-category.expanded .category-tools {
    max-height: 1000px;
}

.tool-item {
    margin: 2px 0;
}

.tool-item a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px 8px 42px;
    color: var(--text-secondary);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.tool-item a:hover {
    background: var(--primary-light);
    color: var(--primary-color);
}

.tool-item.active a {
    background: var(--primary-light);
    color: var(--primary-color);
    font-weight: 500;
}

.tool-icon {
    font-size: 14px;
    width: 16px;
    text-align: center;
}

.tool-name {
    font-size: 13px;
}

/* 空状态 */
.nav-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 40px 20px;
    color: var(--text-muted);
}

.nav-empty .fa-inbox {
    font-size: 32px;
    margin-bottom: 10px;
    opacity: 0.5;
}

/* 导航底部 */
.nav-footer {
    padding: 12px 16px;
    border-top: 1px solid var(--border-color);
    background: var(--background-color);
    flex-shrink: 0;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-primary);
}

.user-info .fa-user-circle {
    font-size: 20px;
    color: var(--primary-color);
}

.user-info span {
    flex: 1;
    font-weight: 500;
}

.admin-link,
.logout-link {
    color: var(--text-muted);
    padding: 4px;
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
}

.admin-link:hover,
.logout-link:hover {
    color: var(--primary-color);
    background: var(--primary-light);
}

.login-link {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-primary);
    padding: 8px 12px;
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.login-link:hover {
    background: var(--primary-light);
    color: var(--primary-color);
}

/* 移动端导航 */
@media (max-width: 768px) {
    .toolbox-nav {
        transform: translateX(-100%);
    }
    
    .toolbox-nav.expanded {
        transform: translateX(0);
    }
    
    .nav-close {
        display: block;
    }
    
    .mobile-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        z-index: 999;
        display: none;
        opacity: 0;
        transition: opacity var(--transition-normal);
    }
    
    .mobile-overlay.show {
        display: block;
        opacity: 1;
    }
}

/* ============ 移动端导航按钮 ============ */
.nav-toggle {
    position: fixed;
    left: 16px;
    top: 16px;
    z-index: 1001;
    background: var(--primary-color);
    color: #fff;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    cursor: pointer;
    box-shadow: var(--shadow-md);
    transition: all var(--transition-fast);
    display: none;
}

.nav-toggle:hover {
    background: var(--primary-hover);
    transform: scale(1.05);
}

@media (max-width: 768px) {
    .nav-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
    }
}

/* ============ 工具卡片 ============ */
.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.tool-card {
    background: #fff;
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-normal);
    border: 1px solid var(--border-color);
}

.tool-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary-color);
}

.tool-card-icon {
    width: 56px;
    height: 56px;
    background: var(--primary-light);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
}

.tool-card-icon i {
    font-size: 28px;
    color: var(--primary-color);
}

.tool-card h3 {
    font-size: 16px;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.tool-card p {
    color: var(--text-secondary);
    font-size: 13px;
    margin-bottom: 16px;
    line-height: 1.5;
}

.tool-card .btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: var(--primary-color);
    color: #fff;
    border-radius: var(--radius-md);
    font-size: 13px;
    transition: all var(--transition-fast);
}

.tool-card .btn:hover {
    background: var(--primary-hover);
    transform: translateX(4px);
}

/* ============ 工具详情页 ============ */
.tool-detail {
    background: #fff;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    overflow: hidden;
}

.tool-detail-header {
    padding: 24px 30px;
    background: linear-gradient(135deg, var(--primary-light) 0%, #fff 100%);
    border-bottom: 1px solid var(--border-color);
}

.tool-detail-header h1 {
    font-size: 24px;
    color: var(--text-primary);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.tool-detail-header h1 i {
    color: var(--primary-color);
}

.tool-detail-header .meta {
    display: flex;
    gap: 20px;
    color: var(--text-secondary);
    font-size: 13px;
}

.tool-detail-header .meta i {
    margin-right: 6px;
    color: var(--primary-color);
}

.tool-detail-content {
    padding: 30px;
    min-height: 300px;
}

.tool-description {
    color: var(--text-secondary);
    padding: 16px;
    background: var(--background-color);
    border-radius: var(--radius-md);
    margin-bottom: 24px;
    line-height: 1.8;
}

/* ============ 分类页面 ============ */
.category-header-page {
    background: #fff;
    border-radius: var(--radius-lg);
    padding: 30px;
    margin-bottom: 24px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
}

.category-header-page h1 {
    font-size: 24px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.category-header-page h1 i {
    color: var(--primary-color);
}

.category-header-page p {
    color: var(--text-secondary);
}

/* ============ 工具栏 ============ */
.toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 16px;
}

.toolbar h2 {
    font-size: 20px;
    color: var(--text-primary);
}

.toolbar .actions {
    display: flex;
    gap: 12px;
}

/* ============ 按钮 ============ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    border: none;
    transition: all var(--transition-fast);
}

.btn-primary {
    background: var(--primary-color);
    color: #fff;
}

.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
}

.btn-secondary {
    background: var(--secondary-color);
    color: #fff;
}

.btn-secondary:hover {
    background: #5a6268;
}

.btn-success {
    background: var(--success-color);
    color: #fff;
}

.btn-danger {
    background: var(--danger-color);
    color: #fff;
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-outline:hover {
    background: var(--primary-color);
    color: #fff;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 12px;
}

.btn-lg {
    padding: 12px 24px;
    font-size: 16px;
}

/* ============ 消息提示 ============ */
.flash-messages {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 2000;
    max-width: 400px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.flash-message {
    padding: 14px 20px;
    border-radius: var(--radius-md);
    font-size: 14px;
    box-shadow: var(--shadow-md);
    animation: slideIn 0.3s ease;
    display: flex;
    align-items: center;
    gap: 10px;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.flash-message.success {
    background: var(--success-color);
    color: #fff;
}

.flash-message.error {
    background: var(--danger-color);
    color: #fff;
}

.flash-message.info {
    background: var(--info-color);
    color: #fff;
}

.flash-message.warning {
    background: var(--warning-color);
    color: #333;
}

/* ============ 分页 ============ */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 30px;
}

.pagination a,
.pagination span {
    padding: 8px 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    transition: all var(--transition-fast);
}

.pagination a:hover {
    background: var(--primary-light);
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.pagination .active {
    background: var(--primary-color);
    color: #fff;
    border-color: var(--primary-color);
}

/* ============ 评论区域 ============ */
.comments-section {
    margin-top: 32px;
    border-top: 1px solid var(--border-color);
    padding-top: 32px;
}

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

.comments-header h3 {
    font-size: 18px;
    color: var(--text-primary);
}

.comments-header .comment-count {
    color: var(--text-muted);
    font-size: 14px;
}

/* 评论表单 */
.comment-form {
    background: var(--background-color);
    padding: 20px;
    border-radius: var(--radius-md);
    margin-bottom: 24px;
}

.comment-form textarea {
    width: 100%;
    min-height: 100px;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 14px;
    resize: vertical;
    transition: all var(--transition-fast);
}

.comment-form textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--primary-light);
}

.comment-form-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 12px;
}

.rating-select {
    display: flex;
    align-items: center;
    gap: 8px;
}

.rating-select span {
    color: var(--text-secondary);
    font-size: 13px;
}

.rating-select .stars {
    display: flex;
    gap: 4px;
}

.rating-select .star {
    font-size: 20px;
    color: #ddd;
    cursor: pointer;
    transition: color var(--transition-fast);
}

.rating-select .star.active,
.rating-select .star:hover {
    color: var(--warning-color);
}

/* 评论列表 */
.comments-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.comment-item {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px;
    transition: all var(--transition-fast);
}

.comment-item:hover {
    border-color: var(--primary-color);
}

.comment-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.comment-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--primary-light);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    font-weight: 600;
}

.comment-meta {
    flex: 1;
}

.comment-author {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 14px;
}

.comment-time {
    color: var(--text-muted);
    font-size: 12px;
}

.comment-rating {
    display: flex;
    gap: 2px;
}

.comment-rating .fa-star {
    font-size: 12px;
    color: #ddd;
}

.comment-rating .fa-star.active {
    color: var(--warning-color);
}

.comment-content {
    color: var(--text-secondary);
    line-height: 1.8;
    font-size: 14px;
}

.comment-footer {
    display: flex;
    gap: 16px;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--border-color);
}

.comment-action {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--text-muted);
    font-size: 13px;
    cursor: pointer;
    transition: color var(--transition-fast);
}

.comment-action:hover {
    color: var(--primary-color);
}

/* 回复列表 */
.comment-replies {
    margin-top: 16px;
    padding-left: 52px;
    border-left: 2px solid var(--border-color);
}

.reply-item {
    padding: 12px;
    background: var(--background-color);
    border-radius: var(--radius-sm);
    margin-bottom: 8px;
}

.reply-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.reply-author {
    font-weight: 500;
    color: var(--primary-color);
    font-size: 13px;
}

.reply-time {
    color: var(--text-muted);
    font-size: 11px;
}

.reply-content {
    color: var(--text-secondary);
    font-size: 13px;
    line-height: 1.6;
}

/* ============ 辅助类 ============ */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mt-4 { margin-top: 32px; }

.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }
.mb-4 { margin-bottom: 32px; }

.p-1 { padding: 8px; }
.p-2 { padding: 16px; }
.p-3 { padding: 24px; }
.p-4 { padding: 32px; }

.d-flex { display: flex; }
.align-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-1 { gap: 8px; }
.gap-2 { gap: 16px; }

.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}

.empty-state i {
    font-size: 48px;
    margin-bottom: 20px;
    opacity: 0.5;
}

.empty-state h3 {
    margin-bottom: 10px;
    color: var(--text-secondary);
}

/* ============ 工具样式 ============ */
.tool-container {
    background: var(--background-color);
    padding: 24px;
    border-radius: var(--radius-md);
}

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

.tool-input-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--text-primary);
}

.tool-input-group input,
.tool-input-group select,
.tool-input-group textarea {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 14px;
    transition: all var(--transition-fast);
}

.tool-input-group input:focus,
.tool-input-group select:focus,
.tool-input-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--primary-light);
}

.tool-result {
    margin-top: 20px;
    padding: 20px;
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
}

.tool-result h4 {
    margin-bottom: 12px;
    color: var(--text-primary);
}

.tool-result-value {
    font-size: 24px;
    font-weight: 600;
    color: var(--primary-color);
}

/* ============ 右下角悬浮导航 ============ */
.floating-actions {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 1999;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.float-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #fff;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-size: 18px;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    transition: all 0.25s ease;
    opacity: 0;
    transform: translateY(10px);
    pointer-events: none;
    position: relative;
    text-decoration: none;
}

.float-btn.visible {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.float-btn:hover {
    background: var(--primary-color);
    color: #fff;
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.float-btn:active {
    transform: scale(0.92);
}

/* 回到顶部按钮默认隐藏，滚动后显示 */
.float-btn-top {
    opacity: 0;
    transform: translateY(10px);
    pointer-events: none;
}

.float-btn-top.show {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

/* 工具提示 */
.float-btn::after {
    content: attr(data-tooltip);
    position: absolute;
    right: 56px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--text-primary);
    color: #fff;
    font-size: 12px;
    white-space: nowrap;
    padding: 5px 10px;
    border-radius: var(--radius-sm);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s;
}

.float-btn:hover::after {
    opacity: 1;
}

@media (max-width: 768px) {
    .floating-actions {
        right: 14px;
        bottom: 14px;
        gap: 8px;
    }
    
    .float-btn {
        width: 38px;
        height: 38px;
        font-size: 16px;
    }
    
    .float-btn::after {
        display: none;
    }
}

/* ============ 快捷评论弹窗 ============ */
.comment-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.4);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
}

.comment-modal {
    background: #fff;
    border-radius: 12px;
    width: 90%;
    max-width: 380px;
    box-shadow: 0 12px 40px rgba(0,0,0,0.15);
    overflow: hidden;
    animation: modalSlideUp 0.25s ease;
    padding: 20px;
}

@keyframes modalSlideUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.comment-modal-header {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 14px;
}

.comment-modal-header i {
    color: var(--primary-color);
}

.comment-modal-close {
    margin-left: auto;
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 14px;
    padding: 4px;
    border-radius: 4px;
    transition: color 0.15s;
}

.comment-modal-close:hover {
    color: var(--text-primary);
}

.comment-modal textarea {
    width: 100%;
    min-height: 80px;
    padding: 10px 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 14px;
    resize: vertical;
    font-family: inherit;
    box-sizing: border-box;
    transition: border-color 0.2s;
}

.comment-modal input.quick-comment-nickname {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 14px;
    margin-bottom: 10px;
    box-sizing: border-box;
    transition: border-color 0.2s;
}

.comment-modal input.quick-comment-nickname:focus,
.comment-modal textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--primary-light);
}

.comment-modal-status {
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 13px;
    margin-top: 10px;
}

.comment-modal-status.success {
    background: #d4edda;
    color: #155724;
}

.comment-modal-status.error {
    background: #f8d7da;
    color: #721c24;
}

.comment-modal-status.warning {
    background: #fff3cd;
    color: #856404;
}

.comment-modal-submit {
    width: 100%;
    margin-top: 14px;
    padding: 10px;
    background: var(--primary-color);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.comment-modal-submit:hover {
    background: var(--primary-hover);
}

.comment-modal-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

@media (max-width: 768px) {
    .comment-modal {
        width: 95%;
        max-width: none;
        border-radius: 10px;
        padding: 16px;
    }
}
