/* 全局样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background-color: #ffffff;
    color: #000000;
    line-height: 1.6;
    padding: 20px;
    max-width: 768px;
    margin: 0 auto;
    text-align: center;
}

/* 确保在所有屏幕尺寸上都使用手机端布局 */
@media (min-width: 768px) {
    body {
        padding: 20px;
        max-width: 768px;
        margin: 0 auto;
    }
    
    .mobile-header {
        margin-bottom: 20px;
    }
    
    .website-logo {
        width: 100px;
        height: 100px;
        margin-right: 20px;
    }
    
    .website-title {
        font-size: 28px;
    }
    
    .website-domain {
        font-size: 20px;
    }
    
    .modern-carousel {
        height: 300px;
    }
    
    .site-bar {
        height: 60px;
    }
    
    .marquee-content {
        font-size: 24px;
    }
    
    .main-content {
        padding: 30px;
    }
    
    .category-tag {
        padding: 12px 30px;
        font-size: 20px;
    }
    
    .cards-section {
        gap: 30px;
    }
    
    .website-card-logo {
        width: 1.3cm;
        height: 1.3cm;
    }
    
    .website-card-name {
        font-size: 18px;
    }
    
    .mobile-footer {
        padding: 20px;
        font-size: 24px;
    }
}

/* 顶部导航栏 */
.mobile-header {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
    background-color: transparent;
    border: none;
    padding: 0;
}

.logo-section {
    display: flex;
    align-items: center;
    width: 100%;
}

.website-logo {
    width: 70px;
    height: 70px;
    border: none;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: bold;
    margin-right: 15px;
    background-color: #ffffff;
    object-fit: contain;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.website-logo:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.site-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    flex: 1;
    padding: 0;
    margin: 0;
    text-align: left;
}

.website-title {
    font-size: 24px;
    font-weight: bold;
    margin: 0 0 3px 0;
    color: #000000;
    font-family: Arial, sans-serif;
    line-height: 1.2;
}

.website-domain {
    font-size: 16px;
    margin: 0;
    font-family: Arial, sans-serif;
    line-height: 1.2;
    font-weight: bold;
    cursor: pointer;
    background: linear-gradient(90deg, #ff0000, #ff9900, #ffff00, #33cc33, #3366ff, #9933ff, #ff3399, #ff0000);
    background-size: 800% 800%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: rainbow 3s ease infinite;
}

@keyframes rainbow {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

/* 轮播图 */
.modern-carousel {
    width: 100%;
    height: 180px;
    border: none;
    border-radius: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 20px;
    background-color: #ffffff;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

/* 轮播图悬停效果 */
.modern-carousel:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

/* 轮播图内容 */
.modern-carousel::before {
    content: '';
    font-size: 32px;
    font-weight: bold;
    color: #000000;
    font-family: Arial, sans-serif;
}

.carousel-container {
    width: 100%;
    height: 100%;
    overflow: hidden;
    position: relative;
}

.carousel-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    visibility: hidden;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1;
}

.carousel-slide.active {
    opacity: 1;
    visibility: visible;
    z-index: 2;
}

.carousel-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 0;
    background-color: #ffffff;
}

.carousel-link {
    display: block;
    width: 100%;
    height: 100%;
}

/* 滚动公告栏 */
.site-bar {
    width: 100%;
    height: 50px;
    border: none;
    border-radius: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    background-color: #E1FAF8;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    padding: 0 20px;
}

.marquee-container {
    width: 100%;
    height: 100%;
    overflow: hidden;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: transparent;
}

.marquee-content {
    display: inline-block;
    white-space: nowrap;
    font-size: 16px;
    font-weight: bold;
    animation: marquee 10s linear infinite;
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
    background: linear-gradient(90deg, #0099ff, #33ccff, #66ffff, #3399ff, #0066cc, #003399, #0099ff);
    background-size: 800% 800%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: marquee 10s linear infinite, rainbow 3s ease infinite;
}

@keyframes rainbow-text {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

@keyframes marquee {
    0% {
        left: 100%;
        transform: translateY(-50%);
    }
    100% {
        left: -100%;
        transform: translateY(-50%);
    }
}

/* 主内容区域 */
.main-content {
    border: none;
    border-radius: 30px;
    padding: 30px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

/* 分类标签 */
.category-tags {
    display: flex;
    gap: clamp(10px, 3vw, 15px);
    margin-bottom: 30px;
    padding: 0 10px 20px;
    border-bottom: none;
    overflow-x: auto;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    flex-wrap: nowrap;
    align-items: center;
    width: 100%;
    box-sizing: border-box;
}

/* 隐藏滚动条但保留功能 */
.category-tags::-webkit-scrollbar {
    display: none;
}

.category-tags {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.category-tag {
    padding: clamp(6px, 2vw, 8px) clamp(12px, 4vw, 20px);
    border: 1px solid #000000;
    border-radius: 20px;
    font-size: clamp(12px, 3vw, 16px);
    font-weight: bold;
    background-color: #ffffff;
    color: #000000;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex: 0 0 auto;
    white-space: nowrap;
    min-width: 60px;
    max-width: 150px;
    overflow: hidden;
    text-overflow: clip;
}

/* 分类标签悬停效果 */
.category-tag:hover {
    background-color: #f0f0f0;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* 分类标签点击效果 */
.category-tag:active {
    background-color: #000000;
    color: #ffffff;
}

/* 分类标签激活状态 */
.category-tag.active {
    background-color: #000000;
    color: #ffffff;
    border: 1px solid #000000;
}

/* 媒体查询：小型移动设备 */
@media (max-width: 480px) {
    .category-tag {
        font-size: clamp(11px, 4vw, 14px);
        padding: clamp(5px, 2.5vw, 7px) clamp(10px, 5vw, 18px);
        max-width: 120px;
    }
    
    .category-tags {
        gap: clamp(8px, 2.5vw, 12px);
        padding-bottom: 15px;
    }
}

/* 媒体查询：中型移动设备 */
@media (min-width: 481px) and (max-width: 768px) {
    .category-tag {
        font-size: clamp(12px, 3.5vw, 15px);
        padding: clamp(6px, 2.2vw, 8px) clamp(12px, 4.5vw, 19px);
        max-width: 130px;
    }
    
    .category-tags {
        gap: clamp(10px, 2.8vw, 14px);
    }
}

/* 媒体查询：横屏模式 */
@media (orientation: landscape) {
    .category-tag {
        font-size: clamp(11px, 2.5vw, 16px);
        padding: clamp(6px, 1.8vw, 8px) clamp(12px, 3.5vw, 20px);
    }
    
    .category-tags {
        gap: clamp(10px, 2.5vw, 15px);
    }
}

/* 媒体查询：高密度显示器 */
@media (-webkit-device-pixel-ratio: 2), (resolution: 192dpi), (resolution: 2dppx) {
    .category-tag {
        font-synthesis: none;
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }
}

/* 媒体查询：极小屏幕设备 */
@media (max-width: 320px) {
    .category-tag {
        font-size: clamp(10px, 5vw, 13px);
        padding: clamp(4px, 3vw, 6px) clamp(8px, 6vw, 16px);
        max-width: 100px;
        min-width: 60px;
    }
    
    .category-tags {
        gap: clamp(6px, 3vw, 10px);
        padding-bottom: 10px;
    }
}

/* 工具提示样式，用于显示完整分类名称 */
.category-tag {
    position: relative;
}

.category-tag:hover::after {
    content: attr(data-full-name);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background-color: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    white-space: nowrap;
    z-index: 1000;
    margin-bottom: 5px;
    pointer-events: none;
}

/* 仅在需要时显示工具提示（当标签文本可能被截断时） */
.category-tag[data-full-name]:hover::after {
    display: block;
}

.category-tag:not([data-full-name]):hover::after {
    display: none;
}

/* 网站卡片网格 */
.cards-section {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin: 0;
    width: 100%;
    padding: 0;
    background-color: transparent;
    border: none;
    border-radius: 0;
    justify-items: center;
}

/* 网站卡片 */
.website-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #000000;
    width: 100%;
    max-width: 100px;
}

.website-card-logo {
    width: 1.3cm;
    height: 1.3cm;
    border: none;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 8px;
    background-color: #ffffff;
    object-fit: cover;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

/* 网站logo悬停效果 */
.website-card-logo:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.website-card-name {
    font-size: 14px;
    font-weight: bold;
    text-align: center;
    color: #000000;
    font-family: Arial, sans-serif;
    line-height: 1.2;
}

/* 未有链接提示 */
.no-links-message {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 200px;
    text-align: center;
}

.no-links-message p {
    font-size: 24px;
    font-weight: bold;
    color: #000000;
    margin: 0;
    padding: 20px;
    background-color: #f5f5f5;
    border-radius: 10px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

/* 页脚 */
.mobile-footer {
    margin-top: 20px;
    padding: 15px;
    border: none;
    border-radius: 20px;
    text-align: center;
    font-size: 16px;
    font-weight: bold;
    background-color: #ffffff;
    width: 100%;
    max-width: 100%;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.copyright-info {
    text-align: center;
}

.copyright-info p {
    font-size: 16px;
    font-weight: bold;
    color: #000000;
    margin: 0;
    font-family: Arial, sans-serif;
}

/* 响应式设计 - 平板端 (768px以下) */
@media (max-width: 768px) {
    /* 全局样式 */
    body {
        padding: 15px;
    }
    
    /* 顶部导航栏适配 */
    .website-logo {
        width: 80px;
        height: 80px;
        font-size: 20px;
        margin-right: 15px;
    }
    
    .website-title {
        font-size: 24px;
    }
    
    .website-domain {
        font-size: 18px;
    }
    
    /* 轮播图适配 */
    .modern-carousel {
        height: 250px;
        font-size: 28px;
        border-radius: 0;
    }
    
    /* 滚动公告栏适配 */
    .site-bar {
        height: 50px;
        font-size: 20px;
        border-radius: 25px;
    }
    
    .marquee-content {
        font-size: 20px;
    }
    
    /* 主内容区域适配 */
    .main-content {
        padding: 25px;
        border-radius: 25px;
    }
    
    /* 分类标签适配 */
    .category-tags {
        gap: 15px;
        margin-bottom: 25px;
    }
    
    .category-tag {
        padding: 10px 25px;
        font-size: 18px;
        border-radius: 20px;
    }
    
    /* 网站卡片网格适配 */
    .cards-section {
        gap: 25px;
    }
    
    /* 网站卡片适配 */
    .website-card-logo {
        width: 1.3cm;
        height: 1.3cm;
        font-size: 18px;
        border-radius: 15px;
    }
    
    .website-card-name {
        font-size: 16px;
    }
    
    /* 页脚适配 */
    .mobile-footer {
        padding: 15px;
        font-size: 20px;
        border-radius: 25px;
    }
    
    .copyright-info p {
        font-size: 20px;
    }
}

/* 响应式设计 - 手机端 (480px以下) */
@media (max-width: 480px) {
    /* 全局样式 */
    body {
        padding: 10px;
    }
    
    /* 顶部导航栏适配 */
    .logo-section {
        flex-direction: row;
        align-items: center;
    }
    
    .website-logo {
        margin-bottom: 0;
        margin-right: 15px;
    }
    
    /* 轮播图适配 */
    .modern-carousel {
        height: 200px;
        font-size: 24px;
        border-radius: 0;
    }
    
    /* 滚动公告栏适配 */
    .site-bar {
        height: 45px;
        font-size: 18px;
        border-radius: 20px;
    }
    
    .marquee-content {
        font-size: 18px;
    }
    
    /* 主内容区域适配 */
    .main-content {
        padding: 20px;
        border-radius: 20px;
    }
    
    /* 分类标签适配 */
    .category-tags {
        gap: 12px;
        overflow-x: auto;
        white-space: nowrap;
        scroll-behavior: smooth;
        -webkit-overflow-scrolling: touch;
    }
    
    .category-tag {
        flex: 0 0 calc(33.333% - 8px);
        min-width: 100px;
        text-align: center;
    }
    
    /* 网站卡片网格适配 */
    .cards-section {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }
    
    /* 网站卡片适配 */
    .website-card-logo {
        width: 1.3cm;
        height: 1.3cm;
    }
    
    /* 页脚适配 */
    .mobile-footer {
        font-size: 18px;
        border-radius: 20px;
    }
    
    .copyright-info p {
        font-size: 18px;
    }
}

/* 隐藏轮播控制按钮和指示器，因为设计中没有这些元素 */
.carousel-control,
.carousel-dots {
    display: none;
}

/* 隐藏banner默认样式 */
.banner {
    display: none;
}

/* 隐藏旧的导航按钮组 */
.nav-buttons {
    display: none;
}

/* 隐藏旧的卡片样式 */
.card {
    display: none;
}

/* 隐藏旧的卡片内容 */
.card-content {
    display: none;
}

/* 隐藏旧的卡片图标 */
.card-icon {
    display: none;
}

/* 隐藏旧的卡片信息 */
.card-info {
    display: none;
}

/* 隐藏旧的卡片链接 */
.card-link {
    display: none;
}

