/* ============================================================
   assets/style.css - 主样式表（现代化美化设计）
   ============================================================ */
:root {
    --primary: #6c5ce7;
    --primary-light: #a29bfe;
    --bg: #f8f9fc;
    --card-bg: #ffffff;
    --text: #2d3436;
    --text-light: #636e72;
    --border: #e8ecf1;
    --shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.1);
    --radius: 12px;
    --radius-sm: 8px;
    --transition: 0.25s ease;
    --success: #27ae60;
    --danger: #e74c3c;
    --warning: #f39c12;
}
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', 'Noto Sans SC', sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.7;
    min-height: 100vh;
}
a {
    color: var(--primary);
    text-decoration: none;
    transition: var(--transition);
}
a:hover {
    color: #5a4bd1;
}
img {
    max-width: 100%;
    height: auto;
}

/* 头部 */
.site-header {
    background: #fff;
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}
.header-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 60px;
}
.site-logo {
    font-size: 22px;
    font-weight: 700;
    color: var(--primary);
    letter-spacing: -0.5px;
}
.site-nav {
    display: flex;
    gap: 4px;
    align-items: center;
    flex-wrap: wrap;
}
.site-nav a {
    padding: 8px 14px;
    border-radius: 20px;
    font-size: 14px;
    color: var(--text-light);
    font-weight: 500;
    white-space: nowrap;
}
.site-nav a:hover {
    background: #f0edff;
    color: var(--primary);
}
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--text);
}

/* 主体 */
.main-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 24px 20px;
}
.content-wrapper {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 24px;
}
.main-content {
    min-width: 0;
}
.sidebar {
    position: sticky;
    top: 80px;
    align-self: start;
}

/* 卡片 */
.card {
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 20px;
    margin-bottom: 16px;
    transition: var(--transition);
    border: 1px solid var(--border);
}
.card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-1px);
}

/* 文章卡片 */
.article-card {
    display: flex;
    gap: 16px;
    overflow: hidden;
}
.article-card.pinned {
    border-left: 3px solid var(--warning);
}
.pin-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #fff3cd;
    color: #856404;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}
.card-cover {
    flex-shrink: 0;
    width: 200px;
    height: 140px;
    border-radius: var(--radius-sm);
    overflow: hidden;
}
.card-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}
.card-cover img:hover {
    transform: scale(1.05);
}
.card-body {
    flex: 1;
    min-width: 0;
}
.card-title {
    font-size: 18px;
    margin-bottom: 8px;
    line-height: 1.4;
}
.card-title a {
    color: var(--text);
}
.card-title a:hover {
    color: var(--primary);
}
.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 13px;
    color: var(--text-light);
    margin-bottom: 8px;
    align-items: center;
}
.meta-avatar {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    vertical-align: middle;
    margin-right: 2px;
}
.card-excerpt {
    color: var(--text-light);
    font-size: 14px;
    line-height: 1.6;
}
.btn-read {
    display: inline-block;
    margin-top: 8px;
    font-weight: 600;
    font-size: 14px;
    color: var(--primary);
}
.note-tag {
    background: #e8f5e9;
    color: #2e7d32;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 11px;
}

/* 按钮 */
.btn {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 25px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    font-size: 14px;
    transition: var(--transition);
    text-align: center;
}
.btn-primary {
    background: var(--primary);
    color: #fff;
    box-shadow: 0 4px 12px rgba(108, 92, 231, 0.3);
}
.btn-primary:hover {
    background: #5a4bd1;
    transform: translateY(-2px);
    color: #fff;
}
.btn-outline {
    background: #fff;
    color: var(--primary);
    border: 2px solid var(--primary);
}
.btn-outline:hover {
    background: #f0edff;
}
.btn-danger {
    background: #fff;
    color: var(--danger);
    border: 1px solid var(--danger);
}
.btn-success {
    background: var(--success);
    color: #fff;
}
.btn-sm {
    padding: 6px 14px;
    font-size: 12px;
}
.btn-lg {
    padding: 14px 32px;
    font-size: 16px;
}
.btn-block {
    display: block;
    width: 100%;
    margin: 8px 0;
}

/* 广告位 */
.ad-section {
    margin: 12px 0;
    text-align: center;
    overflow: hidden;
    border-radius: var(--radius-sm);
}
.ad-placeholder {
    background: #f1f3f5;
    border: 2px dashed #dee2e6;
    padding: 24px;
    color: #adb5bd;
    font-size: 13px;
    border-radius: var(--radius-sm);
}

/* 侧边栏 */
.sidebar-widget {
    background: #fff;
    border-radius: var(--radius);
    padding: 16px;
    margin-bottom: 16px;
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
}
.widget-title {
    font-size: 15px;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 2px solid #f0edff;
    color: var(--text);
}
.mini-item {
    padding: 6px 0;
    border-bottom: 1px solid #f8f9fa;
    font-size: 13px;
}
.mini-item a {
    color: var(--text);
}
.mini-item a:hover {
    color: var(--primary);
}
.mini-meta {
    font-size: 11px;
    color: #adb5bd;
    display: block;
}
.mini-cover {
    width: 40px;
    height: 40px;
    border-radius: 6px;
    object-fit: cover;
    float: left;
    margin-right: 8px;
}
.music-mini {
    display: flex;
    align-items: center;
    gap: 8px;
}
.links-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.link-item {
    padding: 4px 10px;
    background: #f8f9fa;
    border-radius: 15px;
    font-size: 12px;
    color: var(--text-light);
}
.link-item:hover {
    background: #f0edff;
    color: var(--primary);
}
.user-avatar-lg {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: block;
    margin: 0 auto 8px;
}
.user-info-sidebar {
    text-align: center;
    margin-bottom: 12px;
}
.role-badge {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
}
.role-badge.admin {
    background: #fde8e8;
    color: #c0392b;
}
.role-badge.user {
    background: #e8f4fd;
    color: #2980b9;
}

/* 分类导航 */
.category-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 16px;
}
.cat-item {
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 13px;
    background: #fff;
    border: 1px solid var(--border);
    color: var(--text-light);
    transition: var(--transition);
}
.cat-item.active,
.cat-item:hover {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

/* 分页 */
.pagination {
    display: flex;
    gap: 6px;
    justify-content: center;
    margin: 20px 0;
}
.page-link {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #fff;
    border: 1px solid var(--border);
    font-size: 14px;
    color: var(--text);
}
.page-link.active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

/* 文章详情 */
.article-detail .article-cover-full {
    border-radius: var(--radius);
    overflow: hidden;
    margin: -20px -20px 20px;
}
.article-cover-full img {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
}
.article-title-full {
    font-size: 26px;
    margin-bottom: 12px;
}
.article-meta-full {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    font-size: 13px;
    color: var(--text-light);
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border);
}
.article-content {
    font-size: 16px;
    line-height: 1.9;
    word-break: break-word;
}

/* 评论 */
.comments-section {
    margin-top: 20px;
}
.comment-form textarea {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 12px;
    font-size: 14px;
    resize: vertical;
    font-family: inherit;
}
.comment-item {
    padding: 12px;
    border-bottom: 1px solid #f1f3f5;
}
.comment-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
}
.comment-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
}
.comment-time {
    font-size: 11px;
    color: #adb5bd;
}
.comment-body {
    margin: 4px 0;
    font-size: 14px;
}
.btn-reply {
    background: none;
    border: none;
    color: var(--primary);
    cursor: pointer;
    font-size: 12px;
}

/* 底部板块 */
.bottom-sections {
    margin-top: 32px;
}
.bottom-section {
    margin-bottom: 24px;
}
.bottom-section h3 {
    margin-bottom: 12px;
    font-size: 18px;
}
.section-more {
    font-size: 13px;
    font-weight: normal;
}
.photo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 10px;
}
.photo-item {
    position: relative;
    border-radius: var(--radius-sm);
    overflow: hidden;
    aspect-ratio: 4/3;
    display: block;
}
.photo-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}
.photo-item:hover img {
    transform: scale(1.08);
}
.photo-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.7));
    color: #fff;
    padding: 8px;
    font-size: 12px;
}
.movie-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 12px;
}
.movie-card-sm {
    background: #fff;
    border-radius: var(--radius-sm);
    overflow: hidden;
    box-shadow: var(--shadow);
    text-align: center;
    display: block;
}
.movie-card-sm img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}
.movie-info-sm {
    padding: 8px;
    font-size: 13px;
}
.rating {
    color: #f39c12;
    font-weight: 600;
}
.share-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 10px;
}
.share-card-sm {
    background: #fff;
    border-radius: var(--radius-sm);
    overflow: hidden;
    box-shadow: var(--shadow);
    display: block;
}
.share-card-sm img {
    width: 100%;
    height: 120px;
    object-fit: cover;
}
.share-title-sm {
    padding: 8px;
    display: block;
    font-size: 13px;
    color: var(--text);
}

/* 音乐网格 */
.music-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}
.music-card {
    text-align: center;
}
.music-cover {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 10px;
}
.music-embed {
    margin: 10px 0;
    overflow: hidden;
    border-radius: 8px;
}

/* 照片瀑布流 */
.photo-masonry {
    columns: 3 220px;
    gap: 12px;
}
.photo-masonry-item {
    break-inside: avoid;
    display: block;
    margin-bottom: 12px;
    border-radius: var(--radius-sm);
    overflow: hidden;
    position: relative;
}
.photo-masonry-item img {
    width: 100%;
    display: block;
    transition: var(--transition);
}
.photo-masonry-item:hover img {
    transform: scale(1.05);
}
.photo-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    padding: 6px 10px;
    font-size: 12px;
}

/* 电影网格大 */
.movie-grid-lg {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 16px;
}
.movie-card-lg {
    text-align: center;
    display: block;
    color: var(--text);
}
.movie-card-lg img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    border-radius: var(--radius-sm);
    margin-bottom: 8px;
}
.movie-detail-cover {
    float: right;
    width: 200px;
    border-radius: var(--radius-sm);
    margin: 0 0 16px 16px;
}

/* 分享列表 */
.share-card-full {
    display: flex;
    gap: 14px;
    align-items: flex-start;
}
.share-cover-sm {
    width: 100px;
    height: 70px;
    object-fit: cover;
    border-radius: 6px;
    flex-shrink: 0;
}

/* 认证页面 */
.auth-container {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 80vh;
    padding: 20px;
}
.auth-card {
    width: 100%;
    max-width: 420px;
    padding: 30px;
}
.auth-card h2 {
    text-align: center;
    margin-bottom: 20px;
}

/* 表单 */
.form-group {
    margin-bottom: 14px;
}
.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 4px;
    font-size: 13px;
    color: var(--text-light);
}
.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-family: inherit;
    transition: var(--transition);
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-light);
    box-shadow: 0 0 0 3px rgba(108, 92, 231, 0.1);
}
.form-row {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

/* 用户中心 */
.user-layout {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 24px;
}
.user-sidebar {
    background: #fff;
    border-radius: var(--radius);
    padding: 16px;
    border: 1px solid var(--border);
    height: fit-content;
}
.user-sidebar a {
    display: block;
    padding: 8px 12px;
    border-radius: 6px;
    margin: 2px 0;
    font-size: 14px;
    color: var(--text);
}
.user-sidebar a.active,
.user-sidebar a:hover {
    background: #f0edff;
    color: var(--primary);
}
.my-content-item {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}
.status-badge {
    font-size: 12px;
    padding: 2px 8px;
    border-radius: 10px;
}
.status-pending {
    background: #fff3cd;
    color: #856404;
}
.status-approved {
    background: #d4edda;
    color: #155724;
}
.status-rejected {
    background: #fde8e8;
    color: #721c24;
}

/* 页脚 */
.site-footer {
    background: #2d3436;
    color: #b2bec3;
    text-align: center;
    padding: 24px 20px;
    margin-top: 40px;
    font-size: 13px;
}
.site-footer a {
    color: #dfe6e9;
}
.footer-inner p {
    margin: 4px 0;
}

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 40px;
    color: #adb5bd;
}
.empty-icon {
    font-size: 48px;
    margin-bottom: 12px;
}

/* 面包屑 */
.breadcrumb {
    font-size: 13px;
    color: var(--text-light);
    margin-bottom: 12px;
}
.breadcrumb a {
    color: var(--text-light);
}
.breadcrumb a:hover {
    color: var(--primary);
}

/* 警告提示 */
.alert {
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    margin: 10px 0;
    font-size: 14px;
}
.alert-success {
    background: #d4edda;
    color: #155724;
}
.alert-danger {
    background: #fde8e8;
    color: #721c24;
}

/* 响应式 */
@media (max-width: 900px) {
    .content-wrapper {
        grid-template-columns: 1fr;
    }
    .sidebar {
        position: static;
    }
    .article-card {
        flex-direction: column;
    }
    .card-cover {
        width: 100%;
        height: 180px;
    }
    .user-layout {
        grid-template-columns: 1fr;
    }
    .user-sidebar {
        display: flex;
        flex-wrap: wrap;
        gap: 4px;
    }
    .user-sidebar a {
        display: inline-block;
    }
    .photo-masonry {
        columns: 2 160px;
    }
    .site-nav {
        display: none;
        position: absolute;
        top: 60px;
        left: 0;
        right: 0;
        background: #fff;
        flex-direction: column;
        padding: 12px;
        box-shadow: var(--shadow-lg);
        border-radius: 0 0 var(--radius) var(--radius);
    }
    .site-nav.open {
        display: flex;
    }
    .mobile-menu-btn {
        display: block;
    }
    .movie-detail-cover {
        float: none;
        width: 100%;
        margin: 0 0 16px;
    }
    .share-card-full {
        flex-direction: column;
    }
}
@media (max-width: 500px) {
    .photo-masonry {
        columns: 1;
    }
    .movie-grid,
    .music-grid,
    .movie-grid-lg {
        grid-template-columns: 1fr 1fr;
    }
    .card-meta {
        font-size: 11px;
        gap: 6px;
    }
}
.type-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}
.type-tab {
    padding: 10px 18px;
    border-radius: 25px;
    background: #f1f3f5;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
    border: 2px solid transparent;
}
.type-tab.active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
    box-shadow: 0 4px 12px rgba(108,92,231,0.3);
}
.type-tab input { display: none; }