/* 全局样式 */
* {
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    margin: 0;
    padding: 0;
    -webkit-font-smoothing: antialiased;
}

/* 隐藏滚动条（保留滚动功能） */
body::-webkit-scrollbar {
    display: none;
}

/* 选中状态样式 */
.cup-size-btn.active,
.tag-btn.active {
    background-color: #2563eb;
    color: white;
    border-color: #2563eb;
}

/* 帖子卡片 */
.post-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s;
}

.post-card:active {
    transform: scale(0.98);
}

.post-card-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

/* 图片轮播 */
.image-carousel {
    position: relative;
    width: 100%;
    height: 300px;
    background: #000;
}

.carousel-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.carousel-controls {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
}

.carousel-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    transition: background 0.3s;
}

.carousel-dot.active {
    background: white;
    width: 24px;
    border-radius: 4px;
}

.carousel-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
}

.carousel-nav.prev {
    left: 10px;
}

.carousel-nav.next {
    right: 10px;
}

/* 标签样式 */
.tag {
    display: inline-block;
    padding: 4px 12px;
    background: #eff6ff;
    color: #2563eb;
    border-radius: 12px;
    font-size: 12px;
    margin: 2px;
}

/* 加载更多 */
.load-more {
    text-align: center;
    padding: 20px;
}

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #9ca3af;
}

/* 模态框动画 */
#filter-modal.active {
    display: block;
}

/* Range Input 样式 */
input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    height: 6px;
    border-radius: 3px;
    background: #e5e7eb;
    outline: none;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #2563eb;
    cursor: pointer;
}

input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #2563eb;
    cursor: pointer;
    border: none;
}

/* 按钮点击效果 */
button:active {
    opacity: 0.8;
}

/* 禁用状态 */
button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}
