.page-news{
  --news-num-size: clamp(2.75rem, 6vw, 5.25rem);
  --news-pad: clamp(1.25rem, 3vw, 2.75rem);
  --news-radius-lg: 18px;
  --news-text-muted: #55606E;
  background: var(--clr-gray-bg);
  color: var(--clr-text);
}

.news-hero{
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, var(--clr-primary-deep) 0%, var(--clr-primary-soft) 55%, var(--clr-primary) 100%);
  color: var(--clr-white);
  padding: var(--space-5) 0 var(--space-7);
}

.news-hero::before{
  content: "";
  position: absolute;
  top: -20px;
  right: -8%;
  width: 44%;
  height: 120%;
  background: var(--clr-accent);
  opacity: 0.10;
  transform: skewX(-14deg);
  border-radius: 0 0 0 60px;
  pointer-events: none;
}

.news-hero::after{
  content: "";
  position: absolute;
  left: -14%;
  bottom: -36%;
  width: 320px;
  height: 320px;
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 50%;
  pointer-events: none;
}

.news-hero__inner{
  position: relative;
  z-index: 2;
  max-width: 880px;
}

.news-hero .breadcrumbs{
  margin-bottom: var(--space-5);
}

.page-news .news-hero .breadcrumbs a,
.page-news .news-hero .breadcrumbs span{
  color: rgba(255,255,255,0.72);
}

.page-news .news-hero .breadcrumbs a:hover{
  color: var(--clr-accent-soft);
}

.page-news .news-hero .breadcrumbs [aria-current="page"]{
  color: var(--clr-white);
}

.news-hero__label{
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--fs-tiny);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--clr-accent-soft);
}

.news-hero__label::before{
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--clr-accent);
  box-shadow: 0 0 0 4px rgba(255,90,31,0.22);
}

.news-hero h1{
  margin: var(--space-3) 0 var(--space-4);
  font-family: var(--font-headline);
  font-size: var(--fs-h1);
  line-height: 1.16;
  letter-spacing: -0.01em;
  font-weight: 900;
}

.news-hero__desc{
  color: rgba(255,255,255,0.78);
  font-size: clamp(1rem, 1.6vw, 1.125rem);
  line-height: 1.75;
  max-width: 46em;
}

.hero-ticker{
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3) var(--space-6);
  margin-top: var(--space-6);
  padding-top: var(--space-4);
  border-top: 1px solid rgba(255,255,255,0.16);
  font-size: var(--fs-tiny);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255,255,255,0.6);
}

.hero-ticker__val{
  margin-left: var(--space-2);
  color: var(--clr-white);
  font-family: var(--font-data);
  font-size: var(--fs-small);
  font-weight: 700;
  letter-spacing: 0.02em;
}

.news-hero__deco{
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  width: min(340px, 26vw);
  height: auto;
  opacity: 0.38;
  -webkit-mask-image: linear-gradient(to left, black 0%, transparent 88%);
  mask-image: linear-gradient(to left, black 0%, transparent 88%);
  pointer-events: none;
  z-index: 1;
}

.page-anchors{
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-top: var(--space-5);
}

.page-anchors a{
  border: 1px solid rgba(255,255,255,0.24);
  border-radius: var(--radius-full);
  background: rgba(255,255,255,0.08);
  color: var(--clr-white);
  text-decoration: none;
  font-size: var(--fs-small);
  font-weight: 600;
  padding: var(--space-2) var(--space-4);
  transition: background 0.2s ease, border-color 0.2s ease;
}

.page-anchors a:hover{
  background: var(--clr-accent);
  border-color: var(--clr-accent);
}

.news-featured{
  position: relative;
  z-index: 3;
  margin-top: calc(var(--space-6) * -1);
  padding-bottom: var(--space-7);
}

.news-featured__card{
  display: grid;
  background: var(--clr-white);
  border: 1px solid var(--clr-gray-border);
  border-radius: var(--news-radius-lg);
  box-shadow: var(--shadow-md);
  overflow: hidden;
}

.news-featured__media{
  aspect-ratio: 4 / 3;
  background: var(--clr-gray-bg);
  min-height: 220px;
}

.news-featured__media img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.news-featured__body{
  padding: var(--space-5);
  display: grid;
  align-content: center;
  gap: var(--space-3);
}

.news-featured__tags{
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.news-featured__body h2{
  font-size: clamp(1.35rem, 2.8vw, 1.9rem);
  line-height: 1.4;
  font-weight: 900;
  font-family: var(--font-headline);
  color: var(--clr-primary);
  margin: 0;
}

.news-featured__body > p{
  color: var(--news-text-muted);
  line-height: 1.75;
  margin: 0;
}

.news-tag{
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  font-size: var(--fs-tiny);
  font-weight: 700;
  letter-spacing: 0.04em;
}

.news-tag--update{
  background: rgba(10,37,64,0.08);
  color: var(--clr-primary);
}

.news-tag--topic{
  background: var(--clr-accent-pale);
  color: var(--clr-accent);
}

.news-tag--feature{
  background: rgba(10,37,64,0.12);
  color: var(--clr-primary-soft);
}

.news-tag--time{
  background: var(--clr-gray-bg);
  color: var(--clr-text);
  font-weight: 400;
}

.news-latest{
  padding: var(--space-7) 0 var(--space-6);
}

.news-latest .section-head{
  margin-bottom: var(--space-4);
}

.filter-target{
  width: 0;
  height: 0;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}

.filter-tabs{
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-bottom: var(--space-5);
}

.filter-tab{
  border: 1px solid var(--clr-gray-border);
  border-radius: var(--radius-full);
  background: var(--clr-white);
  color: var(--clr-text);
  font-size: var(--fs-small);
  font-weight: 600;
  padding: var(--space-2) var(--space-4);
  text-decoration: none;
  transition: border-color 0.2s, color 0.2s, transform 0.2s;
}

.filter-tab:hover{
  border-color: var(--clr-primary);
  color: var(--clr-primary);
  transform: translateY(-2px);
}

.news-directory{
  display: grid;
  gap: var(--space-2);
}

.news-row{
  position: relative;
  display: grid;
  gap: var(--space-3);
  padding: var(--news-pad);
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.news-row:nth-of-type(odd){
  background: var(--clr-gray-bg);
}

.news-row:nth-of-type(even){
  background: var(--clr-white);
  border-color: var(--clr-gray-border);
}

.news-row:hover{
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.news-index{
  font-family: var(--font-data);
  font-size: var(--news-num-size);
  font-weight: 700;
  line-height: 1;
  color: var(--clr-primary);
  opacity: 0.12;
  user-select: none;
}

.news-main{
  min-width: 0;
}

.news-meta{
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
}

.news-time{
  font-size: var(--fs-tiny);
  color: #8895A3;
  letter-spacing: 0.02em;
}

.news-title{
  font-family: var(--font-headline);
  font-size: clamp(1.2rem, 2.4vw, 1.55rem);
  line-height: 1.45;
  color: var(--clr-primary);
  font-weight: 900;
  margin: var(--space-1) 0;
}

.news-excerpt{
  color: var(--news-text-muted);
  line-height: 1.7;
  font-size: var(--fs-small);
  margin: 0;
}

.news-expand{
  margin-top: var(--space-2);
}

.news-expand summary{
  cursor: pointer;
  list-style: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--clr-accent);
  font-size: var(--fs-small);
  font-weight: 700;
  transition: color 0.2s;
}

.news-expand summary::-webkit-details-marker{
  display: none;
}

.news-expand summary::after{
  content: "+";
  display: inline-block;
  font-size: 1.1rem;
  line-height: 1;
  transition: transform 0.25s ease;
}

.news-expand[open] summary::after{
  transform: rotate(45deg);
}

.news-expand[open] summary{
  color: var(--clr-primary);
}

.news-expand[open] summary:hover{
  color: var(--clr-accent);
}

.news-content{
  margin-top: var(--space-4);
  padding-top: var(--space-4);
  border-top: 1px solid var(--clr-gray-border);
  display: grid;
  gap: var(--space-3);
  color: #464F5C;
  line-height: 1.75;
  font-size: var(--fs-small);
}

.news-content p{
  margin: 0;
}

.load-more{
  margin-top: var(--space-2);
  border: 1px dashed var(--clr-gray-border);
  border-radius: var(--radius-md);
  background: rgba(255,255,255,0.55);
}

.load-more summary{
  cursor: pointer;
  list-style: none;
  padding: var(--space-4);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  color: var(--clr-primary);
  font-weight: 700;
  font-size: var(--fs-small);
}

.load-more summary::-webkit-details-marker{
  display: none;
}

.load-more__icon{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--clr-accent);
  color: var(--clr-white);
  font-size: 1rem;
  line-height: 1;
  transition: transform 0.25s ease;
}

.load-more[open] .load-more__icon{
  transform: rotate(45deg);
}

.load-more__list{
  padding: var(--space-3);
  display: grid;
  gap: var(--space-3);
}

.load-more__list .news-row{
  border: 1px solid var(--clr-gray-border);
  border-radius: var(--radius-md);
}

.load-more__list .news-row:nth-of-type(odd){
  background: var(--clr-white);
}

.load-more__list .news-row:nth-of-type(even){
  background: var(--clr-gray-bg);
}

.page-news #filter-update:target ~ .news-directory > .news-row,
.page-news #filter-topic:target ~ .news-directory > .news-row,
.page-news #filter-feature:target ~ .news-directory > .news-row{
  display: none;
}

.page-news #filter-update:target ~ .news-directory > .news-row--update,
.page-news #filter-topic:target ~ .news-directory > .news-row--topic,
.page-news #filter-feature:target ~ .news-directory > .news-row--feature{
  display: grid;
}

.page-news #filter-update:target ~ .news-directory > .load-more,
.page-news #filter-topic:target ~ .news-directory > .load-more,
.page-news #filter-feature:target ~ .news-directory > .load-more{
  display: none;
}

.page-news #filter-all:target ~ .news-directory > .news-row{
  display: grid;
}

.page-news #filter-all:target ~ .news-directory > .load-more{
  display: block;
}

.news-changelog{
  position: relative;
  background: linear-gradient(135deg, var(--clr-primary) 0%, var(--clr-primary-deep) 100%);
  color: var(--clr-white);
  padding: var(--space-7) 0;
  overflow: hidden;
}

.news-changelog::before{
  content: "";
  position: absolute;
  top: -60px;
  right: -40px;
  width: 240px;
  height: 240px;
  background: var(--clr-accent);
  opacity: 0.08;
  transform: rotate(24deg);
  border-radius: 24px;
}

.page-news .news-changelog .section-head h2{
  color: var(--clr-white);
}

.page-news .news-changelog .section-label{
  color: var(--clr-accent-soft);
}

.changelog-layout{
  display: grid;
  gap: var(--space-6);
}

.changelog-list{
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: var(--space-1);
  position: relative;
}

.changelog-list::before{
  content: "";
  position: absolute;
  left: 13px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: rgba(255,255,255,0.16);
}

.changelog-list li{
  position: relative;
  padding: var(--space-3) 0 var(--space-3) calc(28px + var(--space-4));
}

.changelog-list li::before{
  content: "";
  position: absolute;
  left: 8px;
  top: 1.5rem;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--clr-accent);
  border: 2px solid var(--clr-primary);
  box-shadow: 0 0 0 3px rgba(255,90,31,0.25);
}

.changelog-version{
  display: inline-block;
  padding: 3px 12px;
  border-radius: var(--radius-full);
  background: rgba(255,255,255,0.1);
  color: var(--clr-accent-soft);
  font-family: var(--font-data);
  font-size: var(--fs-tiny);
  font-weight: 700;
  margin-bottom: var(--space-2);
  letter-spacing: 0.04em;
}

.changelog-body h3{
  margin: 0 0 var(--space-1);
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  font-family: var(--font-headline);
  font-weight: 800;
  color: var(--clr-white);
}

.changelog-body p{
  margin: 0;
  color: rgba(255,255,255,0.68);
  line-height: 1.6;
  font-size: var(--fs-small);
}

.changelog-aside img{
  width: 100%;
  height: auto;
  border-radius: var(--radius-md);
  display: block;
}

.changelog-note{
  margin-top: var(--space-4);
  border-left: 3px solid var(--clr-accent);
  padding-left: var(--space-4);
  color: rgba(255,255,255,0.78);
  font-size: var(--fs-small);
  line-height: 1.7;
}

.news-topics{
  background: var(--clr-white);
  padding: var(--space-7) 0 var(--space-6);
}

.topic-intro{
  color: var(--news-text-muted);
  max-width: 640px;
  line-height: 1.7;
  margin: var(--space-2) 0 var(--space-5);
}

.topics-grid{
  display: grid;
  gap: var(--space-4);
}

.topic-card{
  position: relative;
  border: 1px solid var(--clr-gray-border);
  border-top: 4px solid var(--clr-accent);
  border-radius: var(--radius-md);
  background: var(--clr-gray-bg);
  padding: var(--space-5);
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.topic-card:hover{
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.topic-card__count{
  position: absolute;
  right: var(--space-4);
  top: var(--space-3);
  font-family: var(--font-data);
  font-size: 2.75rem;
  font-weight: 700;
  line-height: 1;
  color: var(--clr-primary);
  opacity: 0.1;
  user-select: none;
}

.topic-card h3{
  font-size: 1.15rem;
  line-height: 1.5;
  margin: var(--space-3) 0 var(--space-2);
  color: var(--clr-primary);
  font-family: var(--font-headline);
  font-weight: 800;
  position: relative;
}

.topic-card p{
  margin: 0;
  color: var(--news-text-muted);
  line-height: 1.7;
  font-size: var(--fs-small);
  position: relative;
}

.news-texture{
  display: block;
  width: 100%;
  height: auto;
  max-width: 100%;
  object-fit: cover;
}

.news-cta{
  padding: var(--space-6) 0 var(--space-7);
  background: var(--clr-gray-bg);
}

.news-cta .content-container{
  display: grid;
  gap: var(--space-4);
  justify-items: center;
  text-align: center;
}

.news-cta p{
  font-family: var(--font-headline);
  font-size: clamp(1.2rem, 2.5vw, 1.6rem);
  font-weight: 800;
  color: var(--clr-primary);
  margin: 0;
}

.news-cta__links{
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  justify-content: center;
}

@media (min-width: 768px){
  .news-featured__card{
    grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  }

  .news-featured__media{
    aspect-ratio: auto;
    height: 100%;
    min-height: 320px;
  }

  .news-featured__body{
    padding: var(--space-6);
  }

  .news-row{
    grid-template-columns: minmax(0, 1fr) minmax(0, 6fr);
    gap: var(--space-5);
  }

  .news-index{
    opacity: 0.15;
  }

  .changelog-layout{
    grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
    align-items: center;
  }

  .topics-grid{
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px){
  .news-hero{
    padding: var(--space-6) 0 var(--space-8);
  }

  .news-hero__inner{
    max-width: 960px;
  }

  .topics-grid{
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 700px){
  .news-hero__deco{
    display: none;
  }
}
