*{box-sizing:border-box;margin:0;padding:0;font-family:system-ui,-apple-system,"Segoe UI",Roboto,sans-serif;}
html,body{width:100%;overflow-x:hidden;}
body{background:#f7f8fa;padding-bottom:90px;}
.container{width:100%;max-width:520px;margin:0 auto;padding:12px;}

/* 公告 */
.notice{
    background:#ffffff;
    box-shadow:0 2px 12px rgba(0,0,0,0.05);
    border-radius:16px;
    padding:14px 16px;
    margin-bottom:12px;
    display:flex;
    align-items:center;
    gap:10px;
    font-size:16px;
    color:#4a7c42;
    overflow:hidden;
    width:100%;
}
.notif {
    width:22px;
    height:22px;
    flex-shrink:0;
    object-fit:contain;
}
.marquee {
    flex:1;
    line-height:22px;
    white-space:nowrap;
    overflow:hidden;
}
.marquee p {
    display:inline-block;
    padding-right:50px;
    font-size:16px;
    color:#4a7c42;
    animation:marquee 12s linear infinite;
}
@keyframes marquee {
    0%{transform:translate(0,0);}
    100%{transform:translate(-100%,0);}
}
.notice:hover .marquee p{
    animation-play-state:paused;
}

/* 访问统计条 */
.stats-bar {
    width: 100%;
    background: #fff;
    border-radius: 12px;
    padding: 10px 6px;
    margin: 0 auto 16px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}
.stats-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 4px 10px;
    font-size: 13px;
}
.stats-item {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
}
.stats-label {
    font-size: 12px;
    color: #666;
}
.stats-value {
    font-size: 15px;
    font-weight: bold;
    color: #165dff;
    transition: all 0.3s ease;
}
/* 活跃访客 绿色 */
#activeVisitors {
    color: #00B42A;
}
/* 今日访问 橙色 */
#todayVisitors {
    color: #FF7D00;
}
/* 跳动动画 */
.stats-value.updating {
    transform: scale(1.08);
    text-shadow: 0 0 10px rgba(22,93,255,0.4);
}
#activeVisitors.updating {
    text-shadow: 0 0 10px rgba(0,180,42,0.5);
}
#todayVisitors.updating {
    text-shadow: 0 0 10px rgba(255,125,0,0.5);
}
.stats-divider {
    color: #ccc;
    line-height: 20px;
}

/* 轮播广告 */
.slide-ad {
    width:100%;
    margin-bottom:16px;
    border-radius:18px;
    overflow:hidden;
    box-shadow:0 4px 15px rgba(0,0,0,0.1);
}
.slide-list {
    display:flex;
    transition:transform 0.5s ease;
    width:100%;
}
.slide-item {
    flex:0 0 100%;
    width:100%;
}
.slide-item img {
    display:block;
    width:100%;
    height:auto;
    object-fit:cover;
}

/* 链接样式 */
a{text-decoration:none !important;}
.download-btn{text-decoration:none !important;}

/* APP 网格自适应 */
.app-grid{
    display:grid;
    grid-template-columns:repeat(3,1fr);
    gap:10px;
    width:100%;
    margin-bottom:20px;
}
@media(min-width:375px){
    .app-grid{grid-template-columns:repeat(3,1fr);}
}
@media(min-width:420px){
    .app-grid{grid-template-columns:repeat(4,1fr);}
}
@media(min-width:500px){
    .app-grid{grid-template-columns:repeat(5,1fr);}
}

/* APP 卡片美化 */
.app-card{
    display:flex;
    flex-direction:column;
    align-items:center;
    background:#ffffff;
    border-radius:18px;
    padding:14px 8px;
    position:relative;
    width:100%;
    box-shadow:0 3px 12px rgba(0,0,0,0.05);
    transition:transform 0.2s ease;
}
.app-card:active{
    transform:scale(0.96);
}
.badge{
    position:absolute;
    top:-4px;
    right:-4px;
    background:linear-gradient(135deg,#ff6b6b,#ff4757);
    color:#fff;
    font-size:11px;
    padding:2px 6px;
    border-radius:6px;
    transform:rotate(15deg);
}
.app-icon{
    width:100%;
    max-width:76px;
    height:auto;
    aspect-ratio:1/1;
    border-radius:16px;
    margin-bottom:8px;
    object-fit:cover;
    box-shadow:0 2px 8px rgba(0,0,0,0.1);
}
.app-name{
    font-size:14px;
    font-weight:600;
    color:#2d3436;
    text-align:center;
    margin-bottom:8px;
    line-height:1.3;
    width:100%;
    word-break:break-word;
}
.download-btn{
    background:linear-gradient(135deg,#667eea 0%,#764ba2 100%);
    color:#fff;
    font-size:12px;
    padding:5px 12px;
    border-radius:20px;
    font-weight:600;
    box-shadow:0 2px 6px rgba(102,126,234,0.25);
}

/* 后台样式 */
.admin{background:#fff;border-radius:12px;padding:20px;width:100%;}
.add-form{margin:20px 0;padding:15px;background:#f9f9f9;border-radius:8px;width:100%;}
.add-form input{width:100%;margin:6px 0;padding:10px;border:1px solid #ddd;border-radius:6px;}
.add-form textarea{width:100%;margin:6px 0;padding:10px;border:1px solid #ddd;border-radius:6px;}
.add-form button{background:#007bff;color:white;border:none;padding:10px;width:100%;border-radius:6px;cursor:pointer;}
.manage-item{display:flex;align-items:center;gap:10px;padding:10px;border-bottom:1px solid #eee;width:100%;}
.manage-item a{color:red;margin-left:auto;text-decoration:none;}

/* 底部悬浮推广 */
.bottom-fixed-app {
    position:fixed;
    left:50%;
    bottom:0;
    z-index:10;
    transform:translateX(-50%);
    width:100%;
    max-width:520px;
    padding:12px 14px;
    box-sizing:border-box;
    background:linear-gradient(to right,rgba(118,64,229,0.85),rgba(255,65,66,0.85));
    backdrop-filter:blur(4px);
    display:flex;
    flex-direction:row;
    align-items:center;
    border-radius:12px 12px 0 0;
}
.bottom-fixed-app .logo {
    width:48px;
    height:48px;
    flex-shrink:0;
}
.bottom-fixed-app .logo img {
    width:100%;
    height:100%;
    border-radius:10px;
    object-fit:cover;
}
.bottom-fixed-app .app-content{
    flex:1;
    color:white;
    padding:0 12px;
}
.bottom-fixed-app .app-content h2 {
    font-size:15px;
    margin-bottom:2px;
    font-weight:600;
}
.bottom-fixed-app .app-content p {
    font-size:12px;
    opacity:0.95;
}
.bottom-fixed-app .download-button{
    padding:8px 14px;
    border-radius:20px;
    color:#ff4142;
    background-color:#fff;
    font-size:14px;
    font-weight:600;
    text-decoration:none;
    flex-shrink:0;
}

/* 底部版权 */
.footer-copy {
    text-align:center;
    padding:16px 10px 20px;
    font-size:12px;
    color:#999;
    line-height:1.6;
}
