:root {
  --mir-red: #E6192C;
  --carbon: #1A1A1A;
  --dark-gray: #2B2B2B;
  --mid-gray: #3D3D3D;
  --gold: #D4AF37;
  --white: #F5F5F5;
  --light-gray: #E6E6E6;
  --bright-red: #FF4D5A;
  --extreme-black: #0D0D0D;
  --bright-gold: #FFD700;
  --font-heading: Impact, "Arial Black", sans-serif;
  --font-body: "Noto Sans SC", "Helvetica Neue", sans-serif;
  --header-w: 280px;
  --max-w: 1400px;
  --transition: 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  background: linear-gradient(180deg, var(--carbon) 0%, var(--extreme-black) 100%);
  color: var(--white);
  padding-left: var(--header-w);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeSpeed;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--white);
  text-decoration: none;
}

ul {
  list-style: none;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 900;
  line-height: 1.1;
}

:focus-visible {
  outline: 3px solid var(--bright-gold);
  outline-offset: 2px;
}

.skip-link {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 9999;
  transform: translateY(-120%);
  background: var(--mir-red);
  color: var(--white);
  font-weight: 700;
  padding: 14px 28px;
  clip-path: polygon(0 0, 100% 0, calc(100% - 12px) 100%, 0 100%);
  transition: transform 0.2s;
}

.skip-link:focus-visible {
  transform: translateY(0);
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: var(--header-w);
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, var(--carbon) 0%, var(--extreme-black) 100%);
  border-right: 1px solid var(--mid-gray);
  z-index: 100;
  overflow-y: auto;
  overflow-x: hidden;
}

.site-header::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, var(--mir-red) 0%, var(--mir-red) 70%, var(--gold) 70%, var(--gold) 100%);
  z-index: 1;
}

.site-header__brand {
  padding: 32px 24px 0;
}

.site-header__slogan {
  margin: 16px 24px 24px;
  padding-left: 12px;
  border-left: 2px solid var(--mir-red);
  font-size: 13px;
  line-height: 1.5;
  color: var(--light-gray);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--white);
}

.brand__badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  background: linear-gradient(135deg, var(--mir-red) 0%, var(--mir-red) 72%, var(--gold) 72%, var(--gold) 100%);
  clip-path: polygon(0 0, 100% 0, calc(100% - 8px) 100%, 0 100%);
  font-family: var(--font-heading);
  font-size: 26px;
  font-weight: 900;
  color: var(--white);
  line-height: 1;
  flex-shrink: 0;
}

.brand__text {
  display: flex;
  flex-direction: column;
}

.brand__name {
  font-family: var(--font-heading);
  font-size: 22px;
  font-weight: 900;
  color: var(--white);
  line-height: 1.2;
  letter-spacing: 1.5px;
}

.brand__sub {
  font-size: 11px;
  color: var(--gold);
  letter-spacing: 4px;
  text-transform: uppercase;
  font-weight: 700;
}

.primary-nav {
  flex: 1;
  padding: 8px 0;
}

.primary-nav__list {
  display: flex;
  flex-direction: column;
}

.primary-nav__link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 24px;
  color: var(--light-gray);
  border-left: 3px solid transparent;
  transition: background 0.25s, color 0.25s, border-color 0.25s;
  font-size: 15px;
  font-weight: 500;
}

.primary-nav__link:hover,
.primary-nav__link:focus-visible {
  color: var(--white);
  background: linear-gradient(90deg, rgba(230, 25, 44, 0.12) 0%, transparent 70%);
  border-left-color: var(--bright-red);
}

.primary-nav__link[aria-current="page"] {
  color: var(--bright-gold);
  background: linear-gradient(90deg, rgba(212, 175, 55, 0.12) 0%, transparent 80%);
  border-left-color: var(--gold);
  font-weight: 700;
}

.primary-nav__index {
  font-family: var(--font-heading);
  font-size: 13px;
  color: var(--mid-gray);
  min-width: 22px;
  letter-spacing: 1px;
  transition: color 0.25s;
}

.primary-nav__link:hover .primary-nav__index {
  color: var(--bright-red);
}

.primary-nav__link[aria-current="page"] .primary-nav__index {
  color: var(--gold);
}

.primary-nav__label {
  flex: 1;
}

.site-header__foot {
  margin-top: auto;
  padding: 16px 24px 32px;
}

.site-header__cta {
  width: 100%;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 24px;
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 700;
  line-height: 1;
  color: var(--white);
  background: var(--dark-gray);
  border: 1px solid var(--mid-gray);
  cursor: pointer;
  text-decoration: none;
  clip-path: polygon(0 0, calc(100% - 12px) 0, 100% 100%, 12px 100%);
  transition: background 0.25s, border-color 0.25s, transform 0.25s, box-shadow 0.25s;
}

.btn:hover,
.btn:focus-visible {
  background: var(--bright-red);
  border-color: var(--bright-red);
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(230, 25, 44, 0.35);
}

.btn--primary {
  background: var(--mir-red);
  border-color: var(--mir-red);
}

.btn--primary:hover,
.btn--primary:focus-visible {
  background: var(--bright-red);
  border-color: var(--bright-red);
}

.btn--ghost {
  background: transparent;
  border-color: var(--mid-gray);
  color: var(--light-gray);
}

.btn--ghost:hover,
.btn--ghost:focus-visible {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--gold);
  color: var(--gold);
  box-shadow: none;
}

.btn__label {
  position: relative;
  z-index: 1;
}

.btn__arrow {
  transition: transform 0.25s;
}

.btn:hover .btn__arrow {
  transform: translateX(4px);
}

.nav-toggle {
  display: none;
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 200;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  width: 52px;
  height: 52px;
  background: var(--mir-red);
  border: 2px solid var(--mir-red);
  cursor: pointer;
  clip-path: polygon(0 0, 100% 0, calc(100% - 10px) 100%, 0 100%);
  transition: background 0.25s, border-color 0.25s, transform 0.25s;
}

.nav-toggle:hover {
  background: var(--bright-red);
  border-color: var(--bright-red);
  transform: translateY(-2px);
}

.nav-toggle__bars {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nav-toggle__bar {
  display: block;
  width: 22px;
  height: 2px;
  background: white;
  transition: transform 0.25s, opacity 0.25s;
}

.nav-toggle__text {
  font-size: 10px;
  font-weight: 700;
  color: white;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.nav-toggle.is-active {
  background: var(--extreme-black);
  border-color: var(--gold);
}

.nav-toggle.is-active .nav-toggle__bar:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.nav-toggle.is-active .nav-toggle__bar:nth-child(2) {
  opacity: 0;
}

.nav-toggle.is-active .nav-toggle__bar:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

.site-footer {
  background: var(--extreme-black);
  border-top: 1px solid var(--mid-gray);
  position: relative;
}

.site-footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, var(--mir-red) 0%, var(--mir-red) 40%, var(--gold) 40%, var(--gold) 50%, transparent 50%);
}

.site-footer__top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1.2fr;
  gap: 48px;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 48px 32px;
}

.site-footer__slogan {
  margin-top: 16px;
  font-size: 14px;
  color: var(--light-gray);
}

.site-footer__trust {
  margin-top: 12px;
  font-size: 12px;
  line-height: 1.6;
  color: var(--mid-gray);
}

.site-footer__heading {
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 16px;
  position: relative;
  padding-bottom: 8px;
}

.site-footer__heading::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 24px;
  height: 2px;
  background: var(--mir-red);
}

.site-footer__links {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.site-footer__links a {
  color: var(--light-gray);
  font-size: 14px;
  transition: color 0.25s, padding-left 0.25s;
}

.site-footer__links a:hover,
.site-footer__links a:focus-visible {
  color: var(--bright-gold);
  padding-left: 4px;
}

.site-footer__contact-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 14px;
  color: var(--light-gray);
}

.site-footer__contact-label {
  display: inline-block;
  min-width: 32px;
  color: var(--mid-gray);
  margin-right: 8px;
  font-size: 13px;
}

.site-footer__bottom {
  border-top: 1px solid var(--mid-gray);
  padding: 16px 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  max-width: var(--max-w);
  margin: 0 auto;
  font-size: 13px;
  color: var(--mid-gray);
}

.site-footer__icp {
  color: var(--mid-gray);
}

#main-content {
  min-height: 60vh;
}

.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 32px;
}

.section {
  padding: 64px 0;
}

.section__head {
  margin-bottom: 32px;
  border-bottom: 1px solid var(--mid-gray);
  padding-bottom: 16px;
}

.section__title {
  font-family: var(--font-heading);
  font-size: clamp(2.2rem, 5vw, 4rem);
  color: var(--white);
  line-height: 1.1;
  margin-bottom: 8px;
}

.section__subtitle {
  font-size: 16px;
  color: var(--light-gray);
  max-width: 640px;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

.card-grid--2 {
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.card-grid--3 {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.card {
  background: var(--dark-gray);
  border: 1px solid var(--mid-gray);
  padding: 24px;
  transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
  position: relative;
}

.card:hover {
  border-color: var(--mir-red);
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.card__title {
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  font-family: var(--font-heading);
  color: var(--white);
  margin-bottom: 8px;
}

.card__body {
  color: var(--light-gray);
  font-size: 15px;
}

.card__meta {
  font-size: 13px;
  color: var(--mid-gray);
  margin-top: 12px;
  display: flex;
  gap: 16px;
  align-items: center;
}

.card__tag {
  background: var(--mir-red);
  color: white;
  font-size: 12px;
  font-weight: 700;
  padding: 2px 10px;
  letter-spacing: 1px;
  clip-path: polygon(0 0, 100% 0, 100% 100%, 4px 100%);
}

.card__tag--gold {
  background: var(--gold);
  color: var(--extreme-black);
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

.filter-bar__btn {
  background: var(--dark-gray);
  border: 1px solid var(--mid-gray);
  color: var(--light-gray);
  font-size: 14px;
  font-weight: 700;
  padding: 10px 20px;
  cursor: pointer;
  transition: background 0.25s, color 0.25s, border-color 0.25s;
  font-family: var(--font-body);
}

.filter-bar__btn:hover,
.filter-bar__btn:focus-visible {
  border-color: var(--mir-red);
  color: var(--white);
}

.filter-bar__btn.is-active {
  background: var(--mir-red);
  border-color: var(--mir-red);
  color: white;
}

.img-frame {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, var(--dark-gray) 0%, var(--mid-gray) 100%);
  aspect-ratio: 16 / 9;
  clip-path: polygon(0 0, calc(100% - 20px) 0, 100% calc(100% - 20px), 20px 100%);
}

.img-frame::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: repeating-linear-gradient(
    -45deg,
    transparent,
    transparent 8px,
    rgba(255, 255, 255, 0.03) 8px,
    rgba(255, 255, 255, 0.03) 16px
  );
  pointer-events: none;
}

.img-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.img-frame--tall {
  aspect-ratio: 3 / 4;
}

.img-frame--wide {
  aspect-ratio: 21 / 9;
}

.img-frame--square {
  aspect-ratio: 1 / 1;
}

.img-frame__placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  color: var(--mid-gray);
  font-family: var(--font-heading);
  font-size: 18px;
  letter-spacing: 2px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 13px;
  color: var(--mid-gray);
  margin-bottom: 24px;
  padding: 8px 0;
  border-bottom: 1px solid var(--mid-gray);
}

.breadcrumb a {
  color: var(--light-gray);
  transition: color 0.2s;
}

.breadcrumb a:hover,
.breadcrumb a:focus-visible {
  color: var(--mir-red);
}

.breadcrumb__sep {
  color: var(--mid-gray);
}

.hero-frame {
  position: relative;
  border: 1px solid var(--mid-gray);
  background: var(--dark-gray);
  padding: 32px;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 24px), calc(100% - 24px) 100%, 0 100%);
}

.hero-frame__title {
  font-size: clamp(3.5rem, 10vw, 8rem);
  font-family: var(--font-heading);
  font-weight: 900;
  line-height: 1.1;
  color: var(--white);
}

.hero-frame__index {
  position: absolute;
  top: 16px;
  right: 16px;
  font-family: var(--font-heading);
  font-size: 14px;
  color: var(--mid-gray);
  letter-spacing: 2px;
}

.legend {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  padding: 16px;
  background: var(--dark-gray);
  border: 1px solid var(--mid-gray);
  font-size: 13px;
  color: var(--light-gray);
}

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

.legend__dot {
  width: 10px;
  height: 10px;
  background: var(--mir-red);
  transform: rotate(45deg);
  flex-shrink: 0;
}

.legend__dot--gold {
  background: var(--gold);
}

.legend__dot--white {
  background: var(--white);
}

.legend__dot--outline {
  background: transparent;
  border: 2px solid var(--mir-red);
}

.grid-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
}

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

.text-gold {
  color: var(--gold);
}

.text-red {
  color: var(--mir-red);
}

.text-muted {
  color: var(--mid-gray);
}

.mt-1 {
  margin-top: 8px;
}

.mt-2 {
  margin-top: 16px;
}

.mt-3 {
  margin-top: 24px;
}

.mb-2 {
  margin-bottom: 16px;
}

.mb-3 {
  margin-bottom: 24px;
}

@media (max-width: 1023px) {
  body {
    padding-left: 0;
  }

  .site-header {
    transform: translateX(-100%);
    transition: transform 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    box-shadow: none;
  }

  .site-header[data-open] {
    transform: translateX(0);
    box-shadow: 0 0 60px rgba(0, 0, 0, 0.6);
  }

  .nav-toggle {
    display: flex;
  }

  body.nav-open::after {
    content: "";
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 90;
  }

  .site-footer__top {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 32px 20px;
  }

  .site-footer__bottom {
    padding: 16px 20px;
    flex-direction: column;
    text-align: center;
  }

  .container {
    padding: 24px 20px;
  }

  .section {
    padding: 40px 0;
  }

  .hero-frame {
    padding: 24px 16px;
  }
}

@media (max-width: 640px) {
  .site-footer__top {
    padding: 32px 16px;
    gap: 24px;
  }

  .card-grid {
    grid-template-columns: 1fr;
  }

  .filter-bar {
    gap: 6px;
  }

  .filter-bar__btn {
    padding: 8px 14px;
    font-size: 13px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }

  .site-header {
    transition: none;
  }

  .btn,
  .card,
  .primary-nav__link,
  .brand,
  .filter-bar__btn {
    transition: none;
  }
}
