:root {
    --site-blue: #4d94e8;
    --site-blue-dark: #286ebf;
    --site-blue-pale: #eaf4ff;
    --site-red: #e60012;
    --site-yellow: #fff83d;
    --site-line: #d2d2d2;
    --site-text: #4b4b4b;
}

html { background: #eee; }

body {
    width: 100%; max-width: 760px; margin: 0 auto; padding-bottom: 54px;
    color: var(--site-text); background: #fff; border: 0; box-shadow: none;
    font-family: Arial, "Microsoft YaHei", "PingFang SC", sans-serif;
}

a { color: #175fae; text-decoration: none; }

/* 传统彩票论坛的文字标识：白底、红蓝字、小角标。 */
.header, .header.index-header {
    position: relative !important; top: auto; left: auto; width: 100%; max-width: none;
    height: auto; transform: none; background: #fff; border: 0; box-shadow: none;
}

.header .logo-box {
    display: flex; align-items: center; justify-content: space-between;
    min-height: 58px; height: auto; padding: 4px 8px 3px;
}

.site-brand { display: block; min-width: 0; color: inherit; }
.site-brand-copy, .site-brand-line { display: block; }
.site-brand-line { white-space: nowrap; }

.site-brand-title {
    display: inline-block; color: var(--site-red); font-family: Arial, "Microsoft YaHei", sans-serif;
    font-size: 31px; font-weight: 900; line-height: 1; letter-spacing: -2px;
}

.site-brand-edition {
    display: inline-block; margin-left: 5px; padding: 2px 4px; color: #8d5c00;
    background: #ffea45; border: 1px solid #dcbd1c; font-size: 11px;
    font-style: normal; font-weight: 900; vertical-align: top;
}

.site-brand-subtitle {
    display: block; margin-top: 3px; color: #777; font-size: 11px;
    font-weight: 700; letter-spacing: 2px;
}

.primary-domain {
    flex: 0 0 auto; color: #111; background: transparent; border: 0;
    font-size: 21px; font-weight: 900; letter-spacing: -1px;
}

.primary-domain::before {
    content: "官网 "; color: var(--site-blue-dark); font-size: 11px; letter-spacing: 0;
}

.top-spacer { display: none; }

/* 三列页签与参考站相同，第二排保留原站常用入口。 */
.subnav {
    margin: 0 !important; padding: 0; overflow: hidden; background: #fff;
    border: 1px solid #7aa9dc; border-radius: 0;
}

.subnav .hhh {
    display: grid !important; grid-template-columns: repeat(3, minmax(0, 1fr)); margin: 0;
}

.subnav .hhh::before, .subnav .hhh::after {
    display: none !important; content: none !important;
}

.subnav a {
    display: grid; float: none; width: auto !important; min-height: 41px; margin: 0;
    padding: 0 4px; place-items: center; color: #242424; background: #fff;
    border-right: 1px solid #7aa9dc; border-bottom: 1px solid #7aa9dc;
    border-radius: 0; font-size: 14px; font-weight: 800; line-height: 1.2; text-shadow: none;
}

.subnav a:nth-child(3n) { border-right: 0; }
.subnav a:nth-child(-n + 3), .subnav a:hover { color: #fff; background: var(--site-blue); }
.subnav a:nth-child(n + 4) { border-bottom: 0; }
.subnav a img { display: none !important; }

/* 海报紧贴页签，取消卡片与说明区的现代组件感。 */
.hero-poster { margin: 6px 0 0; overflow: hidden; background: #fff; border: 0; border-radius: 0; }
.hero-poster img {
    display: block; width: 100% !important; height: auto !important; max-height: 340px;
    aspect-ratio: 3 / 2; object-fit: cover;
}

.hero-caption {
    display: flex; align-items: center; justify-content: space-between; gap: 10px;
    padding: 7px 10px; color: #333; background: var(--site-yellow);
    border-top: 1px solid #e5d900; border-bottom: 1px solid #e5d900; font-size: 13px;
}

.hero-caption strong, .hero-caption span { color: var(--site-red); font-weight: 900; }

.site-notice {
    padding: 7px 8px; color: #333; background: #fff; border-bottom: 1px solid #ddd;
    font-size: 13px; text-align: center;
}
.site-notice b, .site-notice strong { color: var(--site-red); }

.nav {
    margin: 6px 0 0; overflow: hidden; background: #fff;
    border: 1px solid #89add3; border-radius: 0;
}

.news-box { margin: 6px 0; }
.riqi {
    margin: 0; padding: 6px 8px; color: #333; background: #fff9bd;
    border: 1px solid #e9df52; font-size: 14px; line-height: 1.45; text-align: center;
}

/* 目录与备用网址用老式表格，不做卡片。 */
.section-jump {
    margin: 7px 0; padding: 0; background: #fff; border: 1px solid #90b3dc;
}

.section-jump-title, .domain-directory-title, .featured-materials-title {
    margin: 0; padding: 7px 8px; color: #fff; background: var(--site-blue);
    border: 0; border-bottom: 1px solid var(--site-blue-dark); font-size: 15px;
    font-weight: 900; line-height: 1.2; text-align: center;
}

.section-jump-links { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; }
.section-jump a {
    padding: 8px 4px; color: #155ca8; background: #fff;
    border-right: 1px solid #c9d9eb; border-bottom: 1px solid #c9d9eb;
    border-radius: 0; font-size: 13px; font-weight: 800; text-align: center;
}
.section-jump a:nth-child(4n) { border-right: 0; }
.section-jump a:nth-child(n + 5) { border-bottom: 0; }

.domain-directory { margin: 7px 0; padding: 0; background: #fff; border: 1px solid #90b3dc; }
.domain-directory-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; }
.domain-directory a {
    display: block; padding: 9px 4px; color: var(--site-red); background: #fffbd0;
    border-right: 1px solid #dccf5d; border-bottom: 0; border-radius: 0;
    font-size: 14px; font-weight: 900; text-align: center;
}
.domain-directory a:last-child { border-right: 0; }

.featured-materials { margin: 8px 0 12px; padding: 0; border: 0; }
.featured-materials-title {
    margin-bottom: 7px; color: #222; background: var(--site-yellow);
    border-top: 1px solid #e2d600; border-bottom: 1px solid #e2d600; font-size: 18px;
}

/* 资料块：蓝色亮面标题、白底正文、灰色分隔线。 */
.box, .news-box, .box.pad, .box.padt {
    margin: 8px 0; padding: 0; overflow: hidden; background: #fff !important;
    background-image: none !important; border: 0; border-radius: 0; box-shadow: none;
}
.box .box { margin: 0; border: 0; }

.list-title {
    position: relative; min-height: 36px; height: auto; padding: 7px 10px 6px;
    color: #111 !important;
    background: linear-gradient(to bottom, #58a0ee 0%, #acd2fa 48%, #e8f4ff 100%) !important;
    border: 1px solid #438bd9; border-bottom-color: #a5c7eb;
    border-radius: 10px 10px 0 0; box-shadow: inset 0 1px 0 rgba(255,255,255,.8);
    font-size: 19px !important; font-weight: 900; line-height: 1.25;
    letter-spacing: 0; text-align: center; text-shadow: 0 1px 0 #fff !important;
}

.list-title::after {
    content: "  gangao12.vip"; color: #111; font-size: .78em; font-weight: 900;
}

.duilianpt, .duilianpt1, .qxtable, .listtable, .box table {
    width: 100%; margin: 0 !important; color: var(--site-text);
    background: #fff !important; border-collapse: collapse !important;
}

.duilianpt td, .duilianpt1 td, .duilianpt1 th, .qxtable td, .box table td, .box table th {
    padding: 8px 6px !important; color: var(--site-text); background: #fff !important;
    border: 0 !important; border-bottom: 1px solid var(--site-line) !important;
    font-size: 16px; line-height: 1.55; text-align: center;
}

.box table tr:nth-child(even) td, .duilianpt tr:nth-child(even) td, .duilianpt1 tr:nth-child(even) td {
    background: #fff !important;
}
.box table tr:hover td { background: #fffdf0 !important; }

.box table .zl,
.box table [style*="color: #a233c6"], .box table [style*="color:#a233c6"],
.box table [style*="color: blue"], .box table [style*="color:#0000FF"],
.box table font[color="#0000FF"] {
    color: var(--site-red) !important; font-weight: 900 !important;
}

.box table [style*="border-bottom: 1px dashed"] {
    margin: 0 !important; padding: 6px 2px !important; border-bottom: 1px solid #d7d7d7 !important;
}
.box table [style*="border-bottom: 1px dashed"]:last-child { border-bottom: 0 !important; }

.zhong, .zhongsan {
    display: inline; padding: 0 2px; color: var(--site-red) !important;
    background: var(--site-yellow) !important; border-radius: 0; font-weight: 900;
}

.brand-strip {
    margin: -8px 0 9px; padding: 7px 8px !important; color: #333 !important;
    background: var(--site-yellow) !important; background-image: none !important;
    border: 0 !important; border-bottom: 1px solid #e1d800 !important;
    border-left: 0 !important; border-radius: 0 !important;
    font-size: 14px !important; font-weight: 900; text-align: center;
}
.brand-strip span { color: var(--site-red) !important; }

.gallery { padding: 0; }
.gallery-item { margin-bottom: 8px; overflow: hidden; border: 1px solid #aaa; border-radius: 0; }

/* 参考站的固定底部入口，使用白底蓝字。 */
.cgi-foot-links {
    left: 50%; max-width: 760px; height: 50px; transform: translateX(-50%);
    background: rgba(255,255,255,.96); background-image: none; border: 0;
    border-top: 1px solid #aebed0; box-shadow: 0 -1px 5px rgba(0,0,0,.12);
}
.cgi-foot-links ul { margin: 0; }
.cgi-foot-links ul li { height: 49px; border-right: 1px solid #d8e0e8; }
.cgi-foot-links ul li:last-child { border-right: 0; }
.cgi-foot-links ul li a, .cgi-foot-links ul li a.hover {
    display: block; height: 49px; color: #4d647c; font-size: 12px;
    font-weight: 800; line-height: 49px;
}
.cgi-foot-links ul li a span { display: none; }
.cgi-foot-links ul li.cfl-more { width: 20%; height: 49px; }
.cgi-foot-links ul li.cfl-more a {
    position: static; width: auto; height: 49px; margin: 0; color: #fff;
    background: var(--site-blue); border: 0; border-radius: 0; line-height: 49px; text-indent: 0;
}

.floating-buttons { right: max(8px, calc((100vw - 760px) / 2 + 8px)); gap: 5px; }
.fab {
    width: 34px; height: 34px; color: #15966c; background: #fff;
    border: 1px solid #e5e5e5; border-radius: 50%; box-shadow: 0 2px 7px rgba(0,0,0,.12);
}

@media (max-width: 540px) {
    .header .logo-box { min-height: 52px; padding: 4px 7px 3px; }
    .site-brand-title { font-size: 24px; letter-spacing: -1px; }
    .site-brand-subtitle { font-size: 9px; letter-spacing: 1px; }
    .primary-domain { font-size: 15px; }
    .primary-domain::before { display: none; }
    .subnav a { min-height: 38px; font-size: 12px; }
    .hero-poster img { max-height: none; }
    .hero-caption { display: block; padding: 6px; text-align: center; }
    .hero-caption span { display: block; margin-top: 2px; }
    .section-jump-links { grid-template-columns: repeat(2, 1fr); }
    .section-jump a:nth-child(2n) { border-right: 0; }
    .section-jump a:nth-child(n + 5) { border-bottom: 1px solid #c9d9eb; }
    .section-jump a:nth-last-child(-n + 2) { border-bottom: 0; }
    .domain-directory-list { grid-template-columns: 1fr; }
    .domain-directory a { border-right: 0; border-bottom: 1px solid #dccf5d; }
    .domain-directory a:last-child { border-bottom: 0; }
    .list-title { min-height: 34px; font-size: 16px !important; }
    .duilianpt td, .duilianpt1 td, .box table td, .box table th {
        padding: 7px 4px !important; font-size: 14px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        scroll-behavior: auto !important; animation-duration: .01ms !important;
        animation-iteration-count: 1 !important; transition-duration: .01ms !important;
    }
}
