/* 全局重置 */
* {
	margin: 0;
	padding: 0;
	box-sizing: border-box
}

body {
	background-color: #e9eef3;
	font-family: 'Segoe UI','Lucida Grande','PingFang SC',Roboto,'Helvetica Neue',Arial,sans-serif;
	color: #1f2d3d;
	padding: 20px 24px 40px;
	background: #e9eef3 no-repeat center top;
	background-size: auto !important;
	background-attachment: scroll;
	transition: background 0.4s ease;
}
.container {
	max-width: 1400px;
	margin: 0 auto;
	background-color: #fff;
	box-shadow: 0 4px 20px rgba(0,0,0,0.05);
	border-radius: 20px;
	overflow: hidden;
	padding: 20px 28px 32px;
	-webkit-user-select: none;
	-moz-user-select: none;
	-ms-user-select: none;
	user-select: none
}

.top-bar {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	flex-wrap: wrap;
	padding-bottom: 16px;
	border-bottom: 1px solid #e2e8f0;
	margin-bottom: 20px;
	font-size: 13px
}

.date-area {
	color: #5b687c;
	font-size: 13px;
}

.date-area a {
	text-decoration: none;
	color: #3c6e9e;
	font-size: 13px
}

.user-actions {
	display: flex;
	gap: 18px
}

.user-actions iframe {
	width: 100%;
	max-width: 20px;
	height: 18px;
	border: 0
}

.user-actions a {
	text-decoration: none;
	color: #3c6e9e;
	font-size: 13px
}

.user-actions a:hover {
	color: #1e4a76;
	text-decoration: underline
}

.header-banner {
	margin-bottom: 20px;
	border-bottom: 2px solid #eaeef2;
	padding-bottom: 12px;
	display: flex;
	justify-content: space-between;
	align-items: flex-end;
	flex-wrap: wrap
}

.logo-area h1 {
	font-size: 1.8rem;
	font-weight: 600;
	background: linear-gradient(135deg,#2c6e9e,#1e4a76);
	background-clip: text;
	-webkit-background-clip: text;
	color: transparent;
	letter-spacing: -0.3px
}

.logo-area p {
	font-size: .75rem;
	color: #6c86a3;
	margin-top: 4px
}

.date-tag {
	background: #f0f4f9;
	padding: 6px 14px;
	border-radius: 40px;
	font-size: .8rem;
	color: #2c5a7a
}

.date-tag a {
	text-decoration: none;
	color: #3c6e9e;
	font-size: 13px
}

.User-section {
	display: grid;
	gap: 24px 28px;
	margin-bottom: 28px
}

.User-card {
	background: #fff;
	border-radius: 20px;
	border: 1px solid #eef3fc;
	overflow: hidden;
	box-shadow: 0 1px 2px rgba(0,0,0,0.02);
	transition: box-shadow .2s
}

.User-card:hover {
	box-shadow: 0 4px 12px rgba(0,20,40,0.06)
}

.section-title {
	font-size: 1.15rem;
	font-weight: 700;
	background: #f9fbfe;
	padding: 12px 20px;
	border-bottom: 2px solid #e9f0f6;
	letter-spacing: .5px;
	color: #1e3a5f;
	display: flex;
	align-items: center;
	gap: 8px;
	justify-content: space-between
}

.section-title .add {
	display: block;
	margin-left: auto
}

.section-title span {
	background: #eef2f9;
	padding: 2px 8px;
	border-radius: 30px;
	font-size: 12px;
	font-weight: normal;
	color: #3e6a97
}

.section-title a {
	text-decoration: none;
	color: #3c6e9e
}

.User-grid {
	display: flex;
	flex-wrap: wrap;
	padding: 20px 18px 24px;
	gap: 20px 28px;
	justify-content: flex-start;
	align-items: flex-start
}

.User-link {
	display: inline-flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 6px;
	text-decoration: none;
	color: #1f6392;
	font-weight: 500;
	font-size: .85rem;
	transition: color .15s,transform .1s;
	background: transparent;
	padding: 4px 6px;
	border-radius: 12px;
	min-width: 60px;
	text-align: center
}

.icon-sq {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 48px;
	height: 48px;
	border-radius: 10px;
	font-size: 20px;
	font-weight: 600;
	color: #fff;
	text-shadow: 0 1px 3px rgba(0,0,0,0.10);
	flex-shrink: 0;
	transition: transform .15s,box-shadow .15s;
	box-shadow: 0 3px 8px rgba(0,0,0,0.04)
}

.link-text {
	display: block;
	line-height: 1.3;
	font-size: .82rem;
	letter-spacing: .3px;
	color: #1f6392;
	font-weight: 500;
	transition: color .15s;
	max-width: 70px;
	word-break: keep-all;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	max-width: 6.2em;
	text-shadow: 0px 1px 1px #DEDEDE;
}

.User-link:hover .icon-sq {
	transform: translateY(-3px);
	box-shadow: 0 8px 16px rgba(0,0,0,0.08)
}

.User-link:hover .link-text {
	color: #1f2d3d
}

.User-link:hover {
	color: #c0421a
}

.User-link:active {
	transform: scale(0.96)
}

.standalone-cat {
	margin-bottom: 22px
}

.famous-site {
	display: flex;
	flex-wrap: wrap;
	gap: 10px 15px;
	row-gap: 12px;
	background: #fff;
	padding: 6px;
	margin: 10px auto;
	border: 1px solid #e2e9f0;
	border-radius: 15px
}

.site-link {
	font-size: .9rem;
	color: #2c5a7a;
	text-decoration: none;
	white-space: nowrap;
	transition: all .1s;
	border-bottom: 1px dotted transparent
}

.site-link:hover {
	color: #c0421a;
	background:url(bj.png) no-repeat center top; display:block
}

.standalone-cat span {
	background: #eef2f9;
	padding: 2px 8px;
	border-radius: 30px;
	font-size: 12px;
	color: #3e6a97;
	font-weight: 600
}

.search-aggregator {
	background: #f8fafd;
	border-radius: 28px;
	padding: 18px 20px;
	margin-bottom: 28px;
	border: 1px solid #e2edf7;
	box-shadow: 0 1px 3px rgba(0,0,0,0.02)
}

.engine-tabs {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 18px;
	border-bottom: 1px solid #dce5ef;
	padding-bottom: 12px
}

.engine-btn {
	background: transparent;
	border: 0;
	padding: 6px 18px;
	font-size: 14px;
	font-weight: 500;
	border-radius: 40px;
	cursor: pointer;
	color: #4a5b79;
	transition: all .2s;
	font-family: inherit
}

.engine-btn:hover {
	background-color: #e6f0fa;
	color: #1e4663
}

.engine-btn.active {
	background: #1e6fdf;
	color: white;
	box-shadow: 0 2px 6px rgba(30,111,223,0.2)
}

.search-box-wrapper {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 12px;
	background: white;
	border-radius: 60px;
	border: 1px solid #cfdfed;
	padding: 4px 6px 4px 20px;
	transition: all .1s
}

.search-box-wrapper:focus-within {
	border-color: #1e6fdf;
	box-shadow: 0 0 0 3px rgba(30,111,223,0.2)
}

.search-icon {
	font-size: 18px;
	color: #7f8fa4
}

.search-input {
	flex: 1;
	border: 0;
	padding: 12px 0;
	font-size: 15px;
	outline: 0;
	background: transparent;
	font-family: inherit
}

.search-btn {
	background: #1e6fdf;
	border: 0;
	padding: 8px 26px;
	border-radius: 50px;
	color: white;
	font-weight: 600;
	font-size: 14px;
	cursor: pointer;
	transition: background .2s
}

.search-btn:hover {
	background: #0f5bc0
}

.engine-note {
	font-size: 12px;
	color: #6f7d98;
	margin-top: 10px;
	margin-left: 8px
}

hr {
	margin: 20px 0 8px;
	border: 0;
	border-top: 1px solid #e6edf4
}

.link-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 15px;
    row-gap: 12px;
    background: #f8fafd;
    padding: 6px 16px;
    margin: 10px auto; 
    border: 1px solid #e2e9f0;
    border-radius: 15px;
    width: fit-content; 
    width: -moz-fit-content;
}

.link-list .cat-link {
	font-size: .9rem;
	color: #2c5a7a;
	text-decoration: none;
	white-space: nowrap;
	transition: all .1s;
	border-bottom: 1px dotted transparent
}

.link-list .cat-link:hover {
	color: #c0421a;
	border-bottom-color: #2c5a7a
}

.footer-note {
    margin-top: 28px;
    padding-top: 16px;
    text-align: center;
    font-size: 12px;
    color: #8b9abb;
    position: relative;
}

.footer-note::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(to right, transparent, #e2e8f0 20%, #e2e8f0 80%, transparent);
}

.footer-note a {
    text-decoration: none;
    color: #8b9abb;
}

.tag-bracket {
	color: #cb6e4e
}

.special-bracket {
	font-weight: 500;
	color: #c7452b
}

/* 滚动条美化 */
::-webkit-scrollbar {
	width: 10px;
}
::-webkit-scrollbar-track {
	background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
	background: #cbd5e1;
	border-radius: 12px;
}
::-webkit-scrollbar-thumb:hover {
	background: #94a3b8;
}

/* ====================== 栏目卡片 ====================== */
.category-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill,minmax(280px,1fr));
	gap: 24px 28px;
	margin-top: 10px;
}
.category-card {
	background: #fff;
	border-radius: 20px;
	border: 1px solid #eef3fc;
	overflow: hidden;
	box-shadow: 0 1px 2px rgba(0,0,0,0.02);
	position: relative;
}
.category-card.hidden-card { display: none !important; }
.category-card.sorting { opacity: 0.4; background: #e6f0ff; }
.category-card.dragging .category-header { cursor: grabbing; }

/* 栏目头部 */
.category-header {
	font-size: 1.15rem;
	font-weight: 700;
	background: #f9fbfe;
	padding: 12px 20px;
	border-bottom: 2px solid #e9f0f6;
	letter-spacing: .5px;
	color: #1e3a5f;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
	user-select: none;
}
.category-header .header-left {
	display: flex;
	align-items: center;
	gap: 8px;
	flex-wrap: wrap;
}
.category-header .header-left a {
	color: inherit;
	text-decoration: none;
}
.category-header .header-left span {
	background: #eef2f9;
	padding: 2px 8px;
	border-radius: 30px;
	font-size: 12px;
	font-weight: normal;
	color: #3e6a97;
}
.category-header .header-actions {
	display: flex;
	align-items: center;
	gap: 6px;
}
/* 编辑、隐藏按钮 */
.category-header .edit-btn,
.category-header .del-btn {
	border: none;
	border-radius: 6px;
	padding: 4px 6px;
	font-size: 12px;
	line-height: 1;
	cursor: pointer;
	transition: all 0.2s ease;
	background: #eef3fc;
}
.category-header .edit-btn { color: #64748b; }
.category-header .edit-btn:hover {
	background: #dbeafe;
	color: #2563eb;
}
.category-header .edit-btn.saving {
	color: #16a34a;
	background: #dcfce7;
}
.category-header .del-btn { color: #64748b; }
.category-header .del-btn:hover {
	background: #fee2e2;
	color: #ef4444;
}

/* 链接容器 */
.links-list {
	display: flex;
	flex-wrap: wrap;
	padding: 16px 18px;
	gap: 12px 20px;
	align-items: center;
}
.links-list a {
	text-decoration: none;
	font-size: 13.5px;
	color: #2c6282;
	transition: color .15s;
	white-space: nowrap;
}
.links-list a:hover {
	color: #0f4c77;
	text-decoration: underline;
}
/* 单个链接条目容器：相对定位 */
.links-list .link-item {
  position: relative;
  display: inline-block;
  padding-right: 16px; /* 给叉号预留空间，防止文字被遮挡 */
}
/* 链接文字 */
.links-list .link-item a {
  font-size: 13.5px;
  color: #2c6282;
  text-decoration: none;
  transition: color .15s;
  white-space: nowrap;
}
.links-list .link-item a:hover {
  color: #0f4c77;
  text-decoration: underline;
}
/* 删除叉号：绝对定位贴在文字最右侧，脱离文档流 */
.links-list .del-link {
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  border: none;
  background: transparent;
  color: #ccc;
  font-size: 12px;
  cursor: pointer;
  padding: 0 2px;
  border-radius: 4px;
  transition: 0.2s;
  width: 14px;
  height: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.links-list .del-link:hover {
  color: #fff;
  background: #ef4444;
}

/* 添加链接按钮 */
.add-link-btn {
	background: #f1f5f9;
	border: 1px dashed #94a3b8;
	border-radius: 30px;
	padding: 4px 14px;
	font-size: 13px;
	color: #334155;
	cursor: pointer;
	transition: all .2s;
	white-space: nowrap;
}
.add-link-btn:hover {
	background: #eef6ff;
	border-color: #2563eb;
	color: #2563eb;
}

/* ====================== 顶部栏右对齐 ====================== */
.top-bar-right {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

/* ====================== 顶部栏右对齐 ====================== */
.top-bar-right {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

/* ====================== 编辑控制区 ====================== */
.edit-controls {
    display: flex;
    align-items: center;
    gap: 6px;
}

/* 编辑切换按钮 - 纯图标无背景 */
.edit-toggle-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px 6px;
    border: none;
    background: transparent;
    font-size: 13px;
    cursor: pointer;
    color: #64748b;
    font-family: inherit;
    transition: color 0.2s;
}

.edit-toggle-btn:hover {
    color: #2563eb;
}

.edit-toggle-btn.active {
    color: #ef4444;
}

/* 编辑操作按钮组 */
.edit-actions {
    display: flex;
    align-items: center;
    gap: 4px;
}

.edit-action-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px 6px;
    border: none;
    background: transparent;
    font-size: 13px;
    cursor: pointer;
    color: #64748b;
    font-family: inherit;
    transition: color 0.2s;
}

.edit-action-btn:hover {
    color: #2563eb;
}

.edit-action-btn.save-btn:hover {
    color: #16a34a;
}

.edit-action-btn.reset-btn:hover {
    color: #d97706;
}

.category-card.edit-mode-active .category-header {
    cursor: grab;
}

.category-card.edit-mode-active .category-header:active {
    cursor: grabbing;
}
/* ====================== 响应式适配 ====================== */
@media (max-width: 768px) {
    body {
        padding: 12px
    }
    .container {
        padding: 16px
    }
    .category-grid {
        gap: 18px
    }
    .links-list a {
        white-space: normal;
        word-break: keep-all
    }
    .search-box-wrapper {
        flex-wrap: wrap;
        background: #fff;
        padding: 8px
    }
    .search-btn {
        width: 100%;
        margin-top: 6px
    }
    .top-bar {
        justify-content: flex-end
    }
    .logo-area p {
        display: none
    }
    .date-tag {
        display: none
    }
    .header-banner {
        justify-content: center
    }
    .logo-area {
        text-align: center
    }
    .section-title .title-block {
        display: none
    }
    .date-area-hidden {
        margin-right: auto
    }
    .mail-section {
        display: none
    }
    .search-aggregator {
        padding: 18px 10px
    }
    .engine-tabs {
        gap: 2px;
        margin-bottom: 10px;
        padding-bottom: 10px
    }
    .engine-btn {
        padding: 6px 10px
    }
    .search-box-wrapper {
        padding: 0 8px 6px 10px
    }
    .search-input {
        width: 100%
    }
    .search-btn {
        padding: 8px 6px;
        width: 80px
    }

    /* ====== 新增：手机端顶部栏布局调整 ====== */
    .top-bar {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        justify-content: space-between;
        gap: 4px;
    }

    /* 隐藏邮箱登录区域 */
    .date-area-hidden {
        display: none !important;
    }

    /* 右侧区域占满整行，左右分布 */
    .top-bar-right {
        display: flex;
        align-items: center;
        justify-content: space-between;
        width: 100%;
        gap: 4px;
    }

    /* 登录 iframe 放左边 */
    .top-bar-right .user-actions {
        order: 1;
        flex-shrink: 0;
    }

    .top-bar-right .user-actions iframe {
        max-width: 30px;
        height: 16px;
    }

    /* 编辑控制区放右边 */
    .top-bar-right .edit-controls {
        order: 2;
        flex-shrink: 0;
    }

    .edit-toggle-btn {
        font-size: 11px;
        padding: 2px 4px;
    }

    .edit-action-btn {
        font-size: 11px;
        padding: 2px 4px;
    }

    .edit-actions {
        gap: 2px;
    }

    .edit-controls {
        gap: 2px;
    }

    .tips-box {
        display: none !important;
    }
}

/* 新增/编辑链接弹窗 修正版 */
#linkModal.modal-overlay {
    position: fixed;
    top:0; left:0;
    width:100%; height:100%;
    background: rgba(0,0,0,0.4);
    /* 默认隐藏 */
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 999;
    /* 遮罩默认不拦截鼠标，只有弹窗空白区域才拦截 */
    pointer-events: none;
}
/* 弹窗打开时 */
#linkModal.modal-overlay.active { 
    display: flex; 
    pointer-events: auto;
}
/* 弹窗盒子允许鼠标交互 */
#linkModal .modal-box {
    pointer-events: auto;
}
.modal-box {
    background: #fff;
    border-radius: 24px;
    padding: 28px 32px;
    max-width: 480px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}
.modal-box h3 {
    margin-bottom: 18px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.3rem;
}
.modal-box .field { margin-bottom: 16px; }
.modal-box label {
    display: block;
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 4px;
    color: #334155;
}
.modal-box input {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #d1d9e6;
    border-radius: 12px;
    font-size: 14px;
    transition: border 0.2s;
    /* 输入框强制可点击 */
    pointer-events: auto;
}
.modal-box input:focus {
    outline: none;
    border-color: #2563eb;
}
.modal-box .actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 20px;
}
.modal-box .actions button {
    padding: 8px 24px;
    border: none;
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.2s;
}
.modal-box .actions button:hover { opacity: 0.9; }
.modal-box .actions .btn-primary { background: #2563eb; color: #fff; }
.modal-box .actions .btn-secondary { background: #e2e8f0; color: #1e293b; }
.modal-box .actions .btn-danger { background: #ef4444; color: #fff; }

/* 确认弹窗 */
#confirmOverlay {
	position: fixed;
	top:0;left:0;right:0;bottom:0;
	background: rgba(0,0,0,0.4);
	display: none;
	align-items: center;
	justify-content: center;
	z-index: 99999;
}

/* ====================== 移动端统一适配 ====================== */
@media(max-width:768px) {
	body {
		padding: 12px
	}
	.container {
		padding: 16px
	}
	.category-grid {
		gap: 18px
	}
	.links-list a {
		white-space: normal;
		word-break: keep-all
	}
	.search-box-wrapper {
		flex-wrap: wrap;
		background: #fff;
		padding: 8px
	}
	.search-btn {
		width: 100%;
		margin-top: 6px
	}
	.top-bar {
		justify-content: flex-end
	}
	.logo-area p {
		display: none
	}
	.date-tag {
		display: none
	}
	.header-banner {
		justify-content: center
	}
	.logo-area {
		text-align: center
	}
	.section-title .title-block {
		display: none
	}
	.date-area-hidden {
		margin-right: auto
	}
	.mail-section {
		display: none
	}
	.search-aggregator {
		padding: 18px 10px
	}
	.engine-tabs {
		gap: 2px;
		margin-bottom: 10px;
		padding-bottom: 10px
	}
	.engine-btn {
		padding: 6px 10px
	}
	.search-box-wrapper {
		padding: 0 8px 6px 10px
	}
	.search-input {
		width: 100%
	}
	.search-btn {
		padding: 8px 6px;
		width: 80px
	}
}
@media(max-width:540px) {
	.User-grid {
		gap: 14px 16px;
		padding: 16px 12px 20px;
		justify-content: center
	}
	.icon-sq {
		width: 42px;
		height: 42px;
		font-size: 18px;
		border-radius: 12px
	}
	.link-text {
		font-size: .75rem;
		max-width: 5.8em
	}
	.User-link {
		min-width: 50px;
		padding: 2px 4px
	}
}
@media(max-width:400px) {
	.icon-sq {
		width: 38px;
		height: 38px;
		font-size: 16px;
		border-radius: 10px
	}
	.link-text {
		font-size: .7rem;
		max-width: 5.2em
	}
	.User-grid {
		gap: 10px 12px
	}
}
/* ============================================================
   进度条样式
   ============================================================ */
        /* 默认隐藏页面内容 */
        #page-content {
            opacity: 0;
            transition: opacity 0.5s ease;
        }
        /* 加载完成后显示 */
        #page-content.loaded {
            opacity: 1;
        }
        /* 进度条加载状态 */
        .loading-progress {
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            z-index: 99999;
            background: #f5f7fa;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            transition: opacity 0.6s ease;
        }
        .loading-progress.hide {
            opacity: 0;
            pointer-events: none;
        }
        .loading-progress .logo-text {
            font-size: 28px;
            font-weight: bold;
            color: #2299dd;
            margin-bottom: 30px;
            letter-spacing: 4px;
        }
        .loading-progress .loader {
            width: 50px;
            height: 50px;
            border: 4px solid #e0e0e0;
            border-top-color: #2299dd;
            border-radius: 50%;
            animation: spin 800ms linear infinite;
        }
        @keyframes spin {
            to { transform: rotate(360deg); }
        }
        .loading-progress .loading-text {
            margin-top: 20px;
            color: #999;
            font-size: 14px;
        }
/* ============================================================
   气泡样式
   ============================================================ */
.tips-box {
    position: fixed;
    background: #ffffff;
    border: 1px solid #c8d6e6;
    padding: 5px 8px;
    border-radius: 12px;
    font-size: 13px;
    color: #1f2f42;
    box-shadow: 0 12px 36px rgba(0, 16, 32, 0.14), 0 4px 12px rgba(0, 0, 0, 0.04);
    z-index: 999999;
    display: none;
    max-width: 350px;
    word-wrap: break-word;
    line-height: 1.2;
    pointer-events: auto;
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(2px);
    transition: opacity 0.08s ease;
}

/* 气泡内链接 */
.tips-box a {
    color: #c0392b;
    font-weight: 500;
    text-decoration: underline;
    pointer-events: auto;
    padding: 0 2px;
}
.tips-box a:hover {
    color: #8a1a0a;
}

/* ----- 三角（朝上，气泡在下方） ----- */
.tips-box.top-arrow::after {
    content: '';
    position: absolute;
    left: var(--tri-offset, 60px);
    top: -8px;
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 8px solid #ffffff;
}
.tips-box.top-arrow::before {
    content: '';
    position: absolute;
    left: calc(var(--tri-offset, 60px) - 1px);
    top: -10px;
    width: 0;
    height: 0;
    border-left: 9px solid transparent;
    border-right: 9px solid transparent;
    border-bottom: 9px solid #c8d6e6;
    z-index: -1;
}

/* ----- 三角（朝下，气泡在上方） ----- */
.tips-box.bottom-arrow::after {
    content: '';
    position: absolute;
    left: var(--tri-offset, 60px);
    bottom: -5px;
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 5px solid #ffffff;
}
.tips-box.bottom-arrow::before {
    content: '';
    position: absolute;
    left: calc(var(--tri-offset, 60px) - 1px);
    bottom: -10px;
    width: 0;
    height: 0;
    border-left: 9px solid transparent;
    border-right: 9px solid transparent;
    border-top: 9px solid #c8d6e6;
    z-index: -1;
}

/* 响应式 */
@media (max-width: 768px) {
    .card-wrap { padding: 18px 16px; gap: 10px 14px; }
    .tips-tag { font-size: 15px; padding: 4px 12px; }
    .site-header .logo { font-size: 20px; }
    .tips-box { max-width: 220px; font-size: 13.5px; padding: 10px 14px; }
}