* {
    margin:0; padding:0; box-sizing:border-box;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}
body {
    background: #f6f7f9;
    padding-bottom: 60px;
    padding-top: 60px;
}

/* 顶部导航 */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 60px;
    background: #16a34a; /* 绿色主色 */
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
    color: #fff;
    z-index: 999;
}
.menu-btn {
    font-size: 24px;
    cursor: pointer;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.logo {
    font-size: 18px;
    font-weight: bold;
    /* 超出隐藏，保证小屏不挤飞 */
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.nav-btns {
    display: flex;
    gap: 6px;
    align-items: center;
    /* 小屏自动收缩 */
    flex-shrink: 1;
}
.nav-btn {
    background: rgba(255,255,255,0.15);
    border: none;
    color: #fff;
    padding: 6px 8px;
    border-radius: 16px;
    font-size: 12px;
    cursor: pointer;
    white-space: nowrap;
}
.login-btn {
    background: rgba(255,255,255,0.2);
    border: none;
    color: #fff;
    padding: 8px 12px;
    border-radius: 20px;
    font-size: 14px;
    cursor: pointer;
    white-space: nowrap;
}

/* 小屏适配：按钮更紧凑 */
@media (max-width: 480px) {
    .nav-btn {
        padding: 5px 6px;
        font-size: 11px;
    }
    .login-btn {
        padding: 6px 10px;
        font-size: 12px;
    }
}

/* 左侧抽屉 */
.drawer {
    position: fixed;
    top: 0;
    left: -280px;
    width: 280px;
    height: 100vh;
    background: #fff;
    z-index: 1000;
    transition: 0.3s;
    box-shadow: 2px 0 10px rgba(0,0,0,0.1);
}
.drawer.open {
    left: 0;
}
.drawer-close {
    padding: 20px;
    font-size: 22px;
    cursor: pointer;
    text-align: right;
    color: #333;
}
.drawer-menu {
    padding: 0 20px;
}
.drawer-item {
    padding: 16px;
    border-radius: 12px;
    background: #f5f7fa;
    margin-bottom: 12px;
    cursor: pointer;
    font-size: 16px;
    color: #333;
    text-align: center;
}
.drawer-item:hover {
    background: #e4eaff;
    color: #4a6cf7;
}
.drawer-mask {
    position: fixed;
    top:0; left:0; width:100%; height:100%;
    background: rgba(0,0,0,0.4);
    z-index: 998;
    display: none;
}

/* 悬浮登录 */
.login-float {
    position: fixed; top:0; left:0; width:100%; height:100%;
    background: rgba(0,0,0,0.6); z-index:9999;
    display: none; align-items: center; justify-content: center;
}
.login-box {
    background:#fff; padding:30px; border-radius:16px; width:90%; max-width:380px;
}
.login-box input {
    width:100%; padding:12px; margin:10px 0; border:1px solid #ddd; border-radius:8px;
}
.login-box button {
    width:100%; padding:12px; background:#4a6cf7; color:#fff; border:none; border-radius:8px; font-weight:bold;
}

/* 16:9 海报容器 - 修复版 */
.poster-container {
  width: 100%;
  /* 关键：用 padding-top 实现真正 16:9，不要写死高度 */
  aspect-ratio: 16/9;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #eee;
  overflow: hidden; /* 防止图片溢出 */
  margin-bottom: 10px; /* 海报之间留间距 */
}

.poster-container img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* 不变形裁剪 */
}
.poster-list {
  display: flex;
  flex-direction: column; /* 竖向排列 */
  gap: 10px; /* 海报之间间距 */
}



/* 登录 */
.login-box {
    background: #ffffff; 
    padding: 35px 30px; 
    border-radius: 20px; /* 更大*/
    width: 90%; 
    max-width: 420px; /* 稍微*/
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15); /* 增强立体感 */
    transform: translateY(-20px);
    animation: slideUp 0.4s forwards 0.1s; /* 卡片*/
}

/* 输入 */
.login-box input {
    width: 100%; 
    padding: 15px; 
    margin: 12px 0 20px 0; /* 增加上 */
    border: 1px solid #e0e0e0; 
    border-radius: 12px; /* 圆润 */
    font-size: 16px; /* 字体 */
    transition: all 0.3s ease; /* 过渡 */
    box-sizing: border-box; /* 确 */
}

/* 输入框 */
.login-box input:focus {
    outline: none;
    border-color: #4a6cf7;
    box-shadow: 0 0 0 3px rgba(74, 108, 247, 0.2); /* 外发光效果 */
}

/* 按 */
.login-box button {
    width: 100%; 
    padding: 16px; 
    /* 马年喜 */
    background: linear-gradient(135deg, #ff6b6b, #feca57); 
    color: #fff; 
    border: none; 
    border-radius: 12px; 
    font-weight: bold;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
}

/* 按钮悬 */
.login-box button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(254, 202, 87, 0.4);
}

/* 按钮点*/
.login-box button:active {
    transform: translateY(0);
}

/* 标题样式 */
.login-box h3 {
    text-align: center;
    color: #333;
    margin-bottom: 25px;
    font-size: 24px;
}

/* 动画 */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp {
    from { transform: translateY(-20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}
/* 马年关闭 */
p[onclick="closeLogin()"] {
    position: absolute;
    top: -12px;
    right: -12px;
    width: 36px;
    height: 36px;
    /* 马年 */
    background: linear-gradient(135deg, #ff4d4f, #ff7854); 
    border-radius: 50%;
    box-shadow: 0 4px 12px rgba(255, 77, 79, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff; /* 白色 */
    cursor: pointer;
    transition: all 0.3s ease;
    margin: 0;
    font-size: 14px;
    font-weight: bold;
    border: 2px solid #fff; /* 增加 */
}

/* 马年 */
p[onclick="closeLogin()"]:hover {
    transform: rotate(15deg) scale(1.1); /* 旋转 */
    box-shadow: 0 6px 16px rgba(255, 77, 79, 0.5);
}
/* 素材卡片 16:9 */
.material-item {
  position: relative;
  aspect-ratio: 16/9;
  border-radius: 10px;
  overflow: hidden;
  background: #222;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}
.material-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.material-item .title {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  padding: 6px 10px;
  background: rgba(0,0,0,0.6);
  color: #fff;
  font-size: 13px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  box-sizing: border-box;
  z-index: 2;
}

/* 版权 */
.material-item .copyright {
  position: absolute;
  left: 10px;
  bottom: 10px;
  background: linear-gradient(135deg, #ff4d4f, #ff7854);
  color: #ffffff;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: bold;
  box-shadow: 0 2px 4px rgba(0,0,0,0.2);
  border: 1px solid rgba(255,255,255,0.2);
  z-index: 99;
  white-space: nowrap;
}

/* 下载次数 */
.material-item .down-count {
  position: absolute;
  left: 10px;
  bottom: 38px; /* 放在版权上面一点，不重叠 */
  background: linear-gradient(135deg, #ff4d4f, #ff7854);
  color: #fff;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: bold;
  box-shadow: 0 1px 3px rgba(0,0,0,0.15);
  border: 1px solid rgba(255,255,255,0.2);
  z-index: 99;
  white-space: nowrap;
}

/* 下载按钮 */
.material-item .down {
  position: absolute;
  bottom: 8px;
  right: 8px;
  background: #4a6cf7;
  color: #fff;
  padding: 5px 10px;
  border-radius: 20px;
  font-size: 12px;
  cursor: pointer;
  z-index: 99;
  white-space: nowrap;
}
