/* 模板建站栏目 */
.tpl-page { padding-bottom: 46px; }

.tpl-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin: 22px 0 18px;
    padding: 26px 30px;
    border-radius: 12px;
    color: #fff;
    background: linear-gradient(120deg, #1f6feb 0%, #1447a8 55%, #0d3277 100%);
    box-shadow: 0 12px 30px rgba(20, 71, 168, .18);
}

.tpl-hero-text h1 { margin: 0 0 8px; font-size: 26px; font-weight: 600; letter-spacing: .5px; }
.tpl-hero-text p { margin: 0; max-width: 720px; line-height: 1.8; color: rgba(255, 255, 255, .82); font-size: 14px; }

.tpl-hero-stat { flex: 0 0 auto; text-align: center; padding: 6px 22px; border-left: 1px solid rgba(255, 255, 255, .22); }
.tpl-hero-stat b { display: block; font-size: 34px; font-weight: 700; line-height: 1.1; }
.tpl-hero-stat span { font-size: 13px; color: rgba(255, 255, 255, .78); }

.tpl-filter {
    margin-bottom: 22px;
    padding: 18px 20px 16px;
    background: #fff;
    border: 1px solid #e7ebf2;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(16, 42, 76, .04);
}

.tpl-searchbar { display: flex; gap: 10px; max-width: 480px; margin-bottom: 16px; }
.tpl-searchbar input[type="text"] { flex: 1; height: 40px; padding: 0 14px; border: 1px solid #dfe5ee; border-radius: 6px; outline: none; font-size: 14px; color: #33415c; transition: border-color .2s, box-shadow .2s; }
.tpl-searchbar input[type="text"]:focus { border-color: #1f6feb; box-shadow: 0 0 0 3px rgba(31, 111, 235, .1); }
.tpl-searchbar button { height: 40px; padding: 0 20px; border: 0; border-radius: 6px; background: #1f6feb; color: #fff; font-size: 14px; cursor: pointer; transition: background .2s; }
.tpl-searchbar button:hover { background: #155fd1; }
.tpl-searchbar button i { margin-right: 4px; }

.tpl-cats { display: flex; flex-wrap: wrap; gap: 10px; }
.tpl-cats a { display: inline-flex; align-items: center; gap: 8px; padding: 7px 15px; border: 1px solid #e2e8f1; border-radius: 20px; background: #f7f9fc; color: #3b4a63; font-size: 14px; text-decoration: none; transition: all .2s; }
.tpl-cats a:hover { border-color: #1f6feb; color: #1f6feb; background: #f2f7ff; }
.tpl-cats a b { font-weight: 600; }
.tpl-cats a span { font-size: 12px; color: #8a97ab; }
.tpl-cats a.on { border-color: #1f6feb; background: #1f6feb; color: #fff; }
.tpl-cats a.on span { color: rgba(255, 255, 255, .82); }

.tpl-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }

.tpl-card { display: flex; flex-direction: column; overflow: hidden; background: #fff; border: 1px solid #e7ebf2; border-radius: 10px; transition: transform .25s, box-shadow .25s, border-color .25s; }
.tpl-card:hover { transform: translateY(-4px); border-color: #c7d8f5; box-shadow: 0 14px 30px rgba(20, 50, 100, .12); }

.tpl-shot { position: relative; display: block; height: 230px; overflow: hidden; background: #eef2f8; }
.tpl-shot img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top center; transition: transform .5s ease; }
.tpl-card:hover .tpl-shot img { transform: scale(1.03); }
.tpl-shot-mask { position: absolute; top: 0; right: 0; bottom: 0; left: 0; display: flex; align-items: center; justify-content: center; background: rgba(12, 35, 70, .45); color: #fff; font-size: 14px; opacity: 0; transition: opacity .25s; }
.tpl-shot-mask i { margin-right: 6px; }
.tpl-shot:hover .tpl-shot-mask { opacity: 1; }

.tpl-info { display: flex; flex: 1; flex-direction: column; padding: 15px 16px 16px; }
.tpl-info h3 { margin: 0 0 8px; font-size: 16px; line-height: 1.45; font-weight: 600; }
.tpl-info h3 a { color: #22304a; text-decoration: none; }
.tpl-info h3 a:hover { color: #1f6feb; }
.tpl-info p { display: -webkit-box; overflow: hidden; margin: 0 0 12px; min-height: 40px; color: #7a879b; font-size: 13px; line-height: 1.6; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }

.tpl-meta { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 14px; color: #93a0b4; font-size: 12px; }
.tpl-meta i { margin-right: 4px; }

.tpl-ops { display: flex; gap: 10px; margin-top: auto; }
.tpl-btn { display: inline-flex; align-items: center; justify-content: center; flex: 1; height: 36px; padding: 0 12px; border: 1px solid #dfe5ee; border-radius: 6px; background: #fff; color: #43516b; font-size: 13px; text-decoration: none; transition: all .2s; }
.tpl-btn:hover, .tpl-btn:focus { border-color: #1f6feb; color: #1f6feb; text-decoration: none; }
.tpl-btn i { margin-right: 5px; }
.tpl-btn-main { border-color: #1f6feb; background: #1f6feb; color: #fff; }
.tpl-btn-main:hover, .tpl-btn-main:focus { border-color: #155fd1; background: #155fd1; color: #fff; }
.tpl-btn-buy { border-color: #ff6b2c; background: #ff6b2c; color: #fff; }
.tpl-btn-buy:hover, .tpl-btn-buy:focus { border-color: #e85a1b; background: #e85a1b; color: #fff; }
.tpl-btn-lg { flex: 0 0 auto; min-width: 148px; height: 44px; font-size: 15px; }

.tpl-empty { padding: 70px 0; color: #93a0b4; text-align: center; font-size: 15px; }
.tpl-empty i { margin-right: 6px; }
.tpl-pager { margin: 28px 0 0; text-align: center; }

.tpl-crumb { margin: 20px 0 0; padding: 10px 14px; background: #fff; border: 1px solid #e7ebf2; border-radius: 8px; }

.tpl-showcase { display: flex; gap: 28px; align-items: flex-start; margin: 18px 0 24px; padding: 24px; background: #fff; border: 1px solid #e7ebf2; border-radius: 12px; box-shadow: 0 4px 16px rgba(16, 42, 76, .05); }
.tpl-showcase-shot { flex: 0 0 56%; max-height: 560px; overflow: hidden; border: 1px solid #eef1f6; border-radius: 8px; background: #f4f6fa; }
.tpl-showcase-shot img { display: block; width: 100%; transition: transform 6s ease; }
.tpl-showcase-shot:hover img { transform: translateY(calc(-100% + 560px)); }

.tpl-showcase-side { flex: 1; min-width: 0; padding-top: 6px; }
.tpl-showcase-side h1 { margin: 0 0 14px; color: #1d2b45; font-size: 26px; font-weight: 600; line-height: 1.4; }
.tpl-showcase-meta { display: flex; flex-wrap: wrap; gap: 16px; margin-bottom: 18px; color: #8a97ab; font-size: 13px; }
.tpl-showcase-meta i { margin-right: 5px; }
.tpl-showcase-intro { margin: 0 0 22px; color: #5f6f88; font-size: 14px; line-height: 1.9; }
.tpl-showcase-ops { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 18px; }
.tpl-showcase-tip { color: #93a0b4; font-size: 13px; line-height: 1.8; }
.tpl-showcase-tip i { margin-right: 5px; color: #1f6feb; }

.tpl-detail { margin-bottom: 24px; padding: 24px 26px; background: #fff; border: 1px solid #e7ebf2; border-radius: 12px; }
.tpl-detail h2, .tpl-related h2 { margin: 0 0 16px; padding-left: 12px; border-left: 4px solid #1f6feb; color: #1d2b45; font-size: 18px; font-weight: 600; }
.tpl-detail h2 i, .tpl-related h2 i { margin-right: 6px; color: #1f6feb; }
.tpl-detail-content { color: #4d5c74; font-size: 14px; line-height: 2; }
.tpl-detail-content img { display: block; margin: 0 auto; max-width: 100%; height: auto; cursor: zoom-in; }
.tpl-detail-content p { margin: 0 0 14px; }

#imgZoomOverlay { display: none; position: fixed; top: 0; left: 0; right: 0; bottom: 0; z-index: 999999; background: rgba(0, 0, 0, .85); cursor: grab; text-align: center; }
#imgZoomOverlay.on { display: block; }
#imgZoomOverlay.grab { cursor: grabbing; }
#imgZoomOverlay img { position: absolute; top: 50%; left: 50%; max-width: none; box-shadow: 0 0 30px rgba(0, 0, 0, .6); will-change: transform; -webkit-user-drag: none; user-select: none; }
#imgZoomOverlay .img-zoom-close { position: absolute; top: 10px; right: 26px; font-size: 46px; line-height: 1; color: #fff; opacity: .8; text-decoration: none; font-family: Arial, sans-serif; z-index: 2; }
#imgZoomOverlay .img-zoom-close:hover { opacity: 1; }
#imgZoomToolbar { position: absolute; left: 50%; bottom: 24px; transform: translateX(-50%); display: flex; gap: 8px; }
#imgZoomToolbar button { padding: 6px 14px; background: rgba(255, 255, 255, .15); border: 1px solid rgba(255, 255, 255, .4); color: #fff; font-size: 14px; border-radius: 4px; cursor: pointer; }
#imgZoomToolbar button:hover { background: rgba(255, 255, 255, .3); }

.tpl-related { padding: 24px 26px; background: #fff; border: 1px solid #e7ebf2; border-radius: 12px; }

@media (max-width: 1199px) {
    .tpl-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 991px) {
    .tpl-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .tpl-showcase { flex-direction: column; }
    .tpl-showcase-shot { flex: none; width: 100%; max-height: 420px; }
    .tpl-showcase-shot:hover img { transform: translateY(calc(-100% + 420px)); }
}

@media (max-width: 767px) {
    .tpl-hero { flex-direction: column; align-items: flex-start; padding: 22px; }
    .tpl-hero-text h1 { font-size: 22px; }
    .tpl-hero-stat { padding: 0; border-left: 0; text-align: left; }
    .tpl-hero-stat b { display: inline; font-size: 24px; }
    .tpl-hero-stat span { margin-left: 6px; }
    .tpl-filter { padding: 16px; }
    .tpl-searchbar { max-width: none; }
    .tpl-showcase { padding: 18px; }
    .tpl-showcase-side h1 { font-size: 22px; }
    .tpl-showcase-ops { flex-direction: column; }
    .tpl-showcase-ops .tpl-btn { width: 100%; }
    .tpl-detail, .tpl-related { padding: 18px; }
}

@media (max-width: 575px) {
    .tpl-grid { grid-template-columns: 1fr; }
    .tpl-shot { height: 210px; }
}
