:root {
    /* 暗色主题变量 */
    --md-primary: #3b82f6;
    --md-primary-dark: #2563eb;
    --md-primary-light: #60a5fa;
    --md-secondary: #10b981;
    --md-secondary-dark: #059669;
    --md-background: #0f0f0f;
    --md-surface: #1a1a1a;
    --md-surface-variant: #262626;
    --md-on-primary: #ffffff;
    --md-on-secondary: #ffffff;
    --md-on-background: #f5f5f5;
    --md-on-surface: #e5e5e5;
    --md-on-surface-variant: #a3a3a3;
    --md-outline: #404040;
    --md-shadow: rgba(0, 0, 0, 0.3);
    --md-elevation-1: 0 1px 3px rgba(0, 0, 0, 0.3), 0 1px 2px rgba(0, 0, 0, 0.4);
    --md-elevation-2: 0 3px 6px rgba(0, 0, 0, 0.4), 0 3px 6px rgba(0, 0, 0, 0.5);
    --md-elevation-3: 0 10px 20px rgba(0, 0, 0, 0.5), 0 6px 6px rgba(0, 0, 0, 0.6);
    --md-elevation-4: 0 14px 28px rgba(0, 0, 0, 0.6), 0 10px 10px rgba(0, 0, 0, 0.7);
    
    /* 分类标签导航专用色系 */
    --filter-primary: #8b5cf6;
    --filter-primary-dark: #7c3aed;
    --filter-secondary: #f59e0b;
    --filter-secondary-dark: #d97706;
    --filter-surface: #2d1b69;
    --filter-surface-variant: #3730a3;
    
    /* 主题切换过渡 */
    --theme-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 添加亮色主题变量 */
[data-theme="light"] {
    --md-primary: #1976d2;
    --md-primary-dark: #1565c0;
    --md-primary-light: #42a5f5;
    --md-secondary: #388e3c;
    --md-secondary-dark: #2e7d32;
    --md-background: #fafafa;
    --md-surface: #ffffff;
    --md-surface-variant: #f5f5f5;
    --md-on-primary: #ffffff;
    --md-on-secondary: #ffffff;
    --md-on-background: #212121;
    --md-on-surface: #424242;
    --md-on-surface-variant: #757575;
    --md-outline: #e0e0e0;
    --md-shadow: rgba(0, 0, 0, 0.1);
    --md-elevation-1: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.24);
    --md-elevation-2: 0 3px 6px rgba(0, 0, 0, 0.16), 0 3px 6px rgba(0, 0, 0, 0.23);
    --md-elevation-3: 0 10px 20px rgba(0, 0, 0, 0.19), 0 6px 6px rgba(0, 0, 0, 0.23);
    --md-elevation-4: 0 14px 28px rgba(0, 0, 0, 0.25), 0 10px 10px rgba(0, 0, 0, 0.22);
    
    /* 亮色主题分类标签色系 */
    --filter-primary: #673ab7;
    --filter-primary-dark: #512da8;
    --filter-secondary: #ff9800;
    --filter-secondary-dark: #f57c00;
    --filter-surface: #f3e5f5;
    --filter-surface-variant: #e1bee7;
}

* {
    font-family: 'Roboto', sans-serif;
    transition: var(--theme-transition);
}

body {
    background: var(--md-background);
    color: var(--md-on-background);
    margin: 0;
    padding: 0;
}
.md-navbar {
    background: var(--md-surface);
    box-shadow: var(--md-elevation-2);
    position: sticky;
    top: 0;
    z-index: 100;
}

.md-navbar-container {
    max-width: 1470px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    height: 64px;
    justify-content: space-between;
}

/* Material Design Logo */
.md-logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.md-logo-icon {
    width: 40px;
    height: 40px;
    background: rgb(59 130 246 / 46%);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--md-elevation-2);
    animation: logoFloat 3s ease-in-out infinite;
}

@keyframes logoFloat {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-2px); }
}

.md-logo-text {
    font-size: 24px;
    font-weight: 500;
    color: var(--md-primary);
}

.md-theme-toggle {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: none;
    background: var(--md-surface-variant);
    color: var(--md-on-surface);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--theme-transition);
    box-shadow: var(--md-elevation-1);
    margin-left: 12px;
}

.md-theme-toggle:hover {
    background: var(--md-primary);
    color: var(--md-on-primary);
    transform: scale(1.1);
    box-shadow: var(--md-elevation-2);
}

/* Material Design 搜索框 */
.md-search {
    position: relative;
    flex: 1;
    max-width: 300px;
    margin: 0 32px;
}

.md-search input {
    width: 100%;
    height: 48px;
    padding: 0 16px 0 48px;
    border: 1px solid var(--md-outline);
    border-radius: 24px;
    background: var(--md-surface);
    font-size: 16px;
    transition: var(--theme-transition);
    color: var(--md-on-surface);
}

.md-search input:focus {
    outline: none;
    border-color: var(--md-primary);
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.3);
}

.md-search-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--md-on-surface-variant);
}

/* 为按钮添加3D效果 */
.md-btn {
    height: 40px;
    padding: 0 16px;
    border-radius: 20px;
    border: none;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--theme-transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    position: relative;
    transform: translateY(0);
    box-shadow: 0 4px 8px var(--md-shadow), 0 2px 4px var(--md-shadow);
}

.md-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px var(--md-shadow), 0 3px 6px var(--md-shadow);
}

.md-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px var(--md-shadow), 0 1px 2px var(--md-shadow);
}

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

.md-btn-outlined:hover {
    background: rgba(25, 118, 210, 0.1);
}

.md-btn-filled {
    background: var(--md-primary);
    color: var(--md-on-primary);
}

.md-btn-filled:hover {
    background: var(--md-primary-dark);
}

/* 分类标签导航使用不同色系 */
.md-filters {
    background: rgb(58 59 61 / 30%);
    border-bottom: 1px solid rgba(25, 118, 210, 0.1);
    padding: 20px 0;
}

.md-filters-write{
    background: none !important;
}

.md-filters-container {
    max-width: 1470px;
    margin: 0 auto;
    padding: 0 24px;
}

.md-chip {
    display: inline-flex;
    align-items: center;
    height: 32px;
    padding: 0 12px;
    border-radius: 16px;
    border: 1px solid rgb(95 97 101 / 50%);
    background: transparent;
    /* color: #eeeeeeb5; */
    font-size: 14px;
    cursor: pointer;
    transition: var(--theme-transition);
    margin: 4px 8px 4px 0;
    position: relative;
    transform: translateY(0);
    box-shadow: 0 2px 4px var(--md-shadow);
}

.md-chip:hover {
    background: rgba(255, 152, 0, 0.1);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px var(--md-shadow);
}

.md-chip.active {
    background: var(--filter-primary);
    color: white;
    border-color: var(--filter-primary);
    box-shadow: 0 4px 8px rgba(103, 58, 183, 0.4);
}

/* Material Design 卡片 */
.md-content {
    max-width: 1470px;
    margin: 0 auto;
    padding: 24px;
}

/* 调整网格布局，增加一行显示的卡片数量 */
.md-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 16px;
}

.md-card {
  background: var(--md-surface);
  border-radius: 12px;
  box-shadow: var(--md-elevation-1);
  cursor: pointer;
  transition: var(--theme-transition);
  position: relative;
  overflow: hidden;  /* 避免视频溢出 */
}

.md-card-media {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
}

.md-card-media img {
    width: 100%;
    /* height: 100%; */
    min-height: 189px;
    object-fit: cover;
    transition: transform 0.3s ease;
}
.md-card-video-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;               /* 覆盖整个图片区域 */
  background: #000;
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: inherit;
}

.md-card-video-overlay.show {
  opacity: 1;              /* 显示视频 */
}

.md-card-preview-video {
  width: 100%;
  height: 100%;
  object-fit: cover;        /* 保持比例，铺满缩略图区域 */
  border-radius: inherit;
}


.loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(255,255,255,0.3);
  border-top: 3px solid #fff;
  border-radius: 50%;
  animation: spinxx 0.8s linear infinite;
  position: absolute;
  z-index: 20;
}

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

.md-card-actions {
    position: absolute;
    bottom: 16px;
    right: 16px;
    display: flex;
    gap: 8px;
    z-index: 20;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s ease;
}

.md-card:hover .md-card-actions {
    opacity: 1;
    transform: translateY(0);
}

.md-fab-mini {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: var(--md-elevation-2);
    transition: all 0.3s ease;
}

.md-fab-mini:hover {
    transform: scale(1.1);
    box-shadow: var(--md-elevation-3);
}

.md-card-content {
    /* 卡片下方内容区域 */
    height: 30%;
    padding: 16px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* 确保卡片名称完整显示 */
.md-card-title {
    font-size: 14px;
    font-weight: 500;
    color: var(--md-on-surface);
    margin: 0 0 8px 0;
    line-height: 1.4;
    /* 移除行数限制，让标题完整显示 */
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.md-card-subtitle {
    font-size: 12px;
    color: var(--md-on-surface-variant);
    margin: 0 0 8px 0;
}

.md-card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.md-heat {
    font-size: 12px;
    color: var(--md-secondary-dark);
    font-weight: 500;
}

.md-price {
    font-size: 16px;
    font-weight: 700;
    color: var(--md-primary);
}

.md-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.md-tag {
    background: rgba(25, 118, 210, 0.2);
    color: var(--md-primary);
    padding: 2px 6px;
    border-radius: 8px;
    font-size: 10px;
}

/* Material Design FAB */
.md-fab-container {
    position: fixed;
    right: 24px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 16px;
    z-index: 90;
}

.md-fab {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--md-primary);
    color: var(--md-on-primary);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: var(--md-elevation-3);
    transition: var(--theme-transition);
    position: relative;
}

.md-fab:hover {
    box-shadow: var(--md-elevation-4);
    transform: scale(1.1);
}

.md-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background: #f44336;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 500;
}

/* 更新弹窗样式，采用与登录弹窗类似的渐变背景效果 */
.md-popup {
    position: fixed;
    right: -700px;
    top: 50%;
    transform: translateY(-50%);
    width: 460px;
    max-height: 80vh;
    background: linear-gradient(135deg, var(--md-surface) 0%, var(--md-surface-variant) 100%);
    border-radius: 16px;
    box-shadow: var(--md-elevation-4);
    transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.md-popup::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
    pointer-events: none;
}

.md-popup.open {
    right: 24px;
}

.md-popup-header {
    padding: 24px 24px 0 24px;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
}

.md-popup-title {
    font-size: 20px;
    font-weight: 500;
    color: var(--md-on-surface);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.md-popup-content {
    flex: 1;
    overflow-y: auto;
    padding: 16px 24px 24px 24px;
    position: relative;
    z-index: 1;
}

/* 更新购物车样式以适配暗黑主题 */
.md-cart-item {
    background: var(--md-surface-variant);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: var(--theme-transition);
}

.md-cart-item:hover {
    background: var(--md-outline);
}

.md-checkbox {
    width: 20px;
    height: 20px;
    border: 2px solid var(--md-primary);
    border-radius: 4px;
    background: transparent;
    cursor: pointer;
    position: relative;
    transition: var(--theme-transition);
}

.md-checkbox.checked {
    background: var(--md-primary);
}

.md-checkbox.checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: var(--md-on-primary);
    font-size: 14px;
    font-weight: bold;
}

.md-cart-actions {
    position: sticky;
    bottom: 0;
    background: var(--md-surface);
    padding: 16px 0 0 0;
    border-top: 1px solid var(--md-outline);
    margin-top: 16px;
}

/* 预览弹窗 */
.md-preview-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.md-preview-modal.open {
    opacity: 1;
    visibility: visible;
}

.md-preview-content {
    background: var(--md-surface);
    border-radius: 16px;
    max-width: 90vw;
    /* max-height: 70vh; */
    width: 690px;
    display: flex;
    overflow: hidden;
    box-shadow: var(--md-elevation-4);
    transform: scale(0.9);
    transition: transform 0.3s ease;
    min-height: 750px;
}

.md-preview-modal.open .md-preview-content {
    transform: scale(1);
}

.md-preview-left {
    flex: 1;
    background: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.md-preview-video {
    /* width: 375px; */
    /* height: 100%; */
    width: 346.36px;
    height: 750px;
    object-fit: cover;
    border-radius: 8px;
}

.md-preview-right {
    width: 340px;
    padding: 32px;
    overflow-y: auto;
}

/* 模态框 */
.md-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.md-modal.open {
    opacity: 1;
    visibility: visible;
}

/* 重新设计登录注册模态框样式 */
.md-modal-content {
    background: linear-gradient(135deg, var(--md-surface) 0%, var(--md-surface-variant) 100%);
    border-radius: 20px;
    padding: 0;
    max-width: 480px;
    width: 90%;
    box-shadow: var(--md-elevation-4);
    transform: scale(0.9);
    transition: transform 0.3s ease;
    overflow: hidden;
}

.md-modal.open .md-modal-content {
    transform: scale(1);
}

.md-modal-header {
    background: linear-gradient(135deg, var(--md-primary) 0%, var(--filter-primary) 100%);
    padding: 32px;
    text-align: center;
    position: relative;
}

.md-modal-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
}

.md-modal-title {
    font-size: 28px;
    font-weight: 600;
    margin: 0 0 8px 0;
    color: white;
    position: relative;
    z-index: 1;
}

.md-modal-subtitle {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.8);
    margin: 0;
    position: relative;
    z-index: 1;
}

.md-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    z-index: 2;
}

.md-modal-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

.md-modal-body {
    padding: 40px;
}

.md-auth-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 24px;
    background: var(--md-surface-variant);
    border-radius: 12px;
    padding: 4px;
}

.md-auth-tab {
    flex: 1;
    height: 44px;
    border: none;
    border-radius: 8px;
    background: transparent;
    color: var(--md-on-surface-variant);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--theme-transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.md-auth-tab.active {
    background: var(--md-primary);
    color: var(--md-on-primary);
    box-shadow: 0 2px 8px rgba(25, 118, 210, 0.3);
}

.md-input-group {
    margin-bottom: 20px;
    position: relative;
}

.md-input-label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: var(--md-on-surface);
    margin-bottom: 8px;
}

.md-input {
    width: 100%;
    height: 56px;
    padding: 16px 16px 16px 48px;
    border: 2px solid var(--md-outline);
    border-radius: 12px;
    background: var(--md-surface);
    font-size: 16px;
    transition: var(--theme-transition);
    color: var(--md-on-surface);
}

.md-input:focus {
    outline: none;
    border-color: var(--md-primary);
    box-shadow: 0 0 0 3px rgba(25, 118, 210, 0.1);
}

.md-input-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--md-on-surface-variant);
    font-size: 18px;
}

.md-code-input-group {
    display: flex;
    gap: 8px;
    align-items: flex-end;
}

.md-code-input {
    flex: 1;
}

.md-code-btn {
    height: 56px;
    padding: 0 20px;
    border-radius: 12px;
    border: none;
    background: var(--filter-secondary);
    color: white;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--theme-transition);
    white-space: nowrap;
    box-shadow: 0 4px 8px rgba(255, 152, 0, 0.3);
}

.md-code-btn:hover {
    background: var(--filter-secondary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(255, 152, 0, 0.4);
}

.md-submit-btn {
    width: 100%;
    height: 56px;
    border-radius: 12px;
    border: none;
    background: linear-gradient(135deg, var(--md-primary) 0%, var(--filter-primary) 100%);
    color: white;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--theme-transition);
    margin-top: 8px;
    box-shadow: 0 6px 16px rgba(25, 118, 210, 0.3);
}

.md-submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(25, 118, 210, 0.4);
}

.md-submit-btn:active {
    transform: translateY(0);
}

.md-form-footer {
    text-align: center;
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid var(--md-outline);
}

.md-form-link {
    color: var(--md-primary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.md-form-link:hover {
    color: var(--md-primary-light);
}

.md-register-extras {
    margin-bottom: 20px;
}

.md-checkbox-group {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.md-checkbox-custom {
    width: 20px;
    height: 20px;
    border: 2px solid var(--md-primary);
    border-radius: 4px;
    background: transparent;
    cursor: pointer;
    position: relative;
    transition: var(--theme-transition);
}

.md-checkbox-custom.checked {
    background: var(--md-primary);
}

.md-checkbox-custom.checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 14px;
    font-weight: bold;
}

.md-checkbox-label {
    font-size: 14px;
    color: var(--md-on-surface-variant);
    cursor: pointer;
}

/* 分页 */
.md-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin: 32px 0;
}

.md-pagination button {
    min-width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    background: var(--md-surface);
    color: var(--md-on-surface);
    cursor: pointer;
    transition: var(--theme-transition);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--md-elevation-1);
}

.md-pagination button:hover,
.md-pagination button.active {
    background: var(--md-primary);
    color: var(--md-on-primary);
    box-shadow: var(--md-elevation-2);
}

.md-mobile-float-btn {
    display: none;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .md-navbar-container {
        padding: 0 16px;
    }

    .md-search {
        margin: 0 16px;
        max-width: none;
    }

    .md-content {
        padding: 16px;
    }

    /* 调整移动端网格布局 */
    .md-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
        gap: 12px;
    }

    .md-fab-container {
        right: 16px;
    }

    .md-popup {
        width: 95vw;
        right: -100vw;
    }

    .md-popup.open {
        right: 2.5vw;
    }

    /* .md-preview-content {
        flex-direction: column;
        width: 95vw;
        height: 95vh;
    } */

    .md-preview-right {
        display: none;
    }

    /* .md-preview-video {
        width: 100%;
        height: 300px;
    } */

    .md-modal-content {
        max-width: 95vw;
    }

    .md-modal-header {
        padding: 24px;
    }

    .md-modal-body {
        padding: 24px;
    }

    .md-mobile-float-btn {
        display: flex;
        position: absolute;
        bottom: 90px;
        right: 40px;
        z-index: 10;
        flex: 1;
        justify-content: center;
        align-items: center;
        padding: 8px 16px;
        font-size: 14px;
        border-radius: 8px;
        background: rgba(0, 0, 0, 0.6);
        color: #fff;
    }
}

/* 加载动画 */
.md-loading {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 40px;
}

.md-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid var(--md-outline);
    border-top: 4px solid var(--md-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 通知样式 */
.md-notification {
    position: fixed;
    bottom: 80px;
    left: 45%;
    transform: translateX(-50%);
    background: var(--md-primary);
    color: var(--md-on-primary);
    padding: 16px 24px;
    border-radius: 8px;
    box-shadow: var(--md-elevation-3);
    z-index: 3000;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    font-weight: 500;
}

.md-notification.show {
    transform: translateX(0);
}

    /* 通知样式 */
.md-error-notification {
    position: fixed;
    bottom: 80px;
    left: 45%;
    transform: translateX(-50%);
    
    background: red;
    color: var(--md-on-primary);
    padding: 16px 24px;
    border-radius: 8px;
    box-shadow: var(--md-elevation-3);
    z-index: 3000;
    transition: transform 0.3s ease;
    font-weight: 500;
}


.md-error-notification.show {
    transform: translateX(0);
}

/* 更新订单卡片样式 */
.md-order-card {
    background: var(--md-surface-variant);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 16px;
    box-shadow: var(--md-elevation-1);
}

.md-order-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 0;
    border-bottom: 1px solid var(--md-outline);
}

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

/* 更新状态标签颜色以适配暗黑主题 */
.md-status-chip {
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.md-status-completed {
    background: rgba(56, 142, 60, 0.2);
    color: #388e3c;
}

.md-status-pending {
    background: rgba(255, 152, 0, 0.2);
    color: #ff9800;
}

.md-status-cancelled {
    background: rgba(244, 67, 54, 0.2);
    color: #f44336;
}

#loading-mask {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #0f0f0f;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  font-size: 18px;
  color: #eee;
  opacity: 1;
      transition: opacity 0.6s ease; /* 渐隐动画 */
}

/* 隐藏状态 */
#loading-mask.fade-out {
    opacity: 0;
}

.spinner {
  width: 40px;
  height: 40px;
  border: 4px solid #ddd;
  border-top-color: #42b983; /* Vue 绿色 */
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-bottom: 12px;
}

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

.ajax-loading {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgb(0 0 0 / 0%); /* 半透明黑背景 */
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  color: #fff;
  font-size: 18px;
}

.ajax-loading .spinner {
  width: 48px;
  height: 48px;
  border: 4px solid rgba(255, 255, 255, 0.3);
  border-top-color: #42b983; /* Vue 绿色 */
  border-radius: 50%;
  animation: ajax-spin 2s linear infinite;
  margin-bottom: 12px;
}

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





/* 遮罩层 */
  .overlay {
    /* display: none; */
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    z-index: 1000;
  }
  .overlay.active {
    display: block;
  }

  /* 弹窗 */
  .modal {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #1e1e1e;
    border-radius: 8px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.6);
    width: 360px;
    color: #e0e0e0;
    animation: fadeIn 0.3s ease-out;
  }
  @keyframes fadeIn {
    from { transform: translate(-50%, -60%); opacity: 0; }
    to { transform: translate(-50%, -50%); opacity: 1; }
  }

  /* Header */
  .modal-header {
    padding: 16px 20px;
    border-bottom: 1px solid #333;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }
  .modal-header h2 {
    margin: 0;
    font-size: 18px;
    color: #fff;
  }
  .close-btn {
    background: none;
    border: none;
    font-size: 20px;
    color: #bbb;
    cursor: pointer;
    transition: color 0.3s;
  }
  .close-btn:hover {
    color: #fff;
  }

  /* 内容区 */
  .modal-content {
    padding: 20px;
    font-size: 14px;
    color: #ccc;
  }

  .order-box {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #2a2a2a;
    padding: 10px;
    border-radius: 6px;
    margin-top: 10px;
  }
  .order-id {
    font-family: monospace;
    color: #90caf9;
  }
  .copy-btn {
    background: #424242;
    border: none;
    color: #fff;
    padding: 6px 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
    transition: background 0.3s;
  }
  .copy-btn:hover {
    background: #616161;
  }

  /* 底部操作 */
  .modal-actions {
    padding: 12px 20px;
    border-top: 1px solid #333;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
  }
  .btn-flat {
    background: transparent;
    border: none;
    color: #90caf9;
    font-weight: 500;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.2s;
  }
  .btn-flat:hover {
    background: rgba(144,202,249,0.1);
  }


.md-title {
  color: var(--md-on-surface);
  font-size: 20px;
  margin: 0 0 8px;
}

.md-subtitle {
  color: var(--md-on-surface-variant);
  font-size: 14px;
  margin-bottom: 16px;
}

.md-divider {
  border-bottom: 1px solid var(--md-outline-variant);
  margin: 16px 0;
}

.md-section {
  margin-bottom: 20px;
}

.md-section-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--md-on-surface);
  margin-bottom: 6px;
}

.md-text {
  color: var(--md-on-surface-variant);
  font-size: 14px;
}


.md-empty {
  width: 100%;
  padding: 40px 0;
  text-align: center;
  color: #999;
  font-size: 16px;
}

.md-empty i {
  font-size: 40px;
  display: block;
  margin-bottom: 12px;
  color: #ccc;
}
