@charset "utf-8";
/* 神将三国辅助工具 - 全局样式 */

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font: 14px/1.6 "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", "SimSun", Arial, sans-serif;
    color: #2f2a24;
    background: #f2ece1 url(../images/bg.jpg) center top no-repeat;
    -webkit-text-size-adjust: 100%;
}

a { color: #7a4b1e; text-decoration: none; }
a:hover { text-decoration: underline; }
ul, ol { list-style: none; }
img { border: 0; vertical-align: top; max-width: 100%; }
[hidden] { display: none !important; }

/* 顶部条 */
.topbar { background: #262320; }
.topbar-inner {
    max-width: 1000px;
    height: 44px;
    margin: 0 auto;
    padding: 0 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.brand {
    color: #eddfc1;
    font-size: 16px;
    font-weight: bold;
    letter-spacing: 1px;
    text-decoration: none;
}
.brand:hover { color: #fff; text-decoration: none; }
.slogan { color: #8f877a; font-size: 12px; }
.topbar-right { display: flex; align-items: center; gap: 14px; }
.skin-switch {
    padding: 4px 10px;
    font-size: 12px;
    color: #e0c48b;
    border: 1px solid #54483a;
    border-radius: 3px;
}
.skin-switch:hover { color: #1f1a14; background: #d3ac6d; border-color: #d3ac6d; text-decoration: none; }

/* 栏目导航 */
.mainnav { background: #383430; border-bottom: 2px solid #b8874a; }
.mainnav-inner {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 6px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}
.mainnav-inner li { display: block; }
.mainnav-inner a {
    display: block;
    padding: 0 16px;
    line-height: 46px;
    color: #ded5c6;
    font-size: 15px;
}
.mainnav-inner a:hover { color: #fff; background: #45403a; text-decoration: none; }
.mainnav-inner .is-active a {
    color: #f3cf90;
    background: #4a433b;
    box-shadow: inset 0 -3px 0 #d8ad63;
}

/* 内容区 */
.page-wrap { max-width: 1000px; margin: 0 auto; padding: 18px 12px 0; }

.panel {
    background: #fff;
    border: 1px solid #e3d8c4;
    border-radius: 6px;
    box-shadow: 0 2px 12px rgba(60, 45, 20, .07);
    padding: 20px 22px 18px;
}
.panel-head { margin-bottom: 14px; }
.panel-head h1 { font-size: 22px; color: #3a3229; line-height: 1.4; }
.panel-head p { margin-top: 6px; color: #8a7f70; font-size: 13px; }

/* 搜索栏 */
.searchbar {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    background: #fbf7ef;
    border: 1px solid #e9dcc4;
    border-radius: 6px;
    padding: 12px 14px;
}
.searchbar-label { color: #6d6253; font-size: 14px; }
.searchbar-input {
    flex: 1 1 220px;
    min-width: 160px;
    height: 38px;
    padding: 0 12px;
    font-size: 15px;
    color: #2f2a24;
    border: 1px solid #d9cbb0;
    border-radius: 4px;
    background: #fff;
    outline: none;
}
.searchbar-input:focus { border-color: #c19a5b; box-shadow: 0 0 0 3px rgba(193, 154, 91, .18); }
.searchbar-btn {
    height: 38px;
    padding: 0 22px;
    font-size: 15px;
    color: #fff;
    background: #b8874a;
    border: 0;
    border-radius: 4px;
    cursor: pointer;
}
.searchbar-btn:hover { background: #a8793d; }
.searchbar-reset { color: #93887a; font-size: 13px; }
.searchbar-stat { margin-left: auto; color: #8a7f70; font-size: 13px; white-space: nowrap; }

/* 列表表头 */
.list-head {
    display: flex;
    align-items: center;
    margin-top: 16px;
    padding: 10px 14px;
    background: #f2ebdd;
    border: 1px solid #e8dcc6;
    border-bottom: 0;
    border-radius: 6px 6px 0 0;
    color: #6b5e4c;
    font-size: 14px;
    font-weight: bold;
}
.list-head .col-q { flex: 1; }
.list-head .col-a { width: 200px; text-align: right; }
.list-head.is-single .col-a { display: none; }

/* 答案列表 */
.answer-list {
    max-height: 620px;
    overflow-y: auto;
    border: 1px solid #e8dcc6;
    border-radius: 0 0 6px 6px;
    background: #fff;
}
.answer-list li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 9px 14px;
    border-bottom: 1px dashed #efe7d8;
    line-height: 1.7;
}
.answer-list li:nth-child(even) { background: #fdfaf4; }
.answer-list li:hover { background: #fdf3df; }
.answer-list li.is-hide { display: none !important; }
.answer-list .q {
    flex: 1;
    min-width: 0;
    word-break: break-word;
    background: url(../images/list_style.png) 0 7px no-repeat;
    padding-left: 14px;
    color: #3b352d;
}
.answer-list .a {
    width: 200px;
    flex: 0 0 200px;
    text-align: right;
    color: #137a4a;
    font-weight: bold;
    word-break: break-word;
}
.answer-list.is-single li { display: block; }
.answer-list.is-single .q { display: block; padding-left: 14px; }
.answer-list.is-single .a { display: none; }
.answer-list.is-single .q { line-height: 1.9; letter-spacing: .2px; }

mark {
    background: #ffe9a8;
    color: #8a4b00;
    padding: 0 1px;
    border-radius: 2px;
}

.list-empty {
    padding: 46px 12px;
    text-align: center;
    color: #9c9182;
    font-size: 14px;
    border: 1px solid #e8dcc6;
    border-top: 0;
    background: #fff;
}
.list-tip { margin-top: 12px; color: #9c9182; font-size: 12px; }

/* 图片页 */
.image-box { text-align: center; padding: 4px 0 10px; }
.image-box img { border: 1px solid #e6dcc8; border-radius: 4px; }

/* 首页 */
.hero { text-align: center; padding: 30px 12px 22px; }
.hero h1 { font-size: 28px; color: #3a3229; letter-spacing: 2px; }
.hero p { margin-top: 10px; color: #8a7f70; font-size: 14px; }

.tool-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 12px;
    margin-bottom: 18px;
}
.tool-card {
    display: block;
    padding: 18px 14px;
    background: #fff;
    border: 1px solid #e5dac7;
    border-radius: 6px;
    text-align: center;
    transition: all .18s ease;
}
.tool-card:hover {
    border-color: #c19a5b;
    box-shadow: 0 6px 16px rgba(120, 90, 40, .16);
    transform: translateY(-2px);
    text-decoration: none;
}
.tool-card-name { display: block; font-size: 17px; color: #7a4b1e; font-weight: bold; }
.tool-card-desc { display: block; margin-top: 6px; font-size: 12px; color: #9c9182; }

.panel-tips h1, .panel-tips h2 { font-size: 18px; color: #3a3229; margin-bottom: 10px; }
.panel-tips p { color: #6d6253; margin-bottom: 10px; }
.panel-tips ul li {
    position: relative;
    padding-left: 16px;
    margin-bottom: 6px;
    color: #6d6253;
    font-size: 13px;
}
.panel-tips ul li:before {
    content: "";
    position: absolute;
    left: 2px;
    top: 9px;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: #c19a5b;
}
.link-btn {
    display: inline-block;
    margin-top: 6px;
    padding: 8px 20px;
    background: #b8874a;
    color: #fff;
    border-radius: 4px;
}
.link-btn:hover { background: #a8793d; text-decoration: none; }

/* 页脚 */
.footer {
    margin-top: 30px;
    padding: 18px 12px;
    background: #262320;
    color: #9c9384;
    text-align: center;
    font-size: 12px;
    line-height: 1.9;
}
.footer-age { color: #d05b4a; }

/* 响应式 */
@media (max-width: 900px) {
    .tool-grid { grid-template-columns: repeat(3, 1fr); }
    .mainnav-inner a { padding: 0 12px; font-size: 14px; }
}
@media (max-width: 640px) {
    .slogan { display: none; }
    .topbar-inner { justify-content: center; }
    .page-wrap { padding: 12px 8px 0; }
    .panel { padding: 16px 14px 14px; }
    .hero h1 { font-size: 22px; letter-spacing: 1px; }
    .tool-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .searchbar { padding: 10px; gap: 8px; }
    .searchbar-label { display: none; }
    .searchbar-input { flex: 1 1 100%; }
    .searchbar-btn { flex: 0 0 auto; }
    .searchbar-stat { margin-left: 0; width: 100%; }
    .list-head .col-a { width: 110px; }
    .answer-list { max-height: none; }
    .answer-list li { flex-direction: column; gap: 2px; }
    .answer-list .a { width: auto; flex: none; text-align: left; }
}
