:root {
  color-scheme: dark;
  --bg: #070b12;
  --panel: #101722;
  --panel-2: #151d2b;
  --text: #f5f1e8;
  --muted: #aeb9ce;
  --line: rgba(255, 255, 255, 0.11);
  --gold: #e3c47c;
  --cyan: #48c7d8;
  --green: #8ccf9f;
  --red: #d57766;
  --max: 1180px;
  --font-ui: Bahnschrift, "Segoe UI", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-family: var(--font-ui);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: inherit;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }

.hd-icon {
  width: 22px;
  height: 22px;
  flex: 0 0 auto;
  color: var(--gold);
  filter: drop-shadow(0 0 10px rgba(227, 196, 124, 0.24));
}

.topbar {
  position: fixed;
  z-index: 50;
  inset: 0 0 auto;
  min-height: 72px;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 12px clamp(16px, 4vw, 56px);
  border-bottom: 1px solid var(--line);
  background: rgba(7, 11, 18, 0.9);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.brand img {
  height: 42px;
  width: auto;
  max-width: 132px;
  object-fit: contain;
  border: 1px solid rgba(227, 196, 124, 0.24);
  border-radius: 8px;
  background: rgba(7, 11, 18, 0.54);
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-left: auto;
}

.nav a,
.lang-toggle,
.filter-button,
.tag {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 8px 10px;
  color: var(--muted);
  background: rgba(16, 23, 34, 0.72);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.nav a .hd-icon {
  width: 18px;
  height: 18px;
}

.nav a:hover,
.nav a.is-active,
.lang-toggle:hover,
.filter-button:hover,
.filter-button.active {
  color: var(--gold);
  border-color: rgba(227, 196, 124, 0.5);
}

.lang-toggle,
.filter-button {
  cursor: pointer;
}

main {
  min-height: 100vh;
}

.hero {
  position: relative;
  min-height: 92vh;
  display: grid;
  align-items: end;
  padding: 120px clamp(18px, 5vw, 72px) 58px;
  overflow: hidden;
}

.hero-bg,
.hero-shade {
  position: absolute;
  inset: 0;
}

.hero-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-shade {
  background:
    linear-gradient(90deg, rgba(7, 11, 18, 0.96) 0%, rgba(7, 11, 18, 0.76) 48%, rgba(7, 11, 18, 0.52) 100%),
    linear-gradient(0deg, var(--bg) 0%, rgba(7, 11, 18, 0) 34%);
}

.hero-copy {
  position: relative;
  z-index: 2;
  max-width: 980px;
}

.kicker {
  margin: 0 0 10px;
  color: var(--gold);
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
}

h1, h2, h3, p {
  margin-top: 0;
}

h1 {
  margin-bottom: 18px;
  max-width: 940px;
  font-size: clamp(48px, 8vw, 104px);
  line-height: 0.9;
}

h2 {
  margin-bottom: 14px;
  font-size: clamp(34px, 5vw, 66px);
  line-height: 0.95;
}

h3 {
  margin-bottom: 8px;
  font-size: 22px;
}

.hero-copy > p:not(.kicker),
.section-copy > p:not(.kicker) {
  max-width: 760px;
  color: var(--muted);
  font-size: 20px;
  line-height: 1.55;
}

.hero-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 180px));
  gap: 12px;
  margin-top: 34px;
}

.hero-metrics article {
  min-height: 112px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(16, 23, 34, 0.78);
}

.hero-metrics strong {
  display: block;
  margin-bottom: 8px;
  color: var(--text);
  font-size: 42px;
  line-height: 1;
}

.hero-metrics span,
.release-meta,
.release-summary,
.note-body,
.footer p,
.channel-grid span,
.quality-grid p {
  color: var(--muted);
  line-height: 1.55;
}

.latest-section,
.controls-section,
.quality-section,
.known-section,
.channels-section {
  width: min(var(--max), calc(100% - 32px));
  margin: 0 auto;
  padding: 72px 0;
}

.latest-section {
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(0, 1.18fr);
  gap: 28px;
  align-items: start;
}

.release-card,
.quality-grid article,
.channel-grid a {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(21, 29, 43, 0.92), rgba(16, 23, 34, 0.92));
}

.release-card {
  padding: 22px;
  position: relative;
  overflow: hidden;
}

.release-card.featured {
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.35);
}

.release-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.release-version {
  font-size: 42px;
  line-height: 1;
  font-weight: 900;
}

.release-title {
  margin: 6px 0 10px;
}

.release-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 13px;
  font-weight: 800;
}

.status-pill {
  color: var(--green);
  border-color: rgba(140, 207, 159, 0.4);
}

.status-beta {
  color: var(--cyan);
  border-color: rgba(72, 199, 216, 0.4);
}

.status-internal {
  color: var(--gold);
  border-color: rgba(227, 196, 124, 0.4);
}

.release-summary {
  font-size: 17px;
}

.note-grid {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.note {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 12px;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(7, 11, 18, 0.36);
}

.note img {
  width: 24px;
  height: 24px;
}

.note strong {
  display: block;
  margin-bottom: 4px;
}

.note-body {
  margin: 0;
}

.controls-section {
  border-top: 1px solid var(--line);
}

.toolbox {
  display: grid;
  grid-template-columns: minmax(260px, 360px) minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  margin: 24px 0;
}

.search-box {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(16, 23, 34, 0.8);
}

.search-box input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  color: var(--text);
  background: transparent;
}

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.release-list {
  display: grid;
  gap: 16px;
}

.release-list .release-card {
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  gap: 22px;
}

.release-side {
  border-right: 1px solid var(--line);
  padding-right: 20px;
}

.empty-state {
  padding: 28px;
  border: 1px dashed rgba(227, 196, 124, 0.35);
  border-radius: 8px;
  color: var(--muted);
}

.quality-section {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: 28px;
  border-top: 1px solid var(--line);
}

.known-section {
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(0, 1.18fr);
  gap: 28px;
  border-top: 1px solid var(--line);
}

.quality-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.known-grid {
  display: grid;
  gap: 12px;
}

.quality-grid article,
.channel-grid a,
.known-card {
  padding: 18px;
}

.known-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(21, 29, 43, 0.92), rgba(16, 23, 34, 0.92));
}

.known-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 10px;
}

.known-head h3 {
  margin: 0;
}

.known-card p {
  margin-bottom: 14px;
  color: var(--muted);
  line-height: 1.55;
}

.known-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.known-meta span {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 9px;
  color: var(--muted);
  background: rgba(7, 11, 18, 0.38);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.known-meta span:first-child {
  color: var(--gold);
  border-color: rgba(227, 196, 124, 0.36);
}

.channel-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 24px;
}

.channel-grid a {
  display: grid;
  gap: 10px;
  min-height: 168px;
}

.channel-grid a:hover {
  border-color: rgba(227, 196, 124, 0.5);
}

.footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 28px clamp(18px, 5vw, 72px);
  border-top: 1px solid var(--line);
  background: #05080d;
}

.footer img {
  width: 180px;
  height: auto;
  object-fit: contain;
}

.footer p {
  margin: 0;
  max-width: 560px;
  text-align: right;
}

.is-hidden {
  display: none !important;
}

@media (max-width: 980px) {
  .topbar {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .nav {
    order: 3;
    width: 100%;
    margin-left: 0;
    overflow-x: auto;
    flex-wrap: nowrap;
    padding-bottom: 2px;
  }

  .nav a {
    white-space: nowrap;
  }

  .hero {
    min-height: 86vh;
    padding-top: 150px;
  }

  .latest-section,
  .quality-section,
  .known-section,
  .release-list .release-card {
    grid-template-columns: 1fr;
  }

  .release-side {
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding-right: 0;
    padding-bottom: 16px;
  }

  .quality-grid,
  .channel-grid,
  .toolbox,
  .hero-metrics {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  .topbar {
    padding: 10px 12px;
  }

  .brand img {
    height: 34px;
  }

  .brand span {
    font-size: 14px;
  }

  .nav a span {
    font-size: 11px;
  }

  .hero {
    min-height: 82vh;
    padding: 150px 16px 44px;
  }

  .hero-copy > p:not(.kicker),
  .section-copy > p:not(.kicker) {
    font-size: 17px;
  }

  .latest-section,
  .controls-section,
  .quality-section,
  .known-section,
  .channels-section {
    width: min(100% - 24px, var(--max));
    padding: 48px 0;
  }

  .release-head,
  .footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .footer p {
    text-align: left;
  }
}

/* HD icon color normalization: keep SVG img icons visible on dark premium surfaces. */
img[src*="assets/icons/"],
img[src*="/assets/icons/"] {
  filter: brightness(0) saturate(100%) invert(82%) sepia(29%) saturate(606%) hue-rotate(2deg) brightness(92%) contrast(91%) drop-shadow(0 0 10px rgba(227, 196, 124, 0.28));
}

a:hover img[src*="assets/icons/"],
a:hover img[src*="/assets/icons/"],
button:hover img[src*="assets/icons/"],
button:hover img[src*="/assets/icons/"] {
  filter: brightness(0) saturate(100%) invert(75%) sepia(93%) saturate(473%) hue-rotate(150deg) brightness(91%) contrast(86%) drop-shadow(0 0 10px rgba(72, 199, 216, 0.28));
}
