/* ====== BB36 ULTIMATE CSS (Final Header Fixed) ====== */
:root {
  --bg: #0A090C;
  --bg-darker: #050406;
  --bg-card: rgba(255, 255, 255, 0.04);
  --primary: #FF2D55;
  --primary-glow: rgba(255, 45, 85, 0.4);
  --text-main: #FFFFFF;
  --text-muted: #A0A0A0;
  --border-color: rgba(255, 255, 255, 0.1);
  --glass-bg: rgba(18, 18, 22, 0.98);
  
  --color-red: #f43f5e;
  --color-blue: #3b82f6;
  --color-gold: #fbbf24;
  --color-green: #10b981;
}

html { scroll-behavior: smooth; }
* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Outfit', 'Noto Sans Khmer', sans-serif; }
body { background-color: var(--bg); color: var(--text-main); line-height: 1.6; overflow-x: hidden; }

/* 背景粒子 */
#particles-bg { position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; }
.particle { 
    position: absolute; background: var(--primary); border-radius: 50%; opacity: 0; 
    width: 3px; height: 3px; box-shadow: 0 0 10px var(--primary);
    animation: float var(--d) linear infinite; 
}
@keyframes float { 0% { transform: translateY(100vh); opacity: 0; } 20% { opacity: 0.3; } 80% { opacity: 0.3; } 100% { transform: translateY(-10vh); opacity: 0; } }

/* HEADER */
header { height: 75px; background: var(--glass-bg); backdrop-filter: blur(25px); border-bottom: 1px solid var(--border-color); position: sticky; top: 0; z-index: 1000; }
.header-inner { max-width: 1400px; margin: 0 auto; height: 100%; display: flex; align-items: center; justify-content: space-between; padding: 0 30px; }

.logo { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.logo-img { 
    width: 44px; height: 44px; background: #FFFFFF; /* 精确白底 */
    padding: 7px; border-radius: 12px; border: 1.5px solid var(--primary); 
    box-shadow: 0 0 15px var(--primary-glow); object-fit: contain;
}
.logo-name { font-size: 24px; font-weight: 800; color: var(--primary); }

.search-wrap { flex: 1; max-width: 500px; position: relative; margin: 0 30px; }
.search-wrap input { width: 100%; height: 42px; background: rgba(255,255,255,0.06); border: 1px solid var(--border-color); border-radius: 21px; padding: 0 45px 0 20px; color: #fff; outline: none; transition: 0.3s; }
.search-btn { position: absolute; right: 5px; top: 50%; transform: translateY(-50%); width: 32px; height: 32px; border-radius: 50%; background: var(--primary); border: none; display: flex; align-items: center; justify-content: center; color: #fff; }

.header-time { text-align: right; min-width: 155px; }
.clock { display: block; font-size: 19px; font-weight: 800; color: #fff; }
#dateStr { font-size: 11px; color: var(--text-muted); opacity: 0.8; }

/* HERO */
.hero { max-width: 1400px; margin: 50px auto 30px; padding: 0 30px; text-align: center; animation: fadeIn 1s; }
.hero-title { font-size: 44px; font-weight: 800; margin-bottom: 15px; }
.hero-tags { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.hero-tag { background: rgba(255,255,255,0.05); border: 1px solid var(--border-color); padding: 8px 20px; border-radius: 25px; color: #fff !important; text-decoration: none; font-size: 12px; font-weight: 600; transition: 0.3s; }
.hero-tag:hover { background: var(--primary); transform: translateY(-3px); }

/* MAIN GRID */
.main-container { max-width: 1400px; margin: 0 auto 80px; display: grid; grid-template-columns: 1fr 340px; gap: 40px; padding: 0 30px; }

.section-block { margin-bottom: 50px; scroll-margin-top: 100px; animation: slideUp 0.8s ease-out both; }
@keyframes slideUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }

.cards-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 18px; }
.site-card {
  background: var(--bg-card); border: 1px solid var(--border-color);
  border-radius: 16px; padding: 22px; text-decoration: none !important;
  display: flex; flex-direction: column; align-items: center; text-align: center;
  transition: 0.3s; color: #fff !important;
}
.site-card:hover { transform: translateY(-8px); border-color: var(--primary); background: rgba(255,255,255,0.08); }

.site-favicon { width: 56px; height: 56px; border-radius: 14px; background: rgba(255,255,255,0.05); display: flex; align-items: center; justify-content: center; margin-bottom: 14px; overflow: hidden; font-size: 24px; }
.uniform-site-img { width: 34px; height: 34px; object-fit: contain; }

.site-name { font-weight: 800; font-size: 16px; margin-bottom: 5px; }
.site-desc { font-size: 11px; color: var(--text-muted); opacity: 0.85; display: block; line-height: 1.4; }

/* SIDEBAR (WHITE LOGO) */
.sidebar { display: flex; flex-direction: column; gap: 25px; }
.casino-col { background: var(--bg-card); border: 1px solid var(--border-color); border-radius: 20px; padding: 25px; }
.casino-item {
  display: flex; align-items: center; gap: 15px; padding: 12px;
  background: rgba(255,255,255,0.02); border-radius: 14px; border: 1px solid transparent; 
  text-decoration: none !important; color: #fff !important; transition: 0.3s; margin-bottom: 10px;
}
.casino-logo-wrap { width: 58px; height: 58px; background: #FFFFFF; border-radius: 14px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; border: 1px solid rgba(255,255,255,0.2); }
.brand-img { width: 100%; height: 100%; object-fit: contain; padding: 6px; }
.casino-desc { font-size: 11px; color: var(--text-muted) !important; opacity: 0.85; display: block; }
.casino-tag { font-size: 9px; font-weight: 900; padding: 2px 7px; border-radius: 5px; }
.casino-tag.hot { background: var(--primary); }
.casino-tag.vip { background: var(--color-gold); color: #000; }
.casino-tag.new { background: var(--color-green); }

/* 返回顶部 */
#backTop {
    position: fixed; bottom: 30px; right: 30px; width: 50px; height: 50px;
    background: var(--primary); color: #fff; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer; opacity: 0; transform: translateY(20px); transition: 0.4s;
    box-shadow: 0 10px 20px var(--primary-glow); z-index: 1000;
}
#backTop.active { opacity: 1; transform: translateY(0); }

/* RESPONSIVE */
@media (max-width: 1024px) {
    .main-container { display: flex; flex-direction: column; gap: 30px; }
    .sidebar { display: contents; }
}

@media (max-width: 600px) {
    header { height: 65px; }
    .header-inner { padding: 0 15px; }
    .logo-img { width: 38px; height: 38px; padding: 5px; }
    .logo-name { font-size: 19px; }
    .search-wrap { display: none; }
    
    /* 手机端时间双排效果 */
    .header-time { 
        min-width: unset; 
        display: flex; 
        flex-direction: column; 
        align-items: flex-end; 
        justify-content: center;
        line-height: 1.2;
    }
    .clock { font-size: 15px; }
    #dateStr { font-size: 9px; opacity: 0.7; font-weight: 400; }
    
    .hero { margin: 30px auto 20px; }
    .hero-title { font-size: 28px; }
    .hero-desc { display: none; } /* 手机端隐藏描述文字 */
    .hero-tags { display: none; } /* 手机端隐藏分类按钮 */
    
    .main-container { padding: 0 15px; }
    #casino-container { order: -1; margin-bottom: 20px; }
    #nav-sections-container { order: 1; }
    #notices-container, #quick-nav-container { order: 10; }
    
    .cards-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
}
