/* ============================================
   旅游笔记列表页样式
   文件：/travel-ui/css/style.css
   功能：旅游笔记列表页 - 响应式移动优先设计，支持品牌页面
   设计原则：沉浸感、移动优先、响应式、SEO友好
   ============================================ */

/* ============================================
   基础重置与设计系统
   ============================================ */

:root {
    /* 颜色系统 - 旅行主题 */
    --primary-color: #5D9CEC;      /* 主蓝色 - 天空与海洋 */
    --secondary-color: #48CFAD;    /* 副绿色 - 自然与生态 */
    --accent-color: #FF6B9D;       /* 强调色 - 花朵与活力 */
    --warning-color: #FFCE54;      /* 警告色 - 阳光与温暖 */
    
    /* 渐变系统 */
    --gradient-primary: linear-gradient(135deg, var(--primary-color), #7BB3FF);
    --gradient-secondary: linear-gradient(135deg, var(--secondary-color), #63D7B2);
    --gradient-accent: linear-gradient(135deg, var(--accent-color), #FF8CB3);
    --gradient-brand: linear-gradient(135deg, #5D9CEC, #48CFAD, #FF6B9D);
    
    /* 文字颜色 - 修复对比度问题 */
    --text-primary: #2C3E50;       /* 主要文字 */
    --text-secondary: #666666;     /* 次要文字 - 提高对比度 */
    --text-light: #888888;         /* 浅色文字 - 提高对比度 */
    --text-white: #FFFFFF;         /* 白色文字 */
    
    /* 背景颜色 */
    --bg-white: #FFFFFF;
    --bg-light: #F8F9FA;
    --bg-gray: #E9ECEF;
    --bg-dark: #2C3E50;
    
    /* 玻璃拟态效果 */
    --glass-bg: rgba(255, 255, 255, 0.92);
    --glass-bg-light: rgba(255, 255, 255, 0.85);
    --glass-bg-dark: rgba(45, 52, 54, 0.92);
    --glass-border: rgba(255, 255, 255, 0.25);
    --glass-border-dark: rgba(255, 255, 255, 0.15);
    --glass-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    --glass-blur: blur(20px) saturate(180%);
    
    /* 阴影系统 */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.12);
    --shadow-xl: 0 16px 48px rgba(0, 0, 0, 0.16);
    --shadow-inner: inset 0 2px 4px rgba(0, 0, 0, 0.05);
    
    /* 圆角系统 */
    --radius-xs: 4px;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --radius-2xl: 24px;
    --radius-3xl: 30px;
    --radius-pill: 9999px;
    --radius-circle: 50%;
    
    /* 间距系统 */
    --space-xs: 4px;
    --space-sm: 8px;
    --space-md: 16px;
    --space-lg: 24px;
    --space-xl: 32px;
    --space-2xl: 48px;
    --space-3xl: 64px;
    
    /* 字体系统 */
    --font-heading: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Segoe UI", sans-serif;
    --font-body: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Segoe UI", sans-serif;
    --font-mono: "SFMono-Regular", "Consolas", "Liberation Mono", "Menlo", monospace;
    
    /* 字号系统 */
    --text-xs: 0.75rem;     /* 12px */
    --text-sm: 0.875rem;    /* 14px */
    --text-base: 1rem;      /* 16px */
    --text-lg: 1.125rem;    /* 18px */
    --text-xl: 1.25rem;     /* 20px */
    --text-2xl: 1.5rem;     /* 24px */
    --text-3xl: 1.875rem;   /* 30px */
    --text-4xl: 2.25rem;    /* 36px */
    
    /* 行高系统 */
    --leading-tight: 1.25;
    --leading-snug: 1.375;
    --leading-normal: 1.5;
    --leading-relaxed: 1.625;
    --leading-loose: 2;
    
    /* 动画速度 */
    --duration-fast: 150ms;
    --duration-normal: 300ms;
    --duration-slow: 500ms;
    --duration-very-slow: 800ms;
    
    /* 安全区域 */
    --safe-area-inset-top: env(safe-area-inset-top);
    --safe-area-inset-bottom: env(safe-area-inset-bottom);
    --safe-area-inset-left: env(safe-area-inset-left);
    --safe-area-inset-right: env(safe-area-inset-right);
}

/* 暗色模式变量 - 修复对比度 */
@media (prefers-color-scheme: dark) {
    :root {
        --text-primary: #ECF0F1;
        --text-secondary: #BBBBBB; /* 提高对比度 */
        --text-light: #999999;     /* 提高对比度 */
        --text-white: #FFFFFF;
        
        --bg-white: #1A1D1F;
        --bg-light: #121416;
        --bg-gray: #2C3E50;
        --bg-dark: #0D0F10;
        
        --glass-bg: rgba(45, 52, 54, 0.92);
        --glass-bg-light: rgba(45, 52, 54, 0.85);
        --glass-border: rgba(255, 255, 255, 0.15);
        
        --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.2);
        --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.25);
        --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.3);
        --shadow-xl: 0 16px 48px rgba(0, 0, 0, 0.35);
        --shadow-inner: inset 0 2px 4px rgba(0, 0, 0, 0.2);
    }
}

/* 基础重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
    -webkit-text-size-adjust: 100%;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* 修复水平滚动和弹性滚动问题 */
html, body {
    overflow-x: hidden;
    overflow-y: auto;
    width: 100%;
    position: relative;
    -webkit-overflow-scrolling: touch; /* iOS平滑滚动 */
}

/* 防止过度弹性滚动 */
body {
    overscroll-behavior-y: contain;
    overscroll-behavior-x: none;
}

html {
    font-size: var(--text-base);
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: none; /* 禁用整个页面的过度滚动 */
}

body {
    font-family: var(--font-body);
    font-size: var(--text-base);
    line-height: var(--leading-relaxed);
    color: var(--text-primary);
    background: var(--bg-light);
    overflow-x: hidden;
    overflow-y: auto;
    padding-top: calc(var(--safe-area-inset-top) + 70px);
    padding-bottom: var(--safe-area-inset-bottom);
    position: relative;
    width: 100%;
    max-width: 100%;
    min-height: 100vh;
    overscroll-behavior-y: contain; /* 控制弹性滚动 */
}

/* 旅行主题背景 */
.travel-background {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: -2;
    background: linear-gradient(135deg, 
        rgba(93, 156, 236, 0.05) 0%, 
        rgba(72, 207, 173, 0.05) 50%, 
        rgba(255, 107, 157, 0.05) 100%);
    opacity: 0.3;
}

.travel-pattern {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: -1;
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(93, 156, 236, 0.1) 0%, transparent 20%),
        radial-gradient(circle at 90% 80%, rgba(72, 207, 173, 0.1) 0%, transparent 20%),
        radial-gradient(circle at 50% 50%, rgba(255, 107, 157, 0.08) 0%, transparent 30%);
    opacity: 0.15;
}

/* 主容器 */
.mobile-container {
    max-width: 100%;
    min-height: 100vh;
    position: relative;
    z-index: 1;
    overflow-x: hidden; /* 防止水平溢出 */
    width: 100%;
}

/* ============================================
   品牌头部 - 玻璃拟态设计
   ============================================ */

.brand-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 70px;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-bottom: 1px solid var(--glass-border);
    z-index: 2000;
    display: flex;
    align-items: center;
    padding: 0 var(--space-md);
    box-shadow: var(--shadow-sm);
}

.brand-container {
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.brand-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: inherit;
    gap: var(--space-sm);
    transition: all var(--duration-normal) ease;
    flex: 1;
    min-width: 0; /* 防止溢出 */
}

.brand-link:active {
    transform: scale(0.98);
}

.brand-logo {
    width: 50px;
    height: 50px;
    border-radius: var(--radius-circle);
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.4);
    background: var(--bg-white);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: var(--shadow-md);
    transition: all var(--duration-normal) ease;
    position: relative;
}

.brand-logo::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--gradient-primary);
    opacity: 0;
    transition: opacity var(--duration-normal) ease;
    border-radius: inherit;
}

.brand-logo:hover {
    transform: translateY(-2px) rotate(5deg);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-color);
}

.brand-logo:hover::before {
    opacity: 0.1;
}

.brand-logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: relative;
    z-index: 1;
}

.brand-text {
    flex: 1;
    min-width: 0;
}

.brand-name {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--primary-color);
    line-height: var(--leading-tight);
    margin-bottom: 2px;
    letter-spacing: 0.5px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.brand-slogan {
    font-size: 0.875rem;
    color: var(--text-secondary);
    font-weight: 500;
    line-height: var(--leading-snug);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 发现/返回首页按钮样式 - 修改：移除背景和边框，只保留图标和文字 */
.discover-button {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: transparent !important; /* 移除背景 */
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    border-radius: var(--radius-md);
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.875rem;
    border: none !important; /* 移除边框 */
    transition: all var(--duration-normal) cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: none !important; /* 移除阴影 */
    margin-left: auto;
    white-space: nowrap;
}

.discover-button:hover {
    background: rgba(93, 156, 236, 0.1) !important; /* 悬停时添加轻微背景 */
    color: var(--primary-color);
    transform: translateY(-2px);
}

.discover-button:active {
    transform: translateY(0) scale(0.98);
}

.discover-icon {
    font-size: 1rem;
}

.discover-text {
    display: none;
}

@media (min-width: 768px) {
    .discover-text {
        display: inline;
    }
}

@media (max-width: 767px) {
    .discover-button {
        padding: 8px;
        width: auto;
        height: auto;
        justify-content: center;
    }
    
    .discover-button .discover-text {
        display: none;
    }
}

/* ============================================
   搜索和标签模块 - 玻璃拟态增强 - 修改：缩小模块
   ============================================ */

.search-tags-module {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-radius: var(--radius-xl);
    padding: var(--space-sm); /* 缩小：原来是var(--space-lg) */
    margin: var(--space-sm) var(--space-sm) var(--space-md); /* 缩小：原来是var(--space-md) */
    box-shadow: var(--glass-shadow);
    border: 1px solid var(--glass-border);
    position: relative;
    z-index: 10;
    overflow: hidden; /* 防止内部元素导致水平滚动 */
}

/* 搜索框 - 修改：缩小 */
.search-container {
    background: var(--glass-bg-light);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: var(--radius-xl);
    padding: 4px 8px; /* 缩小：原来是6px 10px */
    display: flex;
    align-items: center;
    gap: 6px; /* 缩小：原来是8px */
    margin-bottom: 8px; /* 缩小：原来是var(--space-sm) */
    border: 2px solid rgba(255, 255, 255, 0.3);
    box-shadow: var(--shadow-md);
    transition: all var(--duration-normal) ease;
    position: relative;
    overflow: hidden;
}

.search-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(93, 156, 236, 0.1), 
        transparent);
    transition: left var(--duration-slow) ease;
}

.search-container:focus-within {
    border-color: var(--primary-color);
    box-shadow: 
        0 4px 20px rgba(93, 156, 236, 0.2),
        var(--shadow-md);
    transform: translateY(-2px);
}

.search-container:focus-within::before {
    left: 100%;
}

.search-icon {
    width: 32px; /* 缩小：原来是36px */
    height: 32px; /* 缩小：原来是36px */
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    font-size: 14px; /* 缩小：原来是16px */
    flex-shrink: 0;
}

.search-input {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 14px; /* 缩小：原来是var(--text-base) */
    padding: 4px 0; /* 缩小：原来是6px 0 */
    outline: none;
    font-weight: 500;
    min-width: 0;
    min-height: 32px; /* 缩小：原来是36px */
}

.search-input::placeholder {
    color: var(--text-light);
}

.search-button {
    background: var(--gradient-primary);
    color: var(--text-white);
    border: none;
    width: 32px; /* 缩小：原来是36px */
    height: 32px; /* 缩小：原来是36px */
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px; /* 缩小：原来是16px */
    cursor: pointer;
    transition: all var(--duration-normal) cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(93, 156, 236, 0.3);
    position: relative;
    overflow: hidden;
}

.search-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(255, 255, 255, 0.3), 
        transparent);
    transition: left var(--duration-slow) ease;
}

.search-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(93, 156, 236, 0.4);
}

.search-button:active {
    transform: scale(0.95) translateY(0);
    box-shadow: 0 2px 8px rgba(93, 156, 236, 0.2);
}

.search-button:active::before {
    left: 100%;
}

/* 热门标签区域 - 修改：缩小标签，限制高度为2排 */
.hot-tags-container {
    margin: 0;
    padding: 0;
}

.hot-tags-title {
    display: none; /* 移除热门标签提示文字和火图标 */
}

.hot-tags-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 4px; /* 缩小：原来是6px */
    max-height: 56px; /* 限制2排标签高度 (24px标签 + 4px间距) * 2 */
    overflow-y: auto;
    padding: 2px 0; /* 缩小：原来是2px 0 */
    -webkit-overflow-scrolling: touch; /* iOS平滑滚动 */
}

/* 修复：热门标签点击时文字看不清问题 */
.hot-tag {
    background: rgba(255, 255, 255, 0.9);
    color: var(--text-primary);
    border: 1px solid rgba(72, 207, 173, 0.15); /* 缩小边框 */
    border-radius: var(--radius-pill);
    padding: 4px 8px; /* 缩小：原来是6px 12px */
    font-size: 0.75rem; /* 缩小：原来是0.8rem */
    font-weight: 600;
    cursor: pointer;
    transition: all var(--duration-normal) cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    position: relative;
    overflow: hidden;
    user-select: none;
    z-index: 1;
    height: 24px; /* 固定高度 */
}

.hot-tag::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--gradient-secondary);
    opacity: 0;
    transition: opacity var(--duration-normal) ease;
    z-index: -1; /* 背景放在文字后面 */
    border-radius: inherit;
}

.hot-tag:hover,
.hot-tag:active,
.hot-tag:focus {
    border-color: rgba(72, 207, 173, 0.3);
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
    color: var(--text-primary) !important; /* 确保文字颜色不变 */
    text-shadow: 0 1px 1px rgba(0, 0, 0, 0.1); /* 增加文字阴影提高可读性 */
}

.hot-tag:hover::before {
    opacity: 0.85; /* 使用半透明背景，让文字可见 */
}

.hot-tag:active {
    transform: scale(0.95) translateY(0);
}

/* 移除标签数字显示相关样式 */
.tag-count {
    display: none;
}

/* ============================================
   筛选和排序工具栏 - 修改：移除提示文字，缩小
   ============================================ */

.filter-toolbar {
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-radius: var(--radius-md); /* 缩小：原来是var(--radius-lg) */
    padding: 8px 10px; /* 缩小：原来是10px 12px */
    margin: 0 var(--space-sm) 10px; /* 缩小：原来是0 var(--space-md) 12px */
    display: flex;
    flex-wrap: wrap;
    gap: 8px; /* 缩小：原来是var(--space-sm) */
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 70px;
    z-index: 100;
    border: 1px solid var(--glass-border);
}

.filter-group {
    flex: 1;
    min-width: 0;
}

/* 修改：移除提示文字 */
.filter-label {
    display: none; /* 移除"文章栏目"和"排序方式"提示文字 */
}

/* 现代简约下拉菜单 - 修改：缩小 */
.modern-dropdown {
    position: relative;
    width: 100%;
}

.dropdown-trigger {
    width: 100%;
    padding: 8px 32px 8px 10px; /* 缩小：原来是10px 36px 10px 12px */
    border: 1px solid rgba(72, 207, 173, 0.2); /* 缩小：原来是2px */
    border-radius: var(--radius-sm); /* 缩小：原来是var(--radius-md) */
    background: var(--glass-bg-light);
    color: var(--text-primary);
    font-size: 13px; /* 缩小：原来是var(--text-sm) */
    font-weight: 500;
    text-align: left;
    cursor: pointer;
    transition: all var(--duration-normal) ease;
    position: relative;
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    min-height: 36px; /* 缩小：原来是40px */
}

.dropdown-trigger:hover {
    border-color: var(--secondary-color);
    box-shadow: 0 4px 12px rgba(72, 207, 173, 0.15);
}

.dropdown-trigger:active {
    transform: translateY(1px);
}

.dropdown-trigger:after {
    content: "";
    position: absolute;
    right: 10px; /* 调整位置：原来是12px */
    top: 50%;
    transform: translateY(-50%) rotate(45deg);
    width: 6px; /* 缩小：原来是8px */
    height: 6px; /* 缩小：原来是8px */
    border-right: 2px solid var(--text-secondary);
    border-bottom: 2px solid var(--text-secondary);
    transition: transform var(--duration-normal) ease;
    pointer-events: none;
}

.dropdown-trigger.active:after {
    transform: translateY(-50%) rotate(-135deg);
    top: calc(50% + 2px);
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: var(--radius-sm); /* 缩小：原来是var(--radius-md) */
    box-shadow: var(--shadow-lg);
    margin-top: 6px; /* 缩小：原来是8px */
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all var(--duration-normal) cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    max-height: 280px; /* 缩小：原来是320px */
    overflow-y: auto;
    border: 1px solid var(--glass-border);
}

.dropdown-menu.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    padding: 8px 10px; /* 缩小：原来是10px 12px */
    color: var(--text-primary);
    font-size: 13px; /* 缩小：原来是var(--text-sm) */
    cursor: pointer;
    transition: all var(--duration-fast) ease;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    position: relative;
}

.dropdown-item:last-child {
    border-bottom: none;
}

.dropdown-item:hover {
    background: rgba(93, 156, 236, 0.1);
    color: var(--primary-color);
}

.dropdown-item.selected {
    background: linear-gradient(135deg, rgba(72, 207, 173, 0.1), rgba(93, 156, 236, 0.05));
    color: var(--secondary-color);
    font-weight: 600;
}

.dropdown-item.selected:before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px; /* 缩小：原来是4px */
    background: var(--secondary-color);
    border-radius: 0 2px 2px 0;
}

.sort-group {
    flex: 0 0 auto;
}

/* ============================================
   返回首页按钮
   ============================================ */

.back-home-container {
    display: none;
    margin: 0 var(--space-sm) var(--space-md);
}

.back-home-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
    padding: var(--space-sm) var(--space-md);
    background: var(--glass-bg);
    color: var(--text-primary);
    border: 2px solid var(--glass-border);
    border-radius: var(--radius-md);
    font-size: var(--text-sm);
    font-weight: 600;
    cursor: pointer;
    transition: all var(--duration-normal) ease;
    width: 100%;
    text-decoration: none;
    box-shadow: var(--shadow-sm);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.back-home-button:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.back-home-button:active {
    transform: scale(0.98);
}

/* ============================================
   笔记列表容器
   ============================================ */

.notes-container {
    padding: 0 var(--space-sm) 100px;
    overflow-x: hidden; /* 防止内容溢出导致水平滚动 */
    width: 100%;
    max-width: 100%;
}

.notes-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--space-md);
    padding: 0 var(--space-xs);
}

.notes-count {
    font-size: var(--text-sm);
    color: var(--text-secondary);
    font-weight: 600;
}

.layout-toggle {
    display: flex;
    gap: var(--space-xs);
    background: var(--bg-gray);
    padding: 4px;
    border-radius: var(--radius-md);
}

.layout-btn {
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-light);
    cursor: pointer;
    transition: all var(--duration-normal) ease;
}

.layout-btn.active {
    background: var(--bg-white);
    color: var(--primary-color);
    box-shadow: var(--shadow-sm);
}

.layout-btn:hover {
    transform: translateY(-2px);
}

/* 瀑布流网格布局 */
.notes-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-sm); /* 缩小：原来是var(--space-md) */
    margin: 0 auto;
    width: 100%;
}

.notes-list {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}

/* ============================================
   笔记卡片 - 沉浸式设计增强 - 修改：移动端显示优化
   ============================================ */

.note-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: all var(--duration-normal) cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    display: block;
    text-decoration: none;
    color: inherit;
    border: 1px solid rgba(0,0,0,0.05);
    will-change: transform, box-shadow;
}

.note-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: var(--shadow-xl);
}

.note-card:active {
    transform: translateY(-4px) scale(1.01);
    transition-duration: var(--duration-fast);
}

/* 卡片顶部徽章容器 - 新增：用于放置笔记类型和日期 */
.card-badges-container {
    position: absolute;
    top: 8px;
    left: 8px;
    right: 8px;
    z-index: 2;
    display: flex;
    justify-content: space-between;
    pointer-events: none; /* 防止干扰卡片点击 */
}

/* 笔记类型徽章 - 修改：完全透明玻璃拟态，亮色文字 */
.type-badge {
    background: rgba(255, 255, 255, 0.15) !important;
    backdrop-filter: blur(15px) saturate(180%);
    -webkit-backdrop-filter: blur(15px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #FFFFFF !important; /* 亮白色文字 */
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.4), 0 0 10px rgba(255, 255, 255, 0.3); /* 增强文字可读性 */
    padding: 4px 10px;
    border-radius: var(--radius-pill);
    font-size: 0.7rem;
    font-weight: 700;
    box-shadow: var(--shadow-md);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 50%;
}

/* 日期徽章 - 修改：完全透明玻璃拟态，亮色文字 */
.date-badge {
    background: rgba(255, 255, 255, 0.15) !important;
    backdrop-filter: blur(15px) saturate(180%);
    -webkit-backdrop-filter: blur(15px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #FFFFFF !important; /* 亮白色文字 */
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.4), 0 0 10px rgba(255, 255, 255, 0.3); /* 增强文字可读性 */
    padding: 4px 10px;
    border-radius: var(--radius-pill);
    font-size: 0.7rem;
    font-weight: 700;
    box-shadow: var(--shadow-md);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 50%;
}

/* 暗色模式下的徽章样式 */
@media (prefers-color-scheme: dark) {
    .type-badge,
    .date-badge {
        background: rgba(0, 0, 0, 0.3) !important;
        border: 1px solid rgba(255, 255, 255, 0.15);
        color: #FFFFFF !important;
        text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6), 0 0 8px rgba(255, 255, 255, 0.2);
    }
}

/* 移除旧的徽章样式 */
.travel-badge {
    display: none !important;
}

/* 笔记图片 */
.note-image {
    width: 100%;
    aspect-ratio: 16/9;
    overflow: hidden;
    position: relative;
    background: linear-gradient(45deg, var(--bg-gray), var(--bg-light));
}

.note-image::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.3) 0%, transparent 50%);
    opacity: 0;
    transition: opacity var(--duration-normal) ease;
}

.note-card:hover .note-image::after {
    opacity: 1;
}

.note-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--duration-slow) ease;
    display: block;
}

.image-placeholder {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, var(--bg-gray), var(--bg-light));
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-light);
    font-size: var(--text-sm);
}

.note-card:hover .note-image img {
    transform: scale(1.08);
}

.image-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: var(--space-md);
    z-index: 1;
}

/* 笔记内容 */
.note-content {
    padding: var(--space-md);
}

.note-title {
    font-family: var(--font-heading);
    font-size: var(--text-base);
    font-weight: 700;
    line-height: var(--leading-snug);
    color: var(--text-primary);
    margin-bottom: var(--space-sm);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.note-summary {
    font-size: var(--text-sm);
    line-height: var(--leading-relaxed);
    color: var(--text-secondary);
    margin-bottom: var(--space-md);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* 标签和地点 */
.note-tags {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-xs);
    margin-bottom: var(--space-md);
    transition: all var(--duration-normal) ease;
}

.note-tag {
    background: rgba(200, 200, 200, 0.1);
    color: var(--text-secondary);
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    font-size: var(--text-xs);
    font-weight: 500;
    white-space: nowrap;
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: all var(--duration-normal) ease;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    display: inline-block; /* 确保点击时只触发标签点击，而不是卡片点击 */
    text-decoration: none;
}

.note-tag:hover {
    background: rgba(93, 156, 236, 0.1);
    color: var(--primary-color);
    border-color: rgba(93, 156, 236, 0.2);
    transform: translateY(-1px);
}

.note-tag:active {
    transform: scale(0.95);
}

/* 位置标签的特殊样式 */
.location-tag {
    background: rgba(255, 107, 157, 0.05);
    color: var(--text-secondary);
    border: 1px solid rgba(255, 107, 157, 0.1);
}

.location-tag:hover {
    background: rgba(255, 107, 157, 0.1);
    color: var(--accent-color);
    border-color: rgba(255, 107, 157, 0.3);
}

/* 卡片底部信息区域 - 修改：品牌信息和点赞统计在同一行 */
.note-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: var(--space-sm);
    padding-top: var(--space-sm);
    border-top: 1px solid var(--glass-border);
}

/* 品牌信息 - 左侧 */
.brand-info {
    display: flex;
    align-items: center;
    gap: 6px;
    flex: 1;
    min-width: 0;
}

.brand-logo-small {
    width: 18px;
    height: 18px;
    border-radius: var(--radius-circle);
    overflow: hidden;
    flex-shrink: 0;
    border: 1px solid rgba(0,0,0,0.05);
}

.brand-logo-small img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.brand-name-small {
    font-size: 0.75rem; /* 12px */
    color: var(--text-secondary);
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 点赞统计 - 右侧灰色 */
.likes-stat {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
    color: #888888; /* 灰色文字 */
    font-size: 0.75rem;
    font-weight: 500;
}

.likes-stat .stat-icon {
    color: #AAAAAA; /* 灰色图标 */
    font-size: 12px;
    opacity: 0.8;
}

/* 移除旧的统计样式 */
.note-stats {
    display: none !important;
}

/* 移除旧的品牌信息样式 */
.note-brand-info {
    display: none !important;
}

/* ============================================
   空状态
   ============================================ */

.empty-state {
    text-align: center;
    padding: var(--space-3xl) var(--space-md);
    grid-column: 1 / -1;
}

.empty-icon {
    font-size: 48px;
    margin-bottom: var(--space-md);
    opacity: 0.3;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.empty-title {
    font-size: var(--text-lg);
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: var(--space-sm);
}

.empty-text {
    font-size: var(--text-sm);
    color: var(--text-light);
    margin-bottom: var(--space-md);
}

.reset-btn {
    background: var(--gradient-primary);
    color: var(--text-white);
    border: none;
    padding: var(--space-sm) var(--space-lg);
    border-radius: var(--radius-md);
    font-weight: 600;
    cursor: pointer;
    transition: all var(--duration-normal) ease;
    box-shadow: var(--shadow-md);
}

.reset-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.reset-btn:active {
    transform: scale(0.95);
}

/* ============================================
   加载更多按钮
   ============================================ */

.load-more-container {
    text-align: center;
    margin-top: var(--space-xl);
    padding: var(--space-md);
    grid-column: 1 / -1;
}

.load-more-btn {
    background: var(--gradient-primary);
    color: var(--text-white);
    border: none;
    padding: var(--space-md) var(--space-xl);
    border-radius: var(--radius-lg);
    font-weight: 600;
    font-size: var(--text-sm);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: var(--space-sm);
    transition: all var(--duration-normal) ease;
    box-shadow: var(--shadow-md);
    position: relative;
    overflow: hidden;
}

.load-more-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(255, 255, 255, 0.2), 
        transparent);
    transition: left var(--duration-slow) ease;
}

.load-more-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.load-more-btn:hover::before {
    left: 100%;
}

.load-more-btn:active {
    transform: translateY(0);
}

.load-more-btn.loading {
    opacity: 0.7;
    pointer-events: none;
}

.spinner {
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255,255,255,0.3);
    border-top: 2px solid var(--text-white);
    border-radius: var(--radius-circle);
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ============================================
   分页导航
   ============================================ */

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: var(--space-sm);
    margin-top: var(--space-xl);
    grid-column: 1 / -1;
}

.page-link {
    min-width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 600;
    transition: all var(--duration-normal) ease;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.page-link:hover,
.page-link.active {
    background: var(--gradient-primary);
    color: var(--text-white);
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

.page-link.prev,
.page-link.next {
    padding: 0 var(--space-md);
}

.page-link.disabled {
    opacity: 0.5;
    pointer-events: none;
}

/* ============================================
   页脚
   ============================================ */

.travel-footer {
    background: var(--glass-bg);
    border-top: 1px solid var(--glass-border);
    padding: var(--space-xl) var(--space-md);
    text-align: center;
    margin-top: var(--space-xl);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.footer-content {
    max-width: 800px;
    margin: 0 auto;
}

.footer-logo {
    font-size: 32px;
    color: var(--primary-color);
    margin-bottom: var(--space-md);
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.footer-title {
    font-family: var(--font-heading);
    font-size: var(--text-lg);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: var(--space-sm);
}

.footer-desc {
    font-size: var(--text-sm);
    color: var(--text-secondary);
    line-height: var(--leading-relaxed);
    margin-bottom: var(--space-md);
}

.copyright {
    font-size: var(--text-xs);
    color: var(--text-light);
    margin-top: var(--space-md);
    padding-top: var(--space-md);
    border-top: 1px solid var(--glass-border);
}

/* ============================================
   返回顶部按钮
   ============================================ */

.back-to-top {
    position: fixed;
    bottom: 80px;
    right: var(--space-md);
    width: 50px;
    height: 50px;
    background: var(--gradient-primary);
    color: var(--text-white);
    border: none;
    border-radius: var(--radius-circle);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    cursor: pointer;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transition: all var(--duration-normal) ease;
    z-index: 1000;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.back-to-top:hover {
    transform: translateY(-4px) scale(1.1);
    box-shadow: var(--shadow-xl);
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:active {
    transform: scale(0.95);
}

/* ============================================
   骨架屏样式
   ============================================ */

.skeleton {
    background: linear-gradient(90deg, 
        var(--bg-gray) 25%, 
        var(--bg-light) 50%, 
        var(--bg-gray) 75%);
    background-size: 200% 100%;
    animation: loading 1.5s ease-in-out infinite;
    border-radius: var(--radius-md);
}

.skeleton-text {
    height: 12px;
    margin-bottom: var(--space-sm);
    border-radius: var(--radius-sm);
}

.skeleton-text:last-child {
    width: 60%;
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

@media (prefers-color-scheme: dark) {
    .skeleton {
        background: linear-gradient(90deg, 
            var(--bg-gray) 25%, 
            var(--bg-dark) 50%, 
            var(--bg-gray) 75%);
    }
    
    .note-stats {
        color: #BBBBBB; /* 暗色模式下提高对比度 */
    }
}

/* ============================================
   响应式设计
   ============================================ */

@media (min-width: 640px) {
    html {
        font-size: 15px;
    }
    
    .notes-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--space-md); /* 恢复：原来是var(--space-lg) */
    }
    
    .note-title {
        font-size: var(--text-lg);
    }
    
    .brand-header {
        padding: 0 var(--space-lg);
    }
    
    .brand-name {
        font-size: 1.4rem;
    }
    
    .search-tags-module {
        padding: var(--space-md); /* 恢复：原来是var(--space-lg) */
        margin: var(--space-md) var(--space-md) var(--space-lg);
    }
    
    .back-home-container {
        margin: 0 var(--space-lg) var(--space-md);
    }
    
    .notes-container {
        padding: 0 var(--space-md) 100px;
    }
}

@media (min-width: 768px) {
    body {
        padding-top: calc(var(--safe-area-inset-top) + 90px);
    }
    
    .brand-header {
        height: 90px;
        padding: 0 var(--space-xl);
    }
    
    .brand-logo {
        width: 60px;
        height: 60px;
    }
    
    .brand-name {
        font-size: 1.6rem;
    }
    
    .brand-slogan {
        font-size: 1rem;
    }
    
    .filter-toolbar {
        top: 90px;
        flex-wrap: nowrap;
        gap: var(--space-md);
    }
    
    .notes-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: var(--space-md);
    }
    
    .search-tags-module {
        margin: var(--space-md) var(--space-xl);
        padding: var(--space-lg);
        border-radius: var(--radius-2xl);
    }
    
    .back-to-top {
        bottom: 40px;
        right: 40px;
    }
    
    .dropdown-menu {
        max-height: 280px;
    }
    
    /* PC端显示日期徽章 */
    .date-badge {
        display: block;
    }
    
    .notes-container {
        padding-bottom: 60px;
    }
    
    .back-home-container {
        max-width: 300px;
        margin-left: auto;
        margin-right: auto;
    }
}

@media (min-width: 1024px) {
    .notes-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: var(--space-md);
    }
    
    .mobile-container {
        max-width: 1200px;
        margin: 0 auto;
    }
    
    .brand-header .brand-container,
    .search-tags-module {
        max-width: 1200px;
        margin-left: auto;
        margin-right: auto;
    }
    
    .search-tags-module {
        margin: var(--space-md) auto;
        padding: var(--space-xl);
    }
    
    .notes-container {
        padding: 0 var(--space-lg) 100px;
    }
    
    .dropdown-menu {
        max-height: 260px;
    }
    
    .back-home-container {
        max-width: 400px;
    }
}

@media (min-width: 1280px) {
    .notes-grid {
        grid-template-columns: repeat(5, 1fr);
        gap: var(--space-md);
    }
}

/* 性能优化 */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* 打印样式 */
@media print {
    .travel-background,
    .travel-pattern,
    .filter-toolbar,
    .layout-toggle,
    .load-more-btn,
    .back-to-top,
    .back-home-container,
    .search-tags-module,
    .brand-header {
        display: none !important;
    }
    
    .notes-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 10px !important;
    }
    
    .note-card {
        break-inside: avoid;
        box-shadow: none !important;
        border: 1px solid #ddd !important;
    }
    
    body {
        padding-top: 0 !important;
    }
}