/* ============================================================
   以下为布局 / 组件样式，颜色全部引用上面的变量
   ============================================================ */
* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

::-webkit-scrollbar {
	height: 0 !important;
	width: 0 !important;
}

html {
	scroll-behavior: smooth;
}

.transition-fade {
  transition: opacity .25s ease, filter .25s ease;
}

html.is-changing .transition-fade {
  opacity: .1;
  filter: blur(4px);
}


body {
	background: #2c2f3e;
	color: #e4e6ec;
}

a {
	color: inherit;
	text-decoration: none;
	transition: color 0.2s ease, opacity 0.2s ease;
	cursor: pointer;
}

a:hover {
	color: #6a92ff;
}

a:active {
	color: #4f7cff;
	opacity: 0.9;
}

a:focus-visible {
	outline: 1px solid #4f7cff;
	outline-offset: 2px;
	border-radius: 2px;
}

.app {
	display: grid;
	grid-template-columns: 220px 1fr;
	max-width: 85rem;
	margin: 2rem auto;
	max-height: calc(100vh - 10rem);
	overflow: hidden;
	border-radius: 1rem;
	overflow-y: auto;
}
/* Sidebar */
.sidebar {
	background: rgba(52,54,66,255);
	padding: 28px 20px;
	display: flex;
	flex-direction: column;
	position: sticky;
	top: 0;
	height: calc(100vh - 10rem);
}

.logo {
	display: flex;
	align-items: center;
	gap: 10px;
	font-weight: 700;
	font-size: 18px;
	margin-bottom: 40px;
	padding-left: 8px;
}

.logo-icon {
	width: 28px;
	height: 28px;
	border-radius: 8px;
	background: linear-gradient(135deg, #4f7cff, #2b4fbf);
	display: grid;
	place-items: center;
	box-shadow: 0 4px 12px rgba(79, 124, 255, 0.3);
}

.logo-icon svg {
	width: 16px;
	height: 16px;
}

.nav {
	list-style: none;
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.nav li {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 12px 14px;
	border-radius: .5rem;
	color: #8b92a8;
	font-size: 14px;
	transition: 0.2s;
	position: relative;
}

.nav li:hover {
	color: #e4e6ec;
	background: rgba(255, 255, 255, 0.04);
}

.nav li.current {
	color: #e4e6ec;
}

.nav li.current::before {
	content: "";
	position: absolute;
	left: 0;
	top: 50%;
	transform: translateY(-50%);
	width: 3px;
	height: 18px;
	background: #e4e6ec;
	border-radius: 0 3px 3px 0;
}

.topbar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	background: rgba(56, 58, 70, 255);
	padding: 1rem 2rem;
	position: sticky;
	top: 0;
	border-bottom: .35rem solid rgba(52, 54, 66, 255);
	z-index: 9;
}

.search {
      display: flex;
      align-items: center;
      gap: 8px;
      background: #33374a;
      border: 1px solid #3d4156;
      border-radius: 12px;
      padding: 7px 10px 7px 14px;
      color: #8b92a8;
      max-width: 16rem;
      transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
    }

    .search:focus-within {
      border-color:#4f7cff;
      background: #3b4054;
      box-shadow: 0 0 0 3px rgba(79, 124, 255, 0.15);
    }

    .search svg {
      width: 18px;
      height: 18px;
      stroke: currentColor;
      fill: none;
      stroke-width: 2;
      stroke-linecap: round;
      stroke-linejoin: round;
      flex: 0 0 auto;
    }

    .search-input {
      flex: 1 1 auto;
      min-width: 0;
      border: none;
      background: transparent;
      color:#e4e6ec;
      font-size: 14px;
      font-family: inherit;
      outline: none;
    }

    .search-input::placeholder {
      color: #6c7286;
    }
.topbar-right{
    display: flex;
    gap: .5rem;
    align-items: center;
}

    #navToggle{
        display: none;
    }
.ios-nav-btn {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    color: #e4e6ec;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    text-decoration: none;
    border: none;
    background: none;
    line-height: 0;
    margin: 0 .1rem;
    transition:
        width      .4s  cubic-bezier(.4, 0, .2, 1),
        margin     .4s  cubic-bezier(.4, 0, .2, 1),
        opacity    .3s  ease,
        transform  .2s  ease,
        background .2s  ease,
        box-shadow .25s ease;
}
.scroll-progress-bg {
    fill: none;
    stroke:rgba(52,54,66,255);
    stroke-width: 2.5;
}
.scroll-progress-bar {
    fill: none;
    stroke:#e4e6ec;
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-dasharray: 87.96;
    stroke-dashoffset: 87.96;
    transition: stroke-dashoffset 0.15s;
}
.scroll-progress-text {
    font-size: 9px;
    font-weight: 700;
    color:#e4e6ec;
    position: absolute;
    z-index: 1;
    line-height: 1;
}
.archive {
	background: rgba(56, 58, 70, 255);
	padding: 1rem;
	display: grid;
	gap: 2rem;
	grid-template-columns: 1fr 300px;
}

.post-item {
	border-radius: .5rem;
	transition: 0.2s;
}

.post-item {
	display: flex;
	gap: 16px;
	align-items: flex-start;
	margin-block-end: 3rem;
	padding-block-end: 3rem;
	border-bottom: thin solid #3d4156;
}

.post-avatar {
	flex: 0 0 auto;
	width: 46px;
	height: 46px;
}

.post-avatar img {
	width: 100%;
	height: 100%;
	border-radius: 50%;
	object-fit: cover;
	display: block;
}

.post-body {
	flex: 1 1 auto;
	min-width: 0;
}

.post-item:hover {
	transform: translateY(-2px);
}

.post-main h3 {
	font-size: 18px;
	font-weight: 600;
	line-height: 1.4;
	margin-bottom: 6px;
	transition: 0.2s;
	color: #e4e6ec;
}

.post-item:hover .post-main h3 {
	color: #6a92ff;
}

.post-avatar {
	width: 46px;
	height: 46px;
	border-radius: 50%;
	display: grid;
	place-items: center;
	font-size: 15px;
	font-weight: 700;
	color: #fff;
	flex-shrink: 0;
	letter-spacing: 0.5px;
}

.post-body {
	min-width: 0;
}

.post-head {
	display: flex;
	align-items: baseline;
	gap: 8px;
	margin-bottom: 6px;
}

.post-author {
	font-size: 14px;
	font-weight: 600;
}

.post-handle {
	font-size: 12px;
	color: #6c7286;
}

.post-time {
	font-size: 12px;
	color: #6c7286;
	margin-left: auto;
}

.post-text {
	font-size: 14px;
	line-height: 1.55;
	color: #8b92a8;
	margin-bottom: 14px;
}
.page_next {
    color: #6c7286;
    text-align: center;
    margin-block-end: 3rem;
    font-size: 13px;
}
    /* Right Sidebar */
.rightbar {
	display: flex;
	flex-direction: column;
	gap: 20px;
	position: sticky;
	top: 5rem;
	height: calc(100vh - 4rem);
}

.card {
	border-radius: .5rem;
	padding: 1rem;
	background: -webkit-linear-gradient(top left, rgba(99, 100, 119, 1), rgba(62, 63, 81, 1));
	background: linear-gradient(to bottom right, rgba(99, 100, 119, 1), rgba(62, 63, 81, 1));
	box-shadow: 0 12px 30px rgba(0, 0, 0, 0.28);
}

.card-header {
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 1px;
	color: #8b92a8;
	text-transform: uppercase;
	margin-bottom: 16px;
}
/* Health / Activity widget */
.health-card {
	text-align: center;
}

.health-hero {
	display: flex;
	flex-direction: column;
	align-items: center;
	margin-bottom: 18px;
}

.health-number {
	font-size: 42px;
	font-weight: 700;
	letter-spacing: -0.02em;
	color: #6a92ff;
	line-height: 1;
	margin-bottom: 6px;
}

.health-date {
	font-size: 12px;
	color: #8b92a8;
	margin-bottom: 14px;
}
.health-status {
	font-size: 13px;
	font-weight: 600;
	color: #e4e6ec;
}

.health-rows {
	display: flex;
	flex-direction: column;
	gap: 10px;
	text-align: left;
}

.health-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	font-size: 12px;
	padding: 10px 12px;
	background: #3b4054;
	border-radius: .25rem;
}

.health-row-label {
	color: #8b92a8;
	display: flex;
	align-items: center;
	gap: 8px;
}

.health-row-label svg {
	width: 14px;
	height: 14px;
	fill: none;
	stroke: #8b92a8;
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.health-row-value {
	color: #e4e6ec;
	font-weight: 500;
}
/* footer */
.footer-inner,.footer-beian{
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .2rem;
    font-size: 13px;
    color: #6c7286;
    text-align: center;
}
.footer-meta__item{
    display: flex;
    gap: .5rem;
    justify-content: center;
}
/* Article */
    .article {
      max-width: 760px;
      margin: 0 auto;
      padding: 0 0 40px;
    }

    .article-header {
      margin-bottom: 32px;
    }

    .article-cat {
      display: inline-flex;
      align-items: center;
      gap: 8px;
      font-size: 12px;
      font-weight: 700;
      letter-spacing: 0.5px;
      text-transform: uppercase;
      color: #6a92ff;
      margin-bottom: 14px;
    }

    .article-cat::before {
      content: "";
      width: 8px;
      height: 8px;
      border-radius: 50%;
      background: #4f7cff;
    }

    .article-title {
      font-size: 36px;
      line-height: 1.15;
      font-weight: 700;
      margin-bottom: 22px;
      letter-spacing: -0.02em;
    }

    .article-meta {
      display: flex;
      align-items: center;
      gap: .8rem;
      flex-wrap: wrap;
      color: #8b92a8;
      font-size: 13px;
    }

    .article-author {
      display: flex;
      align-items: center;
      gap: .5rem;
    }

    .article-author .avatar img{
      width: 32px;
      height: 32px;
      border-radius: 50%;
      display: grid;
      place-items: center;
      font-size: 14px;
      font-weight: 700;
      color: #fff;
    }

    .article-author .name {
      color:#e4e6ec;
      font-weight: 600;
    }

    .article-date {
      display: flex;
      align-items: center;
      gap: 6px;
    }

    .article-date svg {
      width: 14px;
      height: 14px;
      stroke: currentColor;
      fill: none;
      stroke-width: 2;
      stroke-linecap: round;
      stroke-linejoin: round;
    }

    .article-divider {
      width: 4px;
      height: 4px;
      border-radius: 50%;
      background: #6c7286;
    }

    .article-body {
      font-size: 15px;
      line-height: 1.75;
      color:#e4e6ec;
    }

    .article-body > * {
      margin-bottom: 1.6em;
    }

    .article-body h2 {
      font-size: 26px;
      font-weight: 700;
      margin: 1.8em 0 0.7em;
      letter-spacing: -0.01em;
      line-height: 1.25;
    }

    .article-body h3 {
      font-size: 20px;
      font-weight: 600;
      margin: 1.6em 0 0.6em;
      line-height: 1.3;
    }

    .article-body ul,
    .article-body ol {
      margin: 0 0 1.6em 1.2em;
      padding-left: 1.2em;
    }

    .article-body li {
      margin-bottom: 0.55em;
    }

    .article-body li::marker {
      color: #6c7286;
    }

    .article-body blockquote {
      border-left: 3px solid #4f7cff;
      padding: 0.8em 0 0.8em 1.2em;
      margin: 0 0 1.6em;
      color: #8b92a8;
      font-style: italic;
    }

    .article-body code {
      font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
      font-size: 0.9em;
      background:#33374a;
      padding: 0.15em 0.4em;
      border-radius: 5px;
      color: #6a92ff;
    }

    .article-body pre {
      background:#33374a;
      border-radius: 12px;
      padding: 18px 20px;
      overflow-x: auto;
      margin: 0 0 1.6em;
      border: 1px solid #3d4156;
    }

    .article-body pre code {
      background: transparent;
      padding: 0;
      color:#e4e6ec;
      font-size: 14px;
      line-height: 1.6;
    }

    .article-body hr {
      border: none;
      border-top: 1px solid #3d4156;
      margin: 2.4em 0;
    }

    .article-body img {
      max-width: 100%;
    border-radius: 8px;
      display: block;
    }

.article-body figcaption.image-caption {
    padding: .2rem .5rem;
    background: rgba(28, 28, 30, 0.72);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    width: fit-content;
    border-radius: 2rem;
    position: absolute;
    bottom: 1rem;
    font-size: 13px;
    transform: translateX(50%);
    right: 50%;
}
.article-body .post__image {
    position: relative;
    cursor: zoom-in;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    filter: brightness(0.85);
}

/*links*/
.links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: .5rem;
}
.link-card {
    display: flex;
    align-items: center;
    gap: .5rem;
    padding: 1rem 0;
    border-radius: 4px;
    text-decoration: none;
    color: inherit;
    transition: all .25s;
    overflow: hidden;
    position: relative;
}
.link-avatar {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    overflow: hidden;
    position: relative;
}
.link-avatar img {
    width: 100%;
    height: 100%;
    border-radius: 4px;
    object-fit: cover;
    display: block;
}
.link-info {
    flex: 1;
    min-width: 0;
    position: relative;
}
.link-name {
    font-size: 15px;
    font-weight: 700;
    color: #e4e6ec;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    transition: color .15s;
    line-height: 1.4;
}
.link-desc {
    font-size: 13px;
    color: #8b92a8;
    margin-top: 3px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 1.4;
}
.link-status.online {
    color: #059669;
    background: rgba(16, 185, 129, 0.08);
}
.link-status {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    font-weight: 500;
    padding: 2px 8px;
    border-radius: 50px;
    vertical-align: middle;
    margin-left: 2px;
    transition: all .3s;
    background: rgba(52,54,66,255);
    color: #8b92a8;
}
.link-status.online::before {
    background: #34d399;
    box-shadow: 0 0 4px rgba(16, 185, 129, 0.35);
}
.link-status::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #6b7280;
    flex-shrink: 0;
    transition: background .3s;
}
.tag-list span {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    color: rgb(148 200 216);
    background: rgb(148 200 216 / 10%);
    padding: 2px 8px;
    border-radius: 2rem;
    font-weight: 500;
}
.tag-list {
    display: flex;
    align-items: center;
    gap: 3px;
    margin-top: 5px;
}
@media (max-width: 769px) {
    .app{
        margin: 0;
        border-radius: 0;
        max-height: none;
        display: block;
    }
    .sidebar{
        height: 100vh;
        position: fixed;
        z-index: 8;
        width: 18rem;
    }
    .sidebar{
        overflow-y: auto;
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }
    .nav-open .sidebar{
        transform: translateX(0);
        box-shadow: 2px 0 24px rgba(0, 0, 0, 0.35);
    }
    .topbar-right{
        position: fixed;
        bottom: 1rem;
        left: 1rem;
        z-index: 9;
        display: flex;
        gap: .5rem;
        padding: .5rem;
        background: rgba(28, 28, 30, 0.72);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        width: fit-content;
        border-radius: 2rem;
    }
    #navToggle{
        display: flex;
        border: thin solid rgba(52, 54, 66, 255);
    }
    /* 默认隐藏关闭图标 */
    .ios-nav-btn .ico-close {
      display: none;
    }
    /* 导航打开时：隐藏三点、显示叉号 */
    body.nav-open .ios-nav-btn .ico-menu {
      display: none;
    }
    body.nav-open .ios-nav-btn .ico-close {
      display: block;
    }
    .archive{
        display: block;
    }
    .rightbar{
        display: none;
    }
    .site-footer{
        margin: 3rem 0;
        margin-block-end: 1rem;
    }
}