/* ============================================================
   酷克温控 CMS - 全局样式
   ============================================================ */

:root {
    --primary: #0d9488;
    --primary-dark: #0f766e;
    --primary-light: #14b8a6;
    --primary-soft: #ccfbf1;
    --primary-softer: #f0fdfa;

    --accent: #3b82f6;
    --accent-soft: #dbeafe;
    --warn: #f59e0b;
    --warn-soft: #fef3c7;
    --danger: #ef4444;
    --danger-soft: #fee2e2;
    --success: #22c55e;
    --success-soft: #dcfce7;

    --bg: #f8fafc;
    --surface: #ffffff;
    --border: #e2e8f0;
    --text: #1e293b;
    --text-light: #64748b;
    --text-lighter: #94a3b8;

    --shadow-sm: 0 1px 2px rgba(0,0,0,.05);
    --shadow: 0 1px 3px rgba(0,0,0,.1), 0 1px 2px rgba(0,0,0,.06);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,.1), 0 2px 4px -2px rgba(0,0,0,.05);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,.1), 0 4px 6px -4px rgba(0,0,0,.05);

    --radius-sm: 6px;
    --radius: 10px;
    --radius-lg: 16px;
    --transition: .25s cubic-bezier(.4,0,.2,1);
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--primary); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--primary-dark); }
img { max-width: 100%; display: block; }

/* ============ 顶部导航 ============ */
.topbar {
    position: sticky; top: 0; z-index: 100;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
}
.topbar-inner {
    max-width: 1200px; margin: 0 auto; padding: 0 24px;
    height: 64px; display: flex; align-items: center; justify-content: space-between;
}
.logo { display: flex; align-items: center; gap: 10px; font-size: 18px; font-weight: 700; color: var(--text); }
.logo-icon {
    width: 36px; height: 36px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    border-radius: 10px; display: flex; align-items: center; justify-content: center;
    color: #fff; font-size: 18px; box-shadow: 0 2px 8px rgba(var(--primary-rgb),.3);
}
.nav-links { display: flex; gap: 4px; align-items: center; }
.nav-links a {
    padding: 8px 16px; border-radius: var(--radius-sm);
    color: var(--text-light); font-size: 15px; font-weight: 500; transition: all var(--transition);
}
.nav-links a:hover { background: var(--primary-softer); color: var(--primary); }
.nav-links a.active { background: var(--primary); color: #fff; }

/* ============ 顶栏搜索 ============ */
.topbar-search {
    display: flex; align-items: center; position: relative;
    flex: 1; max-width: 420px; margin: 0 16px;
}
.topbar-search .s-ico { position: absolute; left: 14px; color: var(--text-lighter); font-size: 14px; pointer-events: none; }
.topbar-search input {
    width: 100%; padding: 9px 16px 9px 38px; border-radius: 30px;
    border: 1px solid var(--border); background: var(--bg); font-size: 14px; font-family: inherit; color: var(--text);
    transition: all var(--transition);
}
.topbar-search input:focus { outline: none; border-color: var(--primary-light); background: #fff; box-shadow: 0 0 0 3px var(--primary-soft); }
.topbar-search .s-btn { display: none; }

/* ============ 内联搜索 ============ */
.inline-search { display: flex; align-items: center; position: relative; gap: 8px; margin-bottom: 20px; max-width: 460px; }
.inline-search .s-ico { position: absolute; left: 14px; color: var(--text-lighter); font-size: 14px; pointer-events: none; }
.inline-search input {
    flex: 1; padding: 10px 14px 10px 38px; border: 1px solid var(--border); border-radius: var(--radius);
    font-size: 14px; font-family: inherit; color: var(--text); transition: all var(--transition);
}
.inline-search input:focus { outline: none; border-color: var(--primary-light); box-shadow: 0 0 0 3px var(--primary-soft); }
.inline-search .clear-q { font-size: 13px; color: var(--text-lighter); white-space: nowrap; }
.inline-search .clear-q:hover { color: var(--primary); }
@media (max-width: 600px) {
    .topbar-search { max-width: none; margin: 0 8px; }
    .topbar-inner { gap: 4px; }
}

/* ============ 容器 ============ */
.container { max-width: 1200px; margin: 0 auto; padding: 32px 24px; }
.page-header { margin-bottom: 28px; }
.page-header h1 { font-size: 28px; font-weight: 800; }
.page-header p { color: var(--text-light); margin-top: 6px; font-size: 15px; }

/* ============ Hero ============ */
.hero {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 50%, var(--primary-light) 100%);
    border-radius: var(--radius-lg); padding: 44px 40px; margin-bottom: 36px;
    color: #fff; position: relative; overflow: hidden;
}
.hero::after {
    content: ''; position: absolute; top: -50%; right: -20%;
    width: 400px; height: 400px; background: rgba(255,255,255,.08); border-radius: 50%;
}
.hero::before {
    content: ''; position: absolute; bottom: -30%; left: -10%;
    width: 300px; height: 300px; background: rgba(255,255,255,.06); border-radius: 50%;
}
.hero h1 { font-size: 30px; font-weight: 800; margin-bottom: 10px; position: relative; z-index: 1; }
.hero p { font-size: 16px; opacity: .9; position: relative; z-index: 1; }
.hero-stats { display: flex; gap: 24px; margin-top: 24px; position: relative; z-index: 1; flex-wrap: wrap; }
.hero-stat {
    background: rgba(255,255,255,.15); backdrop-filter: blur(10px);
    border-radius: var(--radius); padding: 14px 22px; text-align: center; min-width: 100px;
}
.hero-stat .num { font-size: 26px; font-weight: 800; }
.hero-stat .label { font-size: 13px; opacity: .85; margin-top: 2px; }

/* ============ 首页双栏 ============ */
.home-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
@media (max-width: 768px) { .home-grid { grid-template-columns: 1fr; } }

.section-card { background: var(--surface); border-radius: var(--radius-lg); box-shadow: var(--shadow); overflow: hidden; }
.section-card-header {
    display: flex; align-items: center; justify-content: space-between;
    padding: 18px 24px; border-bottom: 1px solid var(--border);
}
.section-card-header h2 { font-size: 17px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.icon { width: 32px; height: 32px; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: 16px; }
.icon-ann { background: var(--warn-soft); color: var(--warn); }
.icon-vid { background: var(--accent-soft); color: var(--accent); }
.icon-cat { background: var(--primary-soft); color: var(--primary); }
.section-card-body { padding: 8px; }
.more-link { font-size: 14px; color: var(--text-lighter); font-weight: 500; }
.more-link:hover { color: var(--primary); }

/* ============ 公告项 ============ */
.ann-item {
    display: flex; align-items: flex-start; gap: 12px;
    padding: 13px 16px; border-radius: var(--radius); transition: background var(--transition); cursor: pointer;
}
.ann-item:hover { background: var(--primary-softer); }
.ann-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--text-lighter); margin-top: 7px; flex-shrink: 0; }
.ann-item.pinned .ann-dot { background: var(--warn); }
.ann-item.pinned { background: var(--warn-soft); }
.ann-content { flex: 1; min-width: 0; }
.ann-title {
    font-size: 15px; font-weight: 600; color: var(--text);
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.ann-title .pin-badge {
    display: inline-block; font-size: 11px; background: var(--warn); color: #fff;
    padding: 1px 6px; border-radius: 4px; margin-right: 6px; vertical-align: middle; font-weight: 700;
}
.ann-meta { font-size: 13px; color: var(--text-lighter); margin-top: 3px; }

/* ============ 视频网格 ============ */
.video-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 20px; }
.video-card {
    background: var(--surface); border-radius: var(--radius-lg); box-shadow: var(--shadow);
    overflow: hidden; transition: all var(--transition); cursor: pointer;
}
.video-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-3px); }
.video-thumb { position: relative; aspect-ratio: 16/9; background: #1e293b; overflow: hidden; }
.video-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.video-card:hover .video-thumb img { transform: scale(1.05); }
.video-thumb-ph {
    width: 100%; height: 100%; display: flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, #1e293b, #334155); color: rgba(255,255,255,.5); font-size: 42px;
}
.video-duration {
    position: absolute; bottom: 8px; right: 8px;
    background: rgba(0,0,0,.75); color: #fff; font-size: 12px; font-weight: 600;
    padding: 2px 7px; border-radius: 5px;
}
.play-overlay {
    position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
    background: rgba(0,0,0,0); transition: background var(--transition);
}
.video-card:hover .play-overlay { background: rgba(0,0,0,.25); }
.play-btn {
    width: 54px; height: 54px; border-radius: 50%;
    background: rgba(255,255,255,.92); color: var(--primary); font-size: 22px;
    display: flex; align-items: center; justify-content: center;
    opacity: 0; transform: scale(.8); transition: all var(--transition);
}
.video-card:hover .play-btn { opacity: 1; transform: scale(1); }
.video-info { padding: 14px 16px; }
.video-info h3 { font-size: 15px; font-weight: 600; color: var(--text); line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.video-info .cat-tag {
    display: inline-block; font-size: 12px; background: var(--primary-soft); color: var(--primary-dark);
    padding: 2px 8px; border-radius: 5px; margin-top: 8px;
}
.video-info .v-meta { font-size: 12px; color: var(--text-lighter); margin-top: 6px; }

/* ============ 分类筛选 ============ */
.filter-bar { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 24px; }
.filter-chip {
    padding: 8px 18px; border-radius: 30px; font-size: 14px; font-weight: 500;
    background: var(--surface); border: 1px solid var(--border); color: var(--text-light);
    cursor: pointer; transition: all var(--transition); user-select: none;
}
.filter-chip:hover { border-color: var(--primary-light); color: var(--primary); }
.filter-chip.active { background: var(--primary); border-color: var(--primary); color: #fff; box-shadow: 0 2px 8px rgba(var(--primary-rgb),.25); }
.filter-group-label {
    display: inline-flex; align-items: center; padding: 7px 16px;
    font-size: 13px; font-weight: 700; letter-spacing: .5px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: #fff; border-radius: 30px; user-select: none;
    box-shadow: 0 2px 8px rgba(var(--primary-rgb),.2);
}
.filter-group-label.active-group {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary));
    box-shadow: 0 3px 12px rgba(var(--primary-rgb),.35);
}

/* ============ 资料卡片（分类页/详情页共用） ============ */
.material-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 20px; }
.material-card {
    background: var(--surface); border-radius: var(--radius-lg); box-shadow: var(--shadow);
    overflow: hidden; transition: all var(--transition); display: block; text-decoration: none; color: inherit;
}
.material-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.material-thumb { position: relative; aspect-ratio: 16/9; background: #1e293b; overflow: hidden; }
.material-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.material-card:hover .material-thumb img { transform: scale(1.05); }
.material-thumb-ph { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #1e293b, #334155); color: rgba(255,255,255,.5); font-size: 42px; }
.material-badge { position: absolute; top: 10px; left: 10px; font-size: 12px; font-weight: 600; padding: 3px 10px; border-radius: 20px; background: rgba(255,255,255,.92); backdrop-filter: blur(4px); }
.material-badge.video { color: #2563eb; }
.material-badge.image { color: #ea580c; }
.material-badge.text { color: #7c3aed; }
.material-duration { position: absolute; bottom: 8px; right: 8px; background: rgba(0,0,0,.75); color: #fff; font-size: 12px; font-weight: 600; padding: 2px 7px; border-radius: 5px; }
.material-info { padding: 14px 16px; }
.material-info h3 { font-size: 15px; font-weight: 600; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.material-excerpt { font-size: 13px; color: var(--text-light); margin-top: 6px; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.material-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; font-size: 12px; }
.material-type { font-weight: 600; }
.material-views { color: var(--text-lighter); }
.image-viewer { background: #000; border-radius: var(--radius-lg); padding: 16px; margin-bottom: 20px; }

/* 分类资料页头部 */
.cat-page-header { border-radius: var(--radius-lg); padding: 32px 36px; color: #fff; margin-bottom: 28px; position: relative; overflow: hidden; }
.cat-page-header::after { content: ''; position: absolute; top: -40%; right: -10%; width: 280px; height: 280px; background: rgba(255,255,255,.08); border-radius: 50%; }
.cat-page-parent { font-size: 14px; opacity: .85; margin-bottom: 6px; letter-spacing: 1px; position: relative; z-index: 1; }
.cat-page-header h1 { font-size: 28px; font-weight: 800; position: relative; z-index: 1; }
.cat-page-meta { font-size: 14px; opacity: .9; margin-top: 8px; position: relative; z-index: 1; }


.detail-wrap { max-width: 860px; margin: 0 auto; }
.article {
    background: var(--surface); border-radius: var(--radius-lg); box-shadow: var(--shadow);
    padding: 36px 40px;
}
.article h1 { font-size: 26px; font-weight: 800; margin-bottom: 12px; }
.article-meta { color: var(--text-lighter); font-size: 14px; padding-bottom: 20px; border-bottom: 1px solid var(--border); margin-bottom: 24px; display: flex; gap: 16px; }
.article-body { font-size: 16px; color: #374151; line-height: 1.9; white-space: pre-wrap; word-break: break-word; }
.back-link { display: inline-flex; align-items: center; gap: 6px; margin-bottom: 20px; font-size: 14px; font-weight: 500; }

/* 视频播放页 */
.player-wrap { background: #000; border-radius: var(--radius-lg); overflow: hidden; margin-bottom: 20px; }
.player-wrap video, .player-wrap iframe { width: 100%; aspect-ratio: 16/9; display: block; border: 0; }

/* ============ 空状态 ============ */
.empty-state { text-align: center; padding: 60px 20px; color: var(--text-lighter); }
.empty-state .ico { font-size: 48px; margin-bottom: 12px; opacity: .5; }

/* ============ 按钮 ============ */
.btn {
    display: inline-flex; align-items: center; gap: 6px; justify-content: center;
    padding: 10px 22px; border-radius: var(--radius); font-size: 14px; font-weight: 600;
    border: 1px solid transparent; cursor: pointer; transition: all var(--transition); font-family: inherit;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); color: #fff; box-shadow: 0 4px 12px rgba(var(--primary-rgb),.3); }
.btn-ghost { background: var(--surface); border-color: var(--border); color: var(--text); }
.btn-ghost:hover { background: var(--bg); color: var(--text); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { background: #dc2626; color: #fff; }
.btn-sm { padding: 6px 14px; font-size: 13px; }

/* ============ 页脚 ============ */
.footer { text-align: center; padding: 32px 24px; color: var(--text-lighter); font-size: 13px; border-top: 1px solid var(--border); margin-top: 40px; }

/* ============================================================
   后台管理样式
   ============================================================ */
.admin-body { background: #f1f5f9; }
.admin-layout { display: flex; min-height: 100vh; }

.sidebar {
    width: 240px; background: #0f172a; color: #cbd5e1; flex-shrink: 0;
    position: fixed; top: 0; left: 0; bottom: 0; overflow-y: auto; z-index: 50;
}
.sidebar-brand {
    padding: 20px 20px; display: flex; align-items: center; gap: 10px;
    font-size: 16px; font-weight: 700; color: #fff; border-bottom: 1px solid rgba(255,255,255,.08);
}
.sidebar-brand .logo-icon { width: 32px; height: 32px; }
.sidebar-nav { padding: 12px 12px; }
.sidebar-nav a {
    display: flex; align-items: center; gap: 10px; padding: 11px 14px;
    border-radius: var(--radius-sm); color: #cbd5e1; font-size: 14px; font-weight: 500;
    margin-bottom: 4px; transition: all var(--transition);
}
.sidebar-nav a:hover { background: rgba(255,255,255,.06); color: #fff; }
.sidebar-nav a.active { background: var(--primary); color: #fff; }
.sidebar-nav .nav-ico { font-size: 16px; }
.sidebar-nav .nav-group { font-size: 11px; text-transform: uppercase; color: #64748b; padding: 16px 14px 6px; letter-spacing: .5px; }
.sidebar-footer { padding: 16px; border-top: 1px solid rgba(255,255,255,.08); margin-top: auto; }
.sidebar-footer a { color: #94a3b8; font-size: 13px; display: block; padding: 8px 14px; border-radius: var(--radius-sm); }
.sidebar-footer a:hover { background: rgba(255,255,255,.06); color: #fff; }

.admin-main { flex: 1; margin-left: 240px; min-width: 0; }
.admin-topbar {
    height: 60px; background: var(--surface); border-bottom: 1px solid var(--border);
    display: flex; align-items: center; justify-content: space-between; padding: 0 28px;
    position: sticky; top: 0; z-index: 40;
}
.admin-topbar h1 { font-size: 18px; font-weight: 700; }
.admin-user { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--text-light); }
.admin-user .avatar {
    width: 34px; height: 34px; border-radius: 50%; background: var(--primary-soft); color: var(--primary-dark);
    display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 14px;
}
.admin-content { padding: 28px; }

/* 统计卡片 */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 20px; margin-bottom: 28px; }
.stat-card {
    background: var(--surface); border-radius: var(--radius-lg); padding: 22px 24px;
    box-shadow: var(--shadow); display: flex; align-items: center; gap: 16px;
    transition: all var(--transition);
}
.stat-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.stat-card .stat-ico { width: 52px; height: 52px; border-radius: 14px; display: flex; align-items: center; justify-content: center; font-size: 24px; }
.stat-card .num { font-size: 28px; font-weight: 800; color: var(--text); line-height: 1; }
.stat-card .label { font-size: 14px; color: var(--text-light); margin-top: 6px; }

/* 数据表格 */
.panel {
    background: var(--surface); border-radius: var(--radius-lg); box-shadow: var(--shadow); overflow: hidden;
}
.panel-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 24px; border-bottom: 1px solid var(--border); }
.panel-head h2 { font-size: 16px; font-weight: 700; }
.panel-body { padding: 0; }
.table { width: 100%; border-collapse: collapse; }
.table th {
    text-align: left; font-size: 13px; font-weight: 600; color: var(--text-light);
    padding: 12px 20px; background: #f8fafc; border-bottom: 1px solid var(--border); white-space: nowrap;
}
.table td { padding: 14px 20px; border-bottom: 1px solid var(--border); font-size: 14px; vertical-align: middle; }
.table tr:last-child td { border-bottom: none; }
.table tr:hover td { background: #fafcff; }
.table .thumb-sm { width: 80px; height: 45px; border-radius: 6px; object-fit: cover; background: #1e293b; }
.table .thumb-ph { width: 80px; height: 45px; border-radius: 6px; background: #1e293b; display: flex; align-items: center; justify-content: center; color: #fff; font-size: 14px; }
.row-title { font-weight: 600; color: var(--text); }
.row-sub { font-size: 12px; color: var(--text-lighter); margin-top: 2px; }
.badge { display: inline-block; font-size: 12px; padding: 3px 10px; border-radius: 20px; font-weight: 600; }
.badge-on { background: var(--success-soft); color: #15803d; }
.badge-off { background: var(--danger-soft); color: #b91c1c; }
.badge-pin { background: var(--warn-soft); color: #b45309; }

/* 行操作 */
.row-actions { display: flex; gap: 6px; }
.icon-btn {
    width: 32px; height: 32px; border-radius: var(--radius-sm); border: 1px solid var(--border);
    background: var(--surface); cursor: pointer; display: flex; align-items: center; justify-content: center;
    color: var(--text-light); transition: all var(--transition); font-size: 14px;
}
.icon-btn:hover { background: var(--bg); color: var(--text); }
.icon-btn.del:hover { background: var(--danger-soft); color: var(--danger); border-color: var(--danger); }

/* 表单 */
.form-wrap { max-width: 720px; }
.form-group { margin-bottom: 20px; }
.form-label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 7px; color: var(--text); }
.form-label .req { color: var(--danger); margin-left: 2px; }
.form-control {
    width: 100%; padding: 10px 14px; border: 1px solid var(--border); border-radius: var(--radius);
    font-size: 14px; font-family: inherit; color: var(--text); background: var(--surface); transition: all var(--transition);
}
.form-control:focus { outline: none; border-color: var(--primary-light); box-shadow: 0 0 0 3px var(--primary-soft); }
textarea.form-control { resize: vertical; min-height: 140px; }
.form-hint { font-size: 12px; color: var(--text-lighter); margin-top: 5px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 600px) { .form-row { grid-template-columns: 1fr; } }

/* 登录页 */
.login-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--primary-dark), var(--primary)); padding: 20px; }
.login-card { width: 100%; max-width: 400px; background: var(--surface); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); padding: 40px 36px; }
.login-card .logo { justify-content: center; margin-bottom: 8px; }
.login-card .subtitle { text-align: center; color: var(--text-light); font-size: 14px; margin-bottom: 28px; }
.login-form .form-group { margin-bottom: 18px; }
.alert { padding: 12px 16px; border-radius: var(--radius); font-size: 14px; margin-bottom: 16px; }
.alert-error { background: var(--danger-soft); color: #b91c1c; border: 1px solid #fecaca; }
.alert-success { background: var(--success-soft); color: #15803d; border: 1px solid #bbf7d0; }

/* 上传预览 */
.upload-preview { margin-top: 10px; }
.upload-preview img { max-width: 200px; border-radius: var(--radius); border: 1px solid var(--border); }
.cover-input-mode { display: flex; gap: 16px; align-items: center; margin-bottom: 8px; }
.radio-inline { display: flex; align-items: center; gap: 6px; font-size: 14px; cursor: pointer; }

/* 分页 */
.pagination { display: flex; justify-content: center; gap: 6px; margin-top: 28px; }
.pagination a, .pagination span {
    min-width: 38px; height: 38px; padding: 0 12px; border-radius: var(--radius-sm);
    display: flex; align-items: center; justify-content: center; font-size: 14px;
    background: var(--surface); border: 1px solid var(--border); color: var(--text-light); transition: all var(--transition);
}
.pagination a:hover { border-color: var(--primary-light); color: var(--primary); }
.pagination a.active { background: var(--primary); border-color: var(--primary); color: #fff; }
.pagination .disabled { opacity: .4; cursor: not-allowed; }
.pagination .dots { border: none; background: none; min-width: 18px; color: var(--text-lighter); }

/* 搜索结果 */
.search-count { color: var(--text-light); font-size: 14px; margin-bottom: 16px; }
.search-count b { color: var(--primary); }
.search-results { display: flex; flex-direction: column; gap: 12px; }
.search-row {
    display: flex; gap: 14px; align-items: flex-start;
    background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
    padding: 14px 16px; transition: all var(--transition); cursor: pointer;
}
.search-row:hover { border-color: var(--primary-light); box-shadow: var(--shadow-md); transform: translateY(-1px); }
.sr-thumb {
    width: 64px; height: 64px; flex-shrink: 0; border-radius: 10px;
    display: flex; align-items: center; justify-content: center; font-size: 26px; color: #fff;
}
.sr-ann { background: linear-gradient(135deg, #f59e0b, #fbbf24); }
.sr-vid { background: linear-gradient(135deg, #1e293b, #334155); overflow: hidden; }
.sr-vid img { width: 100%; height: 100%; object-fit: cover; }
.sr-body { flex: 1; min-width: 0; }
.sr-title { font-size: 16px; font-weight: 600; color: var(--text); transition: color var(--transition); }
.search-row:hover .sr-title { color: var(--primary); }
.sr-meta { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--text-lighter); margin: 4px 0 6px; flex-wrap: wrap; }
.sr-type { font-size: 12px; padding: 1px 8px; border-radius: 20px; font-weight: 600; }
.tag-ann { background: var(--warn-soft); color: var(--warn); }
.tag-vid { background: var(--accent-soft); color: var(--accent); }
.sr-excerpt { font-size: 13px; color: var(--text-light); line-height: 1.5;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pin-badge { display: inline-block; font-size: 11px; background: var(--warn); color: #fff;
    padding: 1px 6px; border-radius: 4px; margin-right: 6px; vertical-align: middle; font-weight: 700; }

/* 工具条 */
.toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 20px; flex-wrap: wrap; }
.search-box { position: relative; }
.search-box input { padding-left: 38px; width: 260px; }
.search-box .s-ico { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--text-lighter); }

/* 批量导入结果 */
.batch-result { margin-top: 14px; font-size: 14px; }
.batch-result .ok { color: var(--success); font-weight: 600; }
.batch-result .warn { color: var(--warn); font-weight: 600; }
.batch-result ul { margin: 8px 0 0 18px; color: var(--text-light); }
.batch-result li { margin: 2px 0; }

/* 主题选择器 */
.theme-grid { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-top: 6px; }
.theme-swatch {
    width: 40px; height: 40px; border-radius: 50%; cursor: pointer; border: 3px solid transparent;
    transition: transform var(--transition); position: relative;
}
.theme-swatch:hover { transform: scale(1.1); }
.theme-swatch.active { border-color: var(--text); }
.theme-swatch.active::after {
    content: '✓'; position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
    color: #fff; font-weight: 700; font-size: 16px;
}
.theme-custom { display: flex; align-items: center; gap: 8px; margin-left: 4px; font-size: 13px; color: var(--text-light); }
.theme-custom input[type=color] { width: 40px; height: 40px; border: none; background: none; cursor: pointer; padding: 0; }

/* 响应式后台 */
@media (max-width: 768px) {
    .sidebar { transform: translateX(-100%); transition: transform var(--transition); }
    .sidebar.open { transform: translateX(0); }
    .admin-main { margin-left: 0; }
    .admin-content { padding: 16px; }
    .table { display: block; overflow-x: auto; white-space: nowrap; }
}
.menu-toggle { display: none; background: none; border: none; font-size: 22px; cursor: pointer; color: var(--text); }
@media (max-width: 768px) { .menu-toggle { display: block; } }
