:root {
  --primary-color: #8a4bff;
  --primary-light: #b39ddb;
  --primary-dark: #6c3ce0;
  --accent-color: #ffd7e4;
  --success-color: #67c23a;
  --warning-color: #e6a23c;
  --danger-color: #f56c6c;
  --bg-gradient: linear-gradient(135deg, #ffd7e4 0%, #c8f1ff 100%);
  --card-bg: rgba(255, 255, 255, 0.88);
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
  background: var(--bg-gradient);
  background-attachment: fixed;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Noto Sans SC', sans-serif;
  color: #333;
  margin: 0;
  padding: 0;
}

.header-content {
  position: fixed;
  top: 12px;
  left: 12px;
  right: 12px;
  z-index: 999;
  min-height: 64px;
  height: auto;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.98), rgba(247, 247, 255, 0.88));
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(20, 32, 51, 0.12);
  border-radius: 18px;
  box-shadow: 0 10px 28px rgba(20, 32, 51, 0.1);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.admin-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 0 0 auto;
  cursor: pointer;
}

.brand-home {
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 12px;
  padding: 0;
  background: linear-gradient(145deg, #8a4bff 0%, #c4a2ff 100%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 6px 16px rgba(138, 75, 255, 0.25);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.brand-home img {
  width: 28px;
  height: 28px;
  object-fit: contain;
}

.brand-home:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 24px rgba(138, 75, 255, 0.32);
}

.brand-copy {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}

.brand-title {
  font-size: 18px;
  line-height: 1.05;
  font-weight: 700;
  color: #142033;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.brand-subtitle {
  font-size: 11px;
  line-height: 1.2;
  color: #64748b;
  white-space: nowrap;
}

.search-card {
  flex: 0 1 280px;
  min-width: 180px;
  max-width: 380px;
}

.search-card .el-input__inner {
  border-radius: 999px;
  width: 100%;
  height: 38px;
  font-size: 13px;
  border: 1px solid rgba(15, 118, 110, 0.2);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: none;
  padding-left: 34px;
}

.search-card .el-input__inner:focus {
  border-color: rgba(15, 118, 110, 0.42);
  box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.12);
}

.header-stats {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-wrap: nowrap;
  flex: 0 0 auto;
  margin-left: 8px;
}

.stat-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  min-height: 34px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  color: #334155;
  border: 1px solid rgba(15, 118, 110, 0.18);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

.stat-pill i {
  color: #0f766e;
}

.header-content .actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex: 1 1 auto;
  min-width: 0;
}

.header-content .actions > .el-dropdown,
.header-content .actions > .el-button {
  flex: 0 0 auto;
}

.header-action-btn,
.header-icon-btn {
  border: 1px solid rgba(15, 118, 110, 0.22);
  background: rgba(255, 255, 255, 0.95);
  color: #1e293b;
  height: 34px;
  border-radius: 11px;
  padding: 0 10px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  font-size: 13px;
  line-height: 1;
  white-space: nowrap;
  box-sizing: border-box;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.06);
}

.header-action-btn {
  padding: 0 12px;
}

.header-action-btn i {
  pointer-events: none;
  margin: 0 !important;
}

.header-action-btn .el-icon-arrow-down {
  margin-left: -2px !important;
  font-size: 11px;
  opacity: 0.75;
}

.header-icon-btn {
  width: 34px;
  justify-content: center;
  padding: 0;
}

.header-action-btn:hover,
.header-icon-btn:hover {
  border-color: rgba(15, 118, 110, 0.42);
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(15, 118, 110, 0.15);
  color: #0f766e;
}

.header-icon-btn.is-danger {
  border-color: rgba(245, 108, 108, 0.35);
  color: #c62828;
}

.header-content .actions > .status-panel {
  margin: 0;
}

.main-container {
  display: flex;
  flex-direction: column;
  margin-top: 20px;
  padding: 20px;
  min-height: calc(100vh - 80px);
}

.content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  padding: 10px;
  flex-grow: 1;
}

/* 图片卡片样式 */
.image-card {
  width: 100%;
  aspect-ratio: 4 / 3;
  background: var(--card-bg) !important;
  border-radius: 16px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
  overflow: hidden;
  position: relative;
  object-fit: cover;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  border: 1px solid rgba(255, 255, 255, 0.6) !important;
  will-change: transform;
  contain: layout style paint;
}

.image-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(138, 75, 255, 0.12);
  cursor: pointer;
}

.image-card .el-checkbox {
  position: absolute;
  top: 10px;
  right: 10px;
  transform: scale(1.5);
  z-index: 10;
  margin: 0; /* 重要：移除默认边距 */
  padding: 0; /* 重要：移除默认内边距 */
}

.el-image {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition: opacity 0.3s ease;
}
.el-image:hover {
  opacity: 0.8;
}

.card-footer {
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 10px;
  background: rgba(0, 0, 0, 0.6);
  text-align: center;
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  box-sizing: border-box;
}

.image-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.6);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.el-card, .el-card__body{
  border: none !important;
}
.el-card__body{
  padding: 14px !important;
}
.el-card:hover .image-overlay {
  opacity: 1;
}

.overlay-buttons {
  display: flex;
  gap: 10px;
  pointer-events: auto;
}

.pagination-container {
  display: flex;
  justify-content: center;
  margin-top: 16px;
}

.collect-icon {
  position: absolute;
  top: -1.3px;
  left: 10px;
  cursor: pointer;
  font-size: 1.5em;
  z-index: 10;
  transition: color 0.3s ease, transform 0.3s ease;
}
.collect-icon:hover {transform: scale(1.2);}
.liked {color: #FFD7E4;}
.not-liked {color: #b39edb80;}

.footer {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 15px;
  margin-top: 20px;
  font-size: 0.9em;
  color: #555; /* 字体颜色改为黑色 */
}

.footer a {
  color: #555; /* 链接颜色 */
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer a:hover {
  color: #333; /* 悬停时的链接颜色改为黑色 */
}

.footer i {
  color: #333; /* 图标颜色改为黑色 */
}

/* 适配移动端 */
@media (max-width: 768px) {
  .header-content {
    top: 8px;
    left: 8px;
    right: 8px;
    min-height: 0;
    height: auto;
    padding: 10px 14px;
    border-radius: 14px;
    flex-wrap: wrap;
  }
  .content {
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 12px;
  }
  .admin-brand {
    order: 0;
    min-width: 0;
  }
  .search-card {
    order: 1;
    min-width: 0;
    flex: 1 1 100%;
    max-width: none;
  }
  .header-stats {
    order: 2;
    margin-left: 0;
    flex-wrap: wrap;
  }
  .header-content .actions {
    order: 3;
    width: 100%;
    justify-content: flex-start;
    margin-top: 2px;
    overflow-x: auto;
    padding-bottom: 1px;
    scrollbar-width: none;
  }
  .header-content .actions::-webkit-scrollbar {
    display: none;
  }
  .header-action-btn {
    height: 32px;
    padding: 0 10px;
    font-size: 12px;
  }
  .header-icon-btn {
    width: 32px;
    height: 32px;
  }
  .stat-pill {
    min-height: 30px;
    padding: 5px 8px;
  }
  .search-card .el-input__inner {
    width: 100%;
    height: 36px;
  }
  .el-card{aspect-ratio: unset; min-height: 180px;}
  .el-card__body{padding: 0;}
  .main-container {
    margin-top: 76px;
    padding: 12px;
  }
}

@media (max-width: 480px) {
  .content {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .admin-brand {
    width: 100%;
  }
  .brand-title {
    font-size: 16px;
  }
  .brand-subtitle {
    display: none;
  }
  .header-stats {
    width: 100%;
    overflow: auto;
    padding-top: 2px;
  }
  .header-content .actions {
    width: 100%;
    gap: 6px;
    justify-content: flex-start;
    overflow-x: auto;
    padding-bottom: 1px;
    margin-top: 6px;
    padding-top: 6px;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
  }
  .search-card .el-input__inner {
    font-size: 12px;
  }
}

/* 音视频卡片基础样式 */
.video-card, .audio-card, .file-card {
  background: linear-gradient(135deg, rgba(138, 75, 255, 0.9) 0%, rgba(109, 130, 255, 0.9) 100%);
  border: none;
  border-radius: 20px !important;
  overflow: hidden;
  position: relative;
  justify-content: center;
  align-items: center;
  box-shadow: 0 8px 24px rgba(138, 75, 255, 0.15);
  transition: var(--transition);
}

.video-card {
  background: linear-gradient(135deg, #8EC5FC 0%, #E0C3FC 100%);
}

.video-card .el-card__body{
  padding: 0 !important;
}

.audio-card.selected, .video-card.selected, .file-card.selected {
  background: linear-gradient(135deg, rgba(138, 75, 255, 0.85) 0%, rgba(255, 215, 228, 0.85) 100%);
}

.video-card:hover, .audio-card:hover, .file-card:hover {
  transform: scale(1.02);
}

.video-content, .audio-content, .file-content {
  padding: 14px 14px 16px;
  color: white;
  width: 100%;
  box-sizing: border-box;
  overflow: hidden;
  text-overflow: ellipsis;
  min-height: 240px;
}

.video-content{
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.audio-header, .file-header {
  display: flex;
  align-items: center;
  margin-bottom: 15px;
}

.audio-avatar, .file-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  padding: 8px;
  margin-right: 15px;
}

.file-avatar{
  background: none;
  display: flex;
  justify-content: center;
  align-items: center;
}

.audio-avatar img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.audio-info, .file-info {
  flex: 1;
  min-width: 0;
}

.video-title, .audio-title, .file-title {
  font-size: 16px;
  font-weight: 500;
  max-width: 100%;
  white-space: normal;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 6px;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.video-title{
  margin: 6px 0;
  font-size: 0.9em;
}

.audio-subtitle, .file-subtitle {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.7);
}

/* 自定义audio元素样式 */
.custom-audio-player {
  width: 100%;
  height: 42px;
  margin: 15px 0;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.2);
}

.video-controls, .audio-controls, .file-controls {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.like-btn i, .select-btn i {
  font-size: 1.2em;
}

.like-btn .liked, .select-btn .selected {
  color: #FFD7E4;
}

.control-btn {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  color: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  flex-shrink: 0;
  z-index: 1; /* 确保按钮可点击 */
}

.control-btn:hover {
  background: rgba(255, 255, 255, 0.3);
}

/* 状态面板 - 带标签的状态指示器 */
.status-panel {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 6px 14px;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 20px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  margin: 0 8px;
}

.status-panel:hover {
  background: rgba(255, 255, 255, 1);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.status-item {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: #666;
  font-weight: 500;
}

.status-item i {
  font-size: 8px !important;
  margin: 0 !important;
}

.status-item span {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* 返回首页按钮 */
.home-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, #8a4bff 0%, #b39ddb 100%);
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-right: 12px;
  box-shadow: 0 2px 8px rgba(138, 75, 255, 0.3);
}

.home-btn:hover {
  transform: scale(1.08);
  box-shadow: 0 4px 16px rgba(138, 75, 255, 0.4);
}

.home-btn i {
  color: white;
  font-size: 16px;
}

/* 批量操作工具栏 */

.batch-toolbar {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 18px;
  background: rgba(255, 255, 255, 0.65);
  border: 1px solid rgba(138, 75, 255, 0.25);
  border-radius: 999px;
  box-shadow: 0 12px 30px rgba(138, 75, 255, 0.25);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  z-index: 1000;
  cursor: grab;
  user-select: none;
}

.batch-toolbar.is-dragging {
  cursor: grabbing;
  box-shadow: 0 18px 34px rgba(138, 75, 255, 0.3);
}

.batch-float-enter-active,
.batch-float-leave-active {
  transition: all 0.25s ease;
}

.batch-float-enter,
.batch-float-leave-to {
  opacity: 0;
  transform: translate(-50%, 12px);
}

.batch-count {
  font-size: 13px;
  font-weight: 600;
  color: #8a4bff;
  white-space: nowrap;
}

.batch-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.batch-btn {
  border-radius: 999px !important;
  font-weight: 600;
  border: none !important;
}

.batch-btn-copy {
  background: linear-gradient(135deg, #6a9eff 0%, #8ab4ff 100%) !important;
  color: #fff !important;
}

.batch-btn-move {
  background: linear-gradient(135deg, #6f8bff 0%, #94a8ff 100%) !important;
  color: #fff !important;
}

.batch-btn-delete {
  background: linear-gradient(135deg, #ff7b7b 0%, #ff9f9f 100%) !important;
  color: #fff !important;
}

.batch-btn-download {
  background: linear-gradient(135deg, #35d49b 0%, #7ee6c1 100%) !important;
  color: #fff !important;
}

.batch-btn-cancel {
  background: rgba(80, 80, 80, 0.15) !important;
  color: #3b3b3b !important;
}

.batch-shortcuts {
  font-size: 11px;
  color: rgba(55, 55, 55, 0.7);
  margin-left: 4px;
  white-space: nowrap;
}

.batch-toolbar .el-button-group .el-button {
  border-radius: 0;
}

.batch-toolbar .el-button-group .el-button:first-child {
  border-radius: 16px 0 0 16px;
}

.batch-toolbar .el-button-group .el-button:last-child {
  border-radius: 0 16px 16px 0;
}

/* 移动端适配 */
@media (max-width: 768px) {
  .audio-card { max-height: none; }
  .custom-audio-player { height: 32px; }
  .status-panel {
    padding: 4px 10px;
    gap: 8px;
  }
  .status-item span {
    display: none;
  }
  .batch-toolbar {
    bottom: 18px;
    padding: 8px 14px;
    gap: 10px;
    max-width: 92vw;
    flex-wrap: wrap;
    justify-content: center;
  }
  .batch-shortcuts {
    width: 100%;
    text-align: center;
  }
  .header-content .actions {
    flex-wrap: wrap;
    gap: 6px;
    justify-content: flex-start;
  }
  .header-action-btn,
  .header-icon-btn {
    height: 32px;
  }
  .header-action-btn {
    padding: 0 10px;
    font-size: 12px;
  }
}

@media (max-width: 480px) {
  .header-content {
    flex-wrap: wrap;
    height: auto;
    padding: 8px 10px;
    gap: 8px;
  }
  .header-content .actions {
    order: 3;
    width: 100%;
    justify-content: flex-start;
    gap: 2px;
    padding-top: 6px;
    border-top: 1px solid rgba(0,0,0,0.05);
    margin-top: 4px;
  }
  .header-action-btn {
    padding: 0 8px;
    font-size: 11px;
  }
  .main-container {
    margin-top: 100px;
    padding: 8px;
  }
  .content {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }
  .image-card {
    border-radius: 12px;
  }
  .card-footer {
    font-size: 0.75em;
    padding: 6px 8px;
  }
  .overlay-buttons {
    flex-direction: column;
    gap: 6px;
  }
  .overlay-buttons .el-button {
    padding: 4px 10px;
    font-size: 12px;
  }
  .control-btn {
    width: 32px;
    height: 32px;
  }
  .video-controls, .audio-controls, .file-controls {
    gap: 6px;
    flex-wrap: wrap;
    justify-content: center;
  }
  .pagination-container {
    padding: 0 8px;
  }
  .el-pagination {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
  }
  .batch-toolbar {
    bottom: 14px;
    max-width: 95%;
    padding: 6px 12px;
  }
  .batch-toolbar .el-button {
    padding: 6px 10px;
    font-size: 12px;
  }
  .batch-count {
    font-size: 11px;
  }
  
  /* 移动端禁用高消耗效果 */
  .header-content {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    background-color: rgba(255, 255, 255, 0.98);
  }
  
  .image-card:hover {
    transform: none;
  }
  
  .image-card:hover img {
    transform: none;
  }
}

/* 用户偏好减少动画 */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

.website-edit-dialog .el-textarea__inner{
  height: 240px !important;
}

/* Admin UI Refresh */
:root {
  --admin-ink: #142033;
  --admin-muted: #627083;
  --admin-surface: rgba(255, 255, 255, 0.84);
  --admin-line: rgba(20, 32, 51, 0.12);
  --admin-brand: #0f766e;
  --admin-brand-deep: #0b4f4a;
  --admin-accent: #f59e0b;
}

body {
  font-family: "IBM Plex Sans", "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  background:
    radial-gradient(circle at 8% 10%, rgba(245, 158, 11, 0.22), transparent 34%),
    radial-gradient(circle at 92% 8%, rgba(15, 118, 110, 0.2), transparent 30%),
    linear-gradient(145deg, #f4ecdf 0%, #dbeeff 54%, #f8fafc 100%);
  color: var(--admin-ink);
}

.header-content {
  border-radius: 18px;
  border: 1px solid var(--admin-line);
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 14px 38px rgba(20, 32, 51, 0.12);
}

.title {
  letter-spacing: 0.02em;
  color: var(--admin-ink);
}

.title:hover {
  color: var(--admin-brand);
}

.search-card .el-input__inner {
  border: 1px solid rgba(15, 118, 110, 0.2);
  background: rgba(255, 255, 255, 0.95);
  box-shadow: none;
}

.search-card .el-input__inner:focus {
  border-color: rgba(15, 118, 110, 0.42);
  box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.12);
}

.stats {
  cursor: default;
  margin-right: 12px;
  padding: 8px 14px;
  border-radius: 14px;
  border: 1px solid rgba(15, 118, 110, 0.24);
  background: linear-gradient(145deg, rgba(15, 118, 110, 0.16), rgba(15, 118, 110, 0.08));
  color: var(--admin-brand-deep);
  box-shadow: none;
}

.stats:hover {
  transform: none;
  color: var(--admin-brand-deep);
  background: linear-gradient(145deg, rgba(15, 118, 110, 0.18), rgba(15, 118, 110, 0.1));
  box-shadow: none;
}

.stats-icon {
  margin-right: 8px;
  color: var(--admin-brand);
}

.stats-loaded {
  margin-left: 10px;
  padding-left: 10px;
  border-left: 1px solid rgba(15, 118, 110, 0.3);
  color: var(--admin-muted);
  font-size: 12px;
  font-weight: 600;
}

.header-content .actions > i,
.header-content .actions > .el-dropdown > .el-dropdown-link,
.header-content .actions > .theme-admin-toggle {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  border: 1px solid var(--admin-line);
  background: rgba(255, 255, 255, 0.9);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.header-content .actions > i:hover,
.header-content .actions > .el-dropdown > .el-dropdown-link:hover,
.header-content .actions > .theme-admin-toggle:hover {
  color: var(--admin-brand) !important;
  border-color: rgba(15, 118, 110, 0.35);
  box-shadow: 0 8px 16px rgba(15, 118, 110, 0.15);
}

.home-btn {
  background: linear-gradient(145deg, #0f766e, #129a8f);
  box-shadow: 0 8px 20px rgba(15, 118, 110, 0.35);
}

.status-panel {
  border: 1px solid var(--admin-line);
  box-shadow: none;
}

.content {
  gap: 18px;
}

.image-card,
.video-card,
.audio-card,
.file-card {
  border: 1px solid var(--admin-line) !important;
  border-radius: 18px !important;
  box-shadow: 0 10px 24px rgba(20, 32, 51, 0.12);
}

.image-card {
  background: var(--admin-surface) !important;
}

.image-card:hover,
.video-card:hover,
.audio-card:hover,
.file-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 16px 30px rgba(20, 32, 51, 0.18);
}

.video-card,
.audio-card,
.file-card {
  background: linear-gradient(155deg, rgba(11, 79, 74, 0.92), rgba(15, 118, 110, 0.82)) !important;
}

.control-btn {
  background: rgba(255, 255, 255, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.26);
}

.control-btn:hover {
  background: rgba(255, 255, 255, 0.36);
}

.collect-icon .liked {
  color: #f59e0b;
}

.pagination-container .el-pager li,
.pagination-container .btn-prev,
.pagination-container .btn-next {
  border-radius: 10px !important;
}

.load-more-end {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 14px;
  border: 1px solid rgba(15, 118, 110, 0.25);
  border-radius: 999px;
  color: var(--admin-brand-deep);
  background: rgba(15, 118, 110, 0.1);
  font-size: 13px;
  font-weight: 600;
}

.batch-toolbar {
  border: 1px solid rgba(15, 118, 110, 0.3);
  box-shadow: 0 14px 32px rgba(15, 118, 110, 0.2);
}

@media (max-width: 768px) {
  .header-content {
    border-radius: 14px;
  }

  .stats {
    padding: 6px 10px;
  }

  .stats-loaded {
    display: none;
  }

  .header-content .actions > i,
  .header-content .actions > .el-dropdown > .el-dropdown-link,
  .header-content .actions > .theme-admin-toggle {
    width: 34px;
    height: 34px;
  }
}

@media (max-width: 900px) {
  .header-content .actions {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: flex-start !important;
    row-gap: 8px !important;
  }

  .header-content .actions > .status-panel {
    order: 120 !important;
    flex: 0 0 100% !important;
    width: 100% !important;
    margin: 6px 0 0 !important;
  }
}

/* Admin header v2: isolated from legacy .title/.stats/.actions rules. */
.el-header {
  height: auto !important;
  min-height: 0 !important;
  padding: 12px 16px 0 !important;
  overflow: visible !important;
}

.header-content.admin-header {
  position: sticky !important;
  top: 12px !important;
  left: auto !important;
  right: auto !important;
  z-index: 900 !important;
  width: 100% !important;
  min-height: 0 !important;
  height: auto !important;
  box-sizing: border-box !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: stretch !important;
  gap: 8px !important;
  padding: 10px 12px !important;
  border-radius: 14px !important;
  border: 1px solid rgba(15, 23, 42, 0.12) !important;
  background: rgba(255, 255, 255, 0.94) !important;
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.1) !important;
  -webkit-backdrop-filter: blur(16px) !important;
  backdrop-filter: blur(16px) !important;
}

.admin-header__top {
  display: grid;
  grid-template-columns: minmax(190px, 250px) minmax(220px, 1fr) auto;
  align-items: center;
  gap: 12px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  min-width: 0;
}

.header-content.admin-header > *,
.admin-header__top > *,
.admin-header__controls > *,
.admin-header__utility-row > * {
  min-width: 0;
}

.admin-header__brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
  cursor: pointer;
}

.admin-header__home {
  width: 36px !important;
  height: 36px !important;
  min-width: 36px !important;
  padding: 0 !important;
  border-radius: 10px !important;
  border: 1px solid rgba(124, 58, 237, 0.22) !important;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.98), rgba(243, 238, 255, 0.9)) !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  overflow: hidden !important;
  cursor: pointer;
  box-shadow: none !important;
}

.admin-header__logo {
  display: block !important;
  width: 24px !important;
  height: 24px !important;
  max-width: 24px !important;
  max-height: 24px !important;
  object-fit: contain !important;
  flex: 0 0 24px !important;
}

.admin-header__brand-copy {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.admin-header__title {
  color: #172033;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.admin-header__subtitle {
  color: #64748b;
  font-size: 11px;
  line-height: 1.2;
  letter-spacing: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.admin-header__search {
  min-width: 0;
}

.admin-header__search .el-input__inner {
  width: 100% !important;
  height: 34px !important;
  padding-left: 32px !important;
  border-radius: 10px !important;
  border: 1px solid rgba(100, 116, 139, 0.22) !important;
  background: rgba(248, 250, 252, 0.92) !important;
  color: #172033 !important;
  font-size: 13px !important;
  box-shadow: none !important;
}

.admin-header__search .el-input__inner:focus {
  border-color: rgba(15, 118, 110, 0.46) !important;
  box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.1) !important;
}

.admin-header__stats {
  display: inline-flex;
  justify-content: flex-end;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.admin-header__stat {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 32px;
  padding: 5px 9px;
  border-radius: 8px;
  border: 1px solid rgba(15, 118, 110, 0.18);
  background: rgba(240, 253, 250, 0.78);
  color: #0f4f49;
  font-size: 12px;
  font-weight: 650;
  line-height: 1.1;
  white-space: nowrap;
}

.admin-header__stat i {
  color: #0f766e;
  font-size: 13px;
}

.admin-header__controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  min-width: 0;
  padding-top: 8px;
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}

.admin-header__action-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1 1 auto;
  width: auto;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  overflow-y: hidden;
  padding-bottom: 1px;
  scrollbar-width: thin;
}

.admin-header__action-row > .el-dropdown {
  flex: 0 0 auto;
  line-height: 0;
}

.admin-header__action,
.admin-header__icon-btn {
  height: 34px !important;
  border-radius: 8px !important;
  border: 1px solid rgba(100, 116, 139, 0.28) !important;
  background: rgba(248, 250, 252, 0.94) !important;
  color: #1f2937 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 7px !important;
  box-sizing: border-box !important;
  font-size: 13px !important;
  font-weight: 650 !important;
  line-height: 1 !important;
  white-space: nowrap !important;
  cursor: pointer;
  transition: border-color 0.18s ease, background-color 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
}

.admin-header__action {
  min-width: 76px;
  padding: 0 11px !important;
}

.admin-header__action i,
.admin-header__icon-btn i {
  margin: 0 !important;
  color: inherit !important;
  font-size: 15px !important;
  line-height: 1 !important;
}

.admin-header__action .el-icon-arrow-down {
  margin-left: 2px !important;
  font-size: 11px !important;
  opacity: 0.7;
}

.admin-header__icon-btn {
  width: 34px !important;
  min-width: 34px !important;
  padding: 0 !important;
}

.admin-header__action:hover,
.admin-header__icon-btn:hover {
  border-color: rgba(15, 118, 110, 0.4) !important;
  background: rgba(236, 253, 245, 0.95) !important;
  color: #0f766e !important;
  box-shadow: 0 6px 16px rgba(15, 118, 110, 0.12) !important;
}

.admin-header__icon-btn.is-danger {
  border-color: rgba(220, 38, 38, 0.28) !important;
  color: #b91c1c !important;
}

.admin-header__icon-btn.is-danger:hover {
  border-color: rgba(220, 38, 38, 0.42) !important;
  background: rgba(254, 242, 242, 0.95) !important;
  color: #991b1b !important;
}

.admin-header__theme-btn [data-theme-label] {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
}

.admin-header__utility-row {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex: 0 0 auto;
  max-width: 100%;
  min-width: 0;
}

.admin-header__status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 34px;
  padding: 6px 9px;
  border-radius: 8px;
  border: 1px solid rgba(100, 116, 139, 0.22);
  background: rgba(248, 250, 252, 0.92);
  box-sizing: border-box;
  cursor: pointer;
}

.admin-header__status-item {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0;
}

.admin-header__status-item i {
  margin: 0 !important;
  font-size: 7px !important;
  line-height: 1 !important;
}

.main-container {
  margin-top: 14px !important;
}

html[data-theme="dark"] .header-content.admin-header {
  border-color: rgba(148, 163, 184, 0.24) !important;
  background: rgba(15, 23, 39, 0.94) !important;
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.34) !important;
}

html[data-theme="dark"] .admin-header__title,
html[data-theme="dark"] .admin-header__action,
html[data-theme="dark"] .admin-header__icon-btn,
html[data-theme="dark"] .admin-header__search .el-input__inner {
  color: #e8eeff !important;
}

html[data-theme="dark"] .admin-header__subtitle,
html[data-theme="dark"] .admin-header__status-item {
  color: #bac7df !important;
}

html[data-theme="dark"] .admin-header__home,
html[data-theme="dark"] .admin-header__action,
html[data-theme="dark"] .admin-header__icon-btn,
html[data-theme="dark"] .admin-header__status,
html[data-theme="dark"] .admin-header__search .el-input__inner {
  border-color: rgba(148, 163, 184, 0.28) !important;
  background: rgba(30, 41, 59, 0.9) !important;
}

html[data-theme="dark"] .admin-header__stat {
  border-color: rgba(45, 212, 191, 0.22);
  background: rgba(19, 78, 74, 0.34);
  color: #c6fff3;
}

@media (max-width: 1180px) {
  .admin-header__top {
    grid-template-columns: minmax(180px, 230px) minmax(220px, 1fr);
  }

  .admin-header__stats {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }

  .admin-header__controls {
    align-items: stretch;
    flex-direction: column;
  }

  .admin-header__utility-row {
    justify-content: space-between;
    width: 100%;
  }

  .admin-header__status {
    flex: 1 1 auto;
    justify-content: flex-start;
    overflow-x: auto;
  }
}

@media (max-width: 900px) {
  .el-header {
    padding: 10px 10px 0 !important;
  }

  .header-content.admin-header {
    position: static !important;
    top: auto !important;
    padding: 10px !important;
    border-radius: 12px !important;
  }

  .admin-header__top {
    grid-template-columns: 1fr;
    gap: 9px;
  }

  .admin-header__stats {
    overflow-x: auto;
    padding-bottom: 1px;
  }

  .admin-header__action-row {
    width: 100%;
    max-width: 100%;
  }

  .admin-header__utility-row {
    align-items: stretch;
    flex-wrap: wrap;
    width: 100%;
    max-width: 100%;
  }

  .admin-header__status {
    flex: 1 1 100%;
    width: 100%;
    max-width: 100%;
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 6px;
    padding: 7px;
  }

  .admin-header__status-item {
    justify-content: center;
  }

  .main-container {
    margin-top: 12px !important;
  }
}

@media (max-width: 560px) {
  .admin-header__subtitle {
    display: none;
  }

  .admin-header__action {
    min-width: 68px;
    padding: 0 9px !important;
    font-size: 12px !important;
  }

  .admin-header__status {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
