/* 全站样式 —— 复刻原站 layui 观感 */
* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: "Microsoft YaHei", "PingFang SC", "Helvetica Neue", Arial, sans-serif;
  font-size: 14px;
  color: #333;
  background: #eef4fa;
}

a { color: #01aaed; text-decoration: none; }
a:hover { color: #1e9fff; }

/* ============ 顶部导航 ============ */
.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  height: 60px; background: #393d49;
  box-shadow: 0 2px 6px rgba(0, 0, 0, .2);
}
.site-header .container { display: flex; align-items: center; justify-content: space-between; height: 60px; }
.logo-text {
  font-family: "STXingkai", "KaiTi", "STKaiti", cursive;
  font-size: 30px; font-weight: bold; letter-spacing: 2px;
  background: linear-gradient(90deg, #ff6c9b, #b48cff 40%, #5bc1ff 75%, #7dffb2);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  text-shadow: none; filter: drop-shadow(0 0 6px rgba(122, 92, 255, .55));
}
.header-nav { display: flex; align-items: center; gap: 26px; }
.header-nav a {
  display: flex; align-items: center; gap: 8px;
  color: #e8ecf3; font-size: 15px;
}
.header-nav a:hover { color: #fff; }
.header-nav .avatar {
  width: 34px; height: 34px; border-radius: 50%;
  background: #fff; border: 1px solid rgba(52, 73, 94, .44);
  display: inline-flex; align-items: center; justify-content: center;
  animation: spin 6s linear infinite;
}
.header-nav .avatar svg { width: 22px; height: 22px; }
@keyframes spin { to { transform: rotate(360deg); } }
.nav-dot { width: 8px; height: 8px; border-radius: 50%; background: #ff5722; display: inline-block; }

/* ============ 布局 ============ */
.container { width: 1140px; max-width: 96%; margin: 0 auto; }
.main-wrap { padding-top: 74px; padding-bottom: 30px; }

.row { display: flex; gap: 15px; }
.col-form { flex: 0 0 41.666%; min-width: 0; }
.col-gallery { flex: 1; min-width: 0; }
@media (max-width: 992px) {
  .row { flex-direction: column; }
  .col-form, .col-gallery { flex: auto; width: 100%; }
}

/* ============ 卡片面板 ============ */
.fly-panel {
  background: #fff; border-radius: 4px;
  box-shadow: 0 2px 10px rgba(120, 130, 140, .12);
  margin-bottom: 15px; overflow: hidden;
}
.fly-panel-title {
  font-size: 15px; font-weight: 400; color: #333;
  padding: 12px 15px; border-bottom: 1px solid #f0f0f0;
  background: #fcfcfc;
  display: flex; align-items: center; gap: 7px;
}
.fly-panel-title .ico { font-style: normal; font-weight: bold; }
.fly-panel-title .ico.blue { color: #36a3ff; }
.fly-panel-title .ico.red { color: #ff5722; }

blockquote.quote {
  border-left: 5px solid #009688; background: #f8f8f8;
  padding: 10px 15px; margin: 15px; line-height: 1.8; border-radius: 0 3px 3px 0;
}
blockquote.quote.warn { background: #fff2d3; border-left-color: #ffc94a; }
blockquote.quote .q-title { color: #ff6c00; display: inline-flex; align-items: center; gap: 5px; }

/* ============ 广告横幅 ============ */
.ad-box {
  background: #fff; box-shadow: 0 0 10px #dedede;
  padding: 5px; margin: 5px 0; border-radius: 3px;
}
.ad-banner {
  display: block; width: 100%; height: 70px; margin-bottom: 10px;
  border-radius: 4px; overflow: hidden; position: relative;
  background: linear-gradient(120deg, #1b2a4a 0%, #274b8f 45%, #3f7ad6 100%);
}
.ad-banner .ad-inner {
  position: absolute; inset: 0; display: flex; align-items: center;
  justify-content: space-between; padding: 0 34px; color: #fff;
}
.ad-banner .ad-slogan { font-size: 24px; font-weight: bold; letter-spacing: 3px; }
.ad-banner .ad-slogan small { display: block; font-size: 12px; font-weight: 400; opacity: .8; letter-spacing: 1px; margin-top: 4px; }
.ad-banner .ad-badge {
  border: 1px solid rgba(255, 255, 255, .7); border-radius: 20px;
  padding: 5px 16px; font-size: 13px; opacity: .9;
}

/* 彩虹滚动公告 */
.ann-bar {
  background: #333; border-radius: 25px;
  box-shadow: 0 0 5px #f200ff;
  padding: 5px 10px; margin: 10px 0 0; overflow: hidden; white-space: nowrap;
}
.ann-text {
  display: inline-block; padding-left: 100%; font-size: 20px; font-weight: bold;
  background: linear-gradient(90deg, #fff, #f00 6.25%, #ff7d00 12.5%, #ff0 18.75%, #0f0 25%, #0ff 31.25%, #00f 37.5%, #f0f 43.75%, #ff0 50%, #f00 56.25%, #ff7d00 62.5%, #ff0 68.75%, #0f0 75%, #0ff 81.25%, #00f 87.5%, #f0f 93.75%, #ff0 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  background-size: 200% 100%;
  animation: marquee 14s linear infinite, masked 2s infinite linear;
}
@keyframes marquee { 0% { transform: translateX(0); } 100% { transform: translateX(-100%); } }
@keyframes masked { 0% { background-position: 0 0; } 100% { background-position: -200% 0; } }

/* 8 宫格文字广告 */
.txt-ad { width: 100%; overflow: hidden; display: flex; flex-wrap: wrap; padding-top: 5px; }
.txt-ad a {
  width: calc(25% - 5px); margin: 2.5px; border-radius: 2px;
  line-height: 35px; height: 35px; text-align: center;
  font-size: 14px; color: #fff; display: inline-block;
  transition-duration: .3s; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.txt-ad a:nth-child(1) { background: #dc3545; }
.txt-ad a:nth-child(2) { background: #007bff; }
.txt-ad a:nth-child(3) { background: #28a745; }
.txt-ad a:nth-child(4) { background: #ffc107; }
.txt-ad a:nth-child(5) { background: #28a745; }
.txt-ad a:nth-child(6) { background: #ffc107; }
.txt-ad a:nth-child(7) { background: #dc3545; }
.txt-ad a:nth-child(8) { background: #007bff; }
.txt-ad a:hover { background: #ff2805; color: #fff; }
@media (max-width: 1000px) {
  .txt-ad a { width: calc(50% - 5px); }
}

/* ============ 表单 ============ */
.form-body { padding: 15px; }
.form-item { margin-bottom: 15px; }
.form-item.tight { margin-bottom: 5px; }
.form-row { display: flex; align-items: stretch; }
.form-label {
  flex: 0 0 110px; background: #f8f8f8; border: 1px solid #e6e6e6;
  border-right: none; padding: 0 14px; display: flex; align-items: center;
  justify-content: center; color: #555; font-size: 14px;
  border-radius: 2px 0 0 2px;
}
.form-input {
  flex: 1; border: 1px solid #e6e6e6; border-radius: 0 2px 2px 0;
  padding: 0 12px; height: 38px; font-size: 14px; color: #333; outline: none;
  min-width: 0;
}
.form-input:focus { border-color: #1e9fff; }
.form-hint { color: #c2c2c2; font-size: 13px; }
.form-hint.red { color: #ff5722; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 38px; padding: 0 18px; border: 1px solid transparent; border-radius: 3px;
  font-size: 14px; cursor: pointer; background: #f6f6f6; color: #333;
  transition: all .2s; user-select: none; white-space: nowrap;
}
.btn:hover { opacity: .85; }
.btn.btn-fluid { width: 100%; }
.btn.btn-primary-outline { background: #fff; border-color: #1e9fff; color: #1e9fff; }
.btn.btn-primary-outline:hover { background: #1e9fff; color: #fff; }
.btn.btn-blue { background: #1e9fff; color: #fff; }
.btn.btn-orange { background: #ffb800; color: #fff; }
.btn.btn-red { background: #ff5722; color: #fff; }
.btn.btn-default { background: #fff; border-color: #d2d2d2; color: #555; }
.btn.btn-xs { height: 26px; padding: 0 10px; font-size: 12px; }
.btn[disabled] { cursor: not-allowed; opacity: .6; }

/* 选中风格条 */
.picked-style {
  display: none; align-items: center; gap: 10px;
  margin: 0 15px; padding: 8px 10px; background: #f2f9ff;
  border: 1px dashed #a3cdff; border-radius: 4px;
}
.picked-style.show { display: flex; }
.picked-style img { width: 74px; height: 46px; object-fit: cover; border-radius: 4px; }
.picked-style .p-name { color: #333; font-weight: bold; }
.picked-style .p-tag { font-size: 12px; color: #888; }
.picked-style .p-change { margin-left: auto; }

/* 写入过程面板 */
.write-progress { display: none; padding: 40px 15px; text-align: center; }
.write-progress.show { display: block; }
.write-progress .big-ico { font-size: 70px; line-height: 1; }
.write-progress .ok { color: #16b777; }
.write-progress .err { color: #ff5722; }
.write-progress .loading-ico { color: #1e9fff; }
.write-progress .msg { margin-top: 18px; color: #9f9f9f; font-size: 15px; line-height: 2; }
.spin { display: inline-block; animation: spin 1s linear infinite; }

/* 成功面板代码区 */
.code-actions { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin-top: 12px; }
.code-preview {
  display: none; margin: 12px 15px 15px; max-height: 260px; overflow: auto;
  background: #2b3245; color: #d6e2f0; border-radius: 4px;
  padding: 12px; font-family: Consolas, monospace; font-size: 12px;
  text-align: left; white-space: pre-wrap; word-break: break-all; line-height: 1.7;
}
.code-preview.show { display: block; }

/* ============ 风格库 ============ */
.gallery-body { padding: 15px; }
.gallery-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
@media (max-width: 768px) { .gallery-grid { grid-template-columns: repeat(2, 1fr); } }
.style-card { display: block; position: relative; border-radius: 10px; overflow: hidden;
  box-shadow: 0 0 10px rgba(116, 116, 116, .08); cursor: pointer; }
.style-card img.cover { width: 100%; aspect-ratio: 3/2; object-fit: cover; display: block; transition: all .2s; }
.style-card:hover img.cover { transform: scale(1.06); }
.style-card .mask {
  position: absolute; inset: 0;
  background: linear-gradient(0deg, rgba(29, 41, 49, .4) 3em, rgba(255, 255, 255, 0) 8em);
  pointer-events: none;
}
.style-card .hover-ring {
  position: absolute; inset: 0; display: none; align-items: center; justify-content: center;
  gap: 10px;
  background: rgba(0, 86, 255, .22); z-index: 2;
  color: #fff; text-shadow: 1px 1px 3px #000; font-size: 16px;
}
.style-card:hover .hover-ring { display: flex; }
.style-card .hover-ring .pick-btn { text-shadow: none; }
.style-card .hover-ring .ring {
  width: 44px; height: 44px; border-radius: 50%;
  border: 4px solid rgba(255, 255, 255, .35); border-top-color: #fff;
  animation: spin 1s linear infinite;
}
.style-card .card-info {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 12px 15px; color: #fff;
  text-shadow: 0 0 5px rgba(0, 0, 0, .2); z-index: 1;
}
.style-card .card-info .tags { margin-bottom: 6px; }
.style-card.picked { outline: 3px solid #1e9fff; outline-offset: -3px; }

.badge {
  display: inline-block; padding: 0 8px; line-height: 18px; height: 18px;
  font-size: 11px; color: #fff; border-radius: 2px; background: #1e9fff;
}
.badge.gray { background: #dddcdc; color: #666; }
.badge.orange { background: #ffb800; }
.badge.rim { background: #fff; color: #666; border: 1px solid #d2d2d2; }

/* 分页 */
.pager { text-align: center; padding: 5px 0 15px; }
.pager .pg {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 34px; height: 30px; padding: 0 10px; margin: 0 3px;
  background: #fff; border: 1px solid #d2d2d2; border-radius: 3px;
  color: #555; font-size: 13px; cursor: pointer; user-select: none;
}
.pager .pg:hover { border-color: #1e9fff; color: #1e9fff; }
.pager .pg.cur { background: #1e9fff; border-color: #1e9fff; color: #fff; }
.pager .pg.disabled { color: #d2d2d2; cursor: not-allowed; }

/* ============ 详情页 ============ */
.detail-panel { background: #fff; border-radius: 15px 15px 0 0; margin-bottom: 15px;
  box-shadow: 0 2px 10px rgba(120, 130, 140, .12); }
.detail-panel.last { border-radius: 0 0 15px 15px; }
.detail-panel .inner { padding: 10px; }
.detail-top { display: flex; gap: 15px; }
.detail-top .pic { flex: 0 0 33.33%; }
.detail-top .pic img { width: 100%; border-radius: 15px; display: block; }
.detail-top .info { flex: 1; min-width: 0; }
.detail-name {
  text-align: center; background: #f5f5f5; margin-bottom: 10px;
  padding: 20px; border-radius: 15px; font-size: 30px;
}
.detail-quote { border-left: 5px solid #009688; background: #f8f8f8; border-radius: 15px;
  padding: 10px; margin-bottom: 10px; display: flex; align-items: center; }
.detail-quote .qk { flex: 1; }
.detail-quote .qv { display: flex; gap: 6px; flex-wrap: wrap; }
.detail-btns { text-align: center; padding: 10px; display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }
@media (max-width: 992px) { .detail-top { flex-direction: column; } }
fieldset.legend-box { border: 1px solid #eee; padding: 0 15px 15px; margin-top: 0; border-width: 1px 0 0; }
fieldset.legend-box legend { margin-left: 20px; padding: 0 10px; font-size: 14px; color: #333; }
.preview-box { text-align: center; background: #f5f5f5; padding: 20px; border-radius: 15px; }
.preview-box .no-pic { color: #bbb; }
.preview-box .no-pic .eye { font-size: 90px; line-height: 1.2; }
.preview-box img { max-width: 100%; border-radius: 10px; }

/* 预览 iframe 容器 */
.preview-frame { width: 100%; height: 420px; border: 0; border-radius: 10px; background: #000; }

/* ============ 时间线(公告页) ============ */
.timeline { padding: 15px; }
.tl-item { position: relative; padding-bottom: 24px; padding-left: 30px; }
.tl-item:before {
  content: ""; position: absolute; left: 0; top: 0; bottom: -10px; width: 1px; background: #e2e2e2;
}
.tl-item:last-child:before { display: none; }
.tl-item .dot {
  position: absolute; left: -6px; top: 3px; width: 13px; height: 13px; border-radius: 50%;
  background: #a9d3ff; border: 2px solid #fff; box-shadow: 0 0 0 1px #a9d3ff;
  animation: pulse 1.6s ease-in-out infinite;
}
@keyframes pulse { 50% { transform: scale(1.25); } }
.tl-item .tl-title { font-size: 15px; color: #333; font-weight: 600; margin-bottom: 6px; }
.tl-item .tl-title .tl-date { color: #1e9fff; margin-right: 8px; }
.tl-item ul { color: #777; line-height: 1.9; padding-left: 18px; }

/* ============ 页脚 ============ */
.custom-footer { background: #393d49; color: #aeb5c2; padding: 40px 0 20px; font-size: 14px; margin-top: 60px; }
.custom-footer .row { gap: 0; }
.footer-logo-area .logo-text { font-size: 28px; }
.footer-logo-area p { line-height: 1.8; margin-top: 10px; }
.footer-logo-area .f-icos { margin-top: 20px; display: flex; gap: 15px; }
.footer-logo-area .f-icos a { color: #fff; font-size: 18px; width: 34px; height: 34px; border: 1px solid #4e5563;
  border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; }
.footer-logo-area .f-icos a:hover { border-color: #1e9fff; color: #1e9fff; }
.footer-title { color: #fff; font-size: 16px; font-weight: 600; margin-bottom: 20px; position: relative; padding-left: 10px; }
.footer-title:before { content: ""; position: absolute; left: 0; top: 4px; bottom: 4px; width: 3px; background: #1e9fff; border-radius: 2px; }
.footer-links { display: grid; grid-template-columns: 1fr 1fr; }
.footer-links a { display: block; color: #aeb5c2; line-height: 2.4; transition: all .3s; }
.footer-links a:hover { color: #1e9fff; padding-left: 5px; }
.contact-list p { line-height: 2.4; display: flex; align-items: center; gap: 8px; }
.contact-list .ci { color: #1e9fff; width: 16px; text-align: center; }
.copyright-bar { border-top: 1px solid #4e5563; margin-top: 30px; padding-top: 20px; text-align: center; color: #7b8291; font-size: 12px; line-height: 2; }

/* ============ 弹层 ============ */
.toast-wrap { position: fixed; top: 18%; left: 0; right: 0; display: flex; flex-direction: column; align-items: center; gap: 8px; z-index: 9999; pointer-events: none; }
.toast {
  background: rgba(0, 0, 0, .72); color: #fff; padding: 10px 22px; border-radius: 4px;
  font-size: 14px; animation: fadein .2s;
}
@keyframes fadein { from { opacity: 0; transform: translateY(-8px); } }

.mask-layer { position: fixed; inset: 0; background: rgba(0, 0, 0, .45); z-index: 9000; display: none; align-items: center; justify-content: center; }
.mask-layer.show { display: flex; }
.dlg { background: #fff; border-radius: 6px; width: 340px; max-width: 92%; overflow: hidden; box-shadow: 0 6px 30px rgba(0,0,0,.25); }
.dlg .dlg-title { padding: 12px 15px; background: #f8f8f8; font-size: 14px; display: flex; justify-content: space-between; align-items: center; }
.dlg .dlg-title .close { cursor: pointer; color: #999; font-size: 18px; line-height: 1; }
.dlg .dlg-body { padding: 15px; }

/* 滑块验证 */
.captcha-track { background: #f2f4f8; border-radius: 4px; padding: 8px; }
.captcha-pic {
  position: relative; height: 150px; border-radius: 4px; overflow: hidden; background: #2c5364;
}
.captcha-pic canvas { width: 100%; height: 100%; display: block; }
.captcha-piece { position: absolute; top: 0; left: 0; }
.captcha-slider { margin-top: 10px; position: relative; height: 40px; background: #e8ebf0; border-radius: 4px; overflow: hidden; }
.captcha-slider .fill { position: absolute; left: 0; top: 0; bottom: 0; width: 0; background: #d1e7fe; }
.captcha-slider .block {
  position: absolute; left: 0; top: 0; width: 48px; height: 40px; background: #fff;
  border: 1px solid #d5dae2; border-radius: 4px; display: flex; align-items: center; justify-content: center;
  cursor: grab; z-index: 2; color: #999; box-shadow: 0 1px 3px rgba(0,0,0,.12);
}
.captcha-slider .block:active { cursor: grabbing; }
.captcha-slider .tip { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: #8a93a2; font-size: 13px; z-index: 1; }
.captcha-slider.done .fill { background: #c9f0d8; }
.captcha-slider.done .tip { color: #16b777; }
.captcha-err { color: #ff5722; font-size: 12px; text-align: center; margin-top: 8px; min-height: 16px; }

/* loading 遮罩 */
.load-mask { position: fixed; inset: 0; background: rgba(0,0,0,.25); z-index: 9500; display: none; align-items: center; justify-content: center; }
.load-mask.show { display: flex; }
.load-mask .loader {
  width: 44px; height: 44px; border-radius: 50%;
  border: 4px solid rgba(255,255,255,.35); border-top-color: #1e9fff;
  animation: spin .8s linear infinite;
}
