/*主题变量*/
:root,[data-theme=light] {
  --hn-page-width:60%;
  --hn-header-height:4.75rem;
  
  --hn-body-bg:#f0f0f0;
  --hn-gray-bg:#f6f6f6;
  --hn-text-color:#333;
  --hn-text-secondary-color:#777;
  --hn-article-color:#424244;
  --hn-primary:#111;
  --hn-primary-hover:#000;
  
  --hn-warning-rgb:255, 80, 41;
  --hn-success-rgb:189, 255, 28;
  --hn-success-rgb-hover:107, 151, 0;
  
  --hn-border-radius:12px;
  --hn-dark-lighter-bg:#fff;
  --hn-dark-lighter-shadow:rgba(10, 10, 10, 0.06) 0px 1.2px 1.2px 0px, rgba(10, 10, 10, 0.04) 0px 5px 10px 0px; 

  --hn-black:#000;  
  --hn-white:#fff;
  --hn-box-bg:#fff;
  --hn-box-shadow:rgba(10, 10, 10, 0.06) 0px 1.2px 1.2px 0px, rgba(10, 10, 10, 0.04) 0px 5px 10px 0px;
  --hn-box-shadow-inset: 0 0 0 2px #e0e0e0 inset;
  --hn-box-shadow-deep:0 1.3436836425447838px .5374734570179134px -.625px #00000017,0 3.184767494094558px 1.273906997637823px -1.25px #00000016,0 5.80934510345105px 2.3237380413804196px -1.875px #00000015,0 9.658024572418071px 3.8632098289672276px -2.5px #00000014,0 15.596922177565284px 6.238768871026112px -3.125px #00000012,0 25.530614085937845px 10.212245634375137px -3.75px #00000010,0 43.96199341069441px 17.58479736427776px -4.375px #0000000a,0 80px 31.999999999999993px -5px #0000;
  --hn-img-border:1px solid #f0f0f0;
  --hn-box-border:1.6px solid #eee;
  --hn-box-tint-bg:#f9f9f9;
  --hn-box-tint-shadow:rgba(0, 0, 0, 0.08) 0px 0.8px 0.8px 0px, rgba(0, 0, 0, 0.04) 0px 3.2px 6.4px 0px;
  --hn-box-tint-border:1px solid #f0f0f0;
  
  --hn-cursor-default: url(../img/cursor/default.svg) 8 6, default;
  --hn-cursor-pointer: url(../img/cursor/pointer.svg) 6 6, pointer;
  --hn-cursor-active: url(../img/cursor/active.svg) 6 6, pointer;
  --hn-cursor-not-allowed: url(../img/cursor/default.svg) 8 6, not-allowed;
  --hn-cursor-help: url(../img/cursor/help.svg) 6 6, help;
  --hn-cursor-grab: url(../img/cursor/grab.svg) 6 6, grab;
  --hn-cursor-grabbing: url(../img/cursor/grabbing.svg) 6 6, grabbing;
  --hn-cursor-special: url(../img/cursor/special.svg) 10 5, pointer;  
}
[data-theme=dark] {
  color-scheme:dark;
  --hn-body-bg:#161616;
  --hn-gray-bg:#2b2b2b;
  --hn-text-color:#aaa;
  --hn-text-secondary-color:#bbb;
  --hn-article-color:#ccc;
  --hn-primary:#aaa;
  --hn-primary-hover:#eee;
  
  --hn-border-radius:12px;
  
  --hn-dark-lighter-bg:#383838;
  --hn-dark-lighter-shadow:rgba(10, 10, 10, 0.2) 0px 1.2px 1.2px 0px, rgba(10, 10, 10, 0.1) 0px 5px 10px 0px;
  
  --hn-box-bg:#212121;
  --hn-box-shadow:rgba(0, 0, 0, 0.6) 0px 1.2px 1.2px 0px, rgba(0, 0, 0, 0.5) 0px 5px 10px 0px;
  --hn-box-shadow-inset: 0 0 0 2px #393838 inset;
  --hn-img-border:1px solid #444;
  --hn-box-border:1.6px solid #222;
  --hn-box-tint-bg:#444;
  --hn-box-tint-shadow:rgba(0, 0, 0, 0.08) 0px 0.8px 0.8px 0px, rgba(0, 0, 0, 0.04) 0px 3.2px 6.4px 0px;
  --hn-box-tint-border:1px solid #454545;  
  
}
/*页面基础*/
html {
  scroll-behavior: smooth;
}
html {
  cursor:var(--hn-cursor-default);
}
html .back-to-top,
html .back-to-top i,
html a *,
html a,
html button,
html label {
  cursor:var(--hn-cursor-pointer);
}
html a:active *,
html a:active,
html button:active,
html label:active {
  cursor:var(--hn-cursor-active);
}
html[data-theme],
a:hover{
  transition: all .3s ease-in-out; 
}
*, *::before, *::after {
  box-sizing: border-box;
}
body{
  color:var(--hn-text-color);
  background: var(--hn-body-bg);
  font-size:.875rem;
  line-height: 1.4;
  font-smoothing: antialiased;
  -webkit-font-smoothing: antialiased;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial,'Noto Sans', sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol','Noto Color Emoji';
}
a{
  color:var(--hn-primary);
  text-decoration: none;
}
a:hover{
  color:var(--hn-primary-hover);
}
.underline a{
  text-decoration: none;
  border-bottom: 1px dotted rgba(0,0,0,0.0);
  padding-bottom: 1px;
  transition: all .3s ease-in-out; 
}
.underline a:hover{
  text-decoration: none;
  padding-bottom: 1px;
  border-bottom: 1px dotted var(--hn-text-secondary-color);
}
h1,h2,h3,h4,h5,h6{
  font-weight:bold;
}
h2{
  font-size:1.1rem;
}
/*全局样式*/
.ellipsis-line-1 {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis!important;
}
.page-width{
  width:var(--hn-page-width);
  margin: 0 auto;
}
.btn{
  color:var(--hn-box-bg);
  background-color: var(--hn-primary);
  height: 100%;
  padding: .5rem 1rem;
  border-radius: calc(var(--hn-border-radius) / 2);
  box-shadow:var(--hn-box-shadow-deep);
  transition: all 0.3s ease; 
}
.btn:hover{
  transform: scale(1.05);
  color:var(--hn-box-bg);
  background-color: var(--hn-primary-hover);
  box-shadow: var(--hn-box-shadow-deep),
  2px 2px 0 2px rgba(23, 23, 23, 0.06),
  -2px -2px 0 2px rgba(23, 23, 23, 0.06),
  2px -2px 0 2px rgba(23, 23, 23, 0.06),
  -2px 2px 0 2px rgba(23, 23, 23, 0.06);
}
.btn-light{
  color:var(--hn-primary);
  background-color: var(--hn-gray-bg);
  height: 100%;
  padding: .5rem 1rem;
  border-radius: calc(var(--hn-border-radius) / 2);
  box-shadow:  var(--hn-box-shadow-inset),var(--hn-box-shadow);
  transition: all 0.3s ease; 
}
.btn-light:hover{
  transform: scale(1.05);
  box-shadow: 0 0 0 1px #e0e0e0 inset,
  1px 1px 0 1px rgba(23, 23, 23, 0.06),
  -1px -1px 0 1px rgba(23, 23, 23, 0.06),
  1px -1px 0 1px rgba(23, 23, 23, 0.06),
  -1px 1px 0 1px rgba(23, 23, 23, 0.06);
}
input, button,textarea {
  border: .5px solid var(--hn-text-secondary-color);
  border-radius: calc(var(--hn-border-radius) / 2);
  outline: none;
  color:var(--hn-text-secondary-color);
}
button {
  cursor: pointer;
}
.flex{
  display: flex;
}
.space-between{
  justify-content: space-between;
}
.flex-wrap{
  flex-wrap:wrap;
}
.flex-nowrap{
  flex-wrap:nowrap;
}
.box{
  background: var(--hn-box-bg);
  border-radius: var(--hn-border-radius);
  border: var(--hn-box-border);
  box-shadow: var(--hn-box-shadow);
}
.box-tint{
  background: var(--hn-box-tint-bg);
  border: var(--hn-box-tint-border);
  box-shadow: var(--hn-box-tint-shadow);
}
.radius{
  border-radius: var(--hn-border-radius);
}
.radius-full{
  border-radius: 100rem;
}
.w-100{
  width: 100%;
}
.gray-bg{
  background: var(--hn-gray-bg);
}
.bar{
  justify-content: space-between;
  align-items: center;
}
.py-2{
  padding: 0.5rem 0!important;
}
.p-1{
  padding: 0.25rem!important;
}
.p-2{
  padding: 0.5rem!important;
}
.p-3{
  padding: 1rem!important;
}
.p-4{
  padding: 1.5rem!important;
}
.p-5{
  padding: 3rem!important;
}
.pl-1{
  padding-left: 0.25rem!important;
}
.pl-2{
  padding-left: 0.5rem!important;
}
.pl-4{
  padding-left: 1.5rem!important;
}
.pr-1{
  padding-right: 0.25rem!important;
}
.pr-2{
  padding-right: 0.5rem!important;
}
.pr-3{
  padding-right: 1rem!important;
}
.pr-4{
  padding-right: 1.5rem!important;
}
.pt-1{
  padding-top: 0.25rem!important;
}
.pt-2{
  padding-top: 0.5rem!important;
}
.pt-3{
  padding-top: 1rem!important;
}
.pb-2{
  padding-bottom: 0.5rem!important;
}
.pb-3{
  padding-bottom: 1rem!important;
}
.pb-4{
  padding-bottom: 1.5rem!important;
}
.pb-5{
  padding-bottom: 3rem!important;
}
.ml-1{
  margin-left:0.25rem!important;
}
.ml-2{
  margin-left:0.5rem!important;
}
.mr-2{
  margin-right:0.5rem!important;
}
.mr-5{
  margin-right:3rem!important;
}
.mr-3{
  margin-right:1rem!important;
}
.mt-2{
  margin-top:0.5rem!important;
}
.mt-3{
  margin-top:1rem!important;
}
.mt-4{
  margin-top:1.5rem!important;
}
.mt-5{
  margin-top:3rem!important;
}
.mb-2{
  margin-bottom:.5rem!important;
}
.mb-3{
  margin-bottom:1rem!important;
}
.mb-4{
  margin-bottom:1.5rem!important;
}
.mb-5{
  margin-bottom:3rem!important;
}
.fixed-h{
  position: sticky;
  top:.5rem;
  z-index: 9;
}
.gradient-text{
  background: linear-gradient(120deg, #409BFB, #8FA4F7, #F991BD);
  background-clip: border-box;
  -webkit-background-clip: text;
  color: transparent;
  display: inline-block;
}
.gradient-text-animation {
  background: linear-gradient(120deg, #409BFB, #8FA4F7, #FFA5CB, #9C7DE1, #5795F7);
  background-clip: border-box;
  -webkit-background-clip: text; 
  color: transparent;
  display: inline-block;
  background-size: 300% 300%;
  animation: gradient-animation 8s ease infinite;
}
@keyframes gradient-animation {
  0% {
    background-position: 0% 50%;
  }
  25% {
    background-position: 100% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  75% {
    background-position: 0% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}
.ribbon {
  position: absolute;
  top: 0;
  z-index:1;
  --f: 10px; /* 控制折叠部分*/
  font-size: .825rem;
  font-weight: bold;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
  color: var(--hn-black);
  padding: .1rem 2rem;
  background: rgba(var(--hn-success-rgb),.8);
  border-bottom :var(--f) solid rgba(var(--hn-success-rgb-hover),.3);
  clip-path: polygon(
    100% calc(100% - var(--f)),100% 100%,calc(100% - var(--f)) calc(100% - var(--f)),var(--f) calc(100% - var(--f)), 0 100%,0 calc(100% - var(--f)),999px calc(100% - var(--f) - 999px),calc(100% - 999px) calc(100% - var(--f) - 999px))
}
.ribbon.top-left {
  left: 0;
  transform: rotate(-45deg);
  transform-origin: 0% 100%;
  top: 2rem;
}
/* modal */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.2);
  /*backdrop-filter: blur(30px);*/
  transition: all .3s ease-in-out;
  justify-content: center;
  align-items: center;
  z-index: 99;
}
.modal img{
  display: inline-block;
}
.modal-content {
  min-width:10rem;
  background-color:var(--hn-white);
  padding: 1rem;
  border-radius: calc(var(--hn-border-radius) / 1.6);
  box-shadow: var(--hn-box-shadow-deep);
  text-align: center;
}
.modal-close {
  margin-top: 10px;
  padding: .3rem 1rem;
  background-color: var(--hn-primary);
  color: var(--hn-box-bg);
  border: none;
  border-radius: calc(var(--hn-border-radius) / 1.6);
  cursor: pointer;
}
/*toast*/
.toast {
  display: block;
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background-color: rgba(0, 0, 0, 0.7);
  color: var(--hn-white);
  padding: .8rem 1.5rem;
  border-radius: calc(var(--hn-border-radius) / 2);
  z-index: 13;
  transition: opacity 0.3s, transform 0.3s;
}
.toast i{
  color: rgba(var(--hn-success-rgb),1);
}