/* Reset & Variables */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: 'Noto Sans SC', 'SF Pro Display', system-ui, sans-serif;
  font-size: 1rem; line-height: 1.6;
  background-color: #0D0D0D; color: #FFFFFF;
  min-height: 100vh;
}

:root {
  --color-bg-dark: #0D0D0D;
  --color-card: #F5E6CC;
  --color-accent: #FF4500;
  --color-gold: #FFD700;
  --color-nav: #2A2A2A;
  --color-text: #FFFFFF;
  --color-text-soft: #A0A0A0;
  --color-danger: #8B0000;
  --font-heading: 'Orbitron', 'Titillium Web', sans-serif;
  --font-body: 'Noto Sans SC', system-ui, sans-serif;
  --content-width: 960px;
  --gap-section: 4rem;
  --gap-paragraph: 1.5rem;
}

/* Skip Link */
.skip-link {
  position: absolute; top: -9999px; left: 0;
  z-index: 9999; padding: 0.5rem 1rem; background: var(--color-accent); color: #FFF;
  font-weight: 700; text-decoration: none; border-radius: 0 0 4px 0;
}
.skip-link:focus { top: 0; }

/* Header */
.header {
  background: var(--color-nav); border-bottom: 2px solid var(--color-accent);
  position: sticky; top: 0; z-index: 1000;
}
.header__inner {
  display: flex; align-items: center; justify-content: space-between;
  max-width: var(--content-width); margin: 0 auto; padding: 0.75rem 1rem;
}
.brand {
  display: flex; align-items: center; gap: 0.5rem;
  text-decoration: none; color: var(--color-text);
}
.brand__text { font-family: var(--font-heading); font-weight: 900; font-size: 1.5rem; letter-spacing: 0.05em; }
.brand__icon { width: 2rem; height: 2rem; filter: drop-shadow(0 0 4px rgba(255,69,0,0.6)); }

.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 0.5rem; }
.nav-toggle__bar {
  display: block; width: 24px; height: 2px; background: var(--color-text);
  margin: 5px 0; transition: transform 0.3s ease;
}
.nav__list { display: flex; list-style: none; gap: 1.5rem; }
.nav__link {
  position: relative; display: inline-block;
  font-family: var(--font-heading); font-weight: 500; font-size: 0.875rem;
  text-transform: uppercase; text-decoration: none; color: var(--color-text-soft);
  padding: 0.25rem 0; transition: color 0.3s;
}
.nav__link::after {
  content: ''; position: absolute; bottom: -4px; left: 50%; transform: translateX(-50%) scale(0);
  width: 120%; height: 120%; background: conic-gradient(from 45deg, #FF4500, #FFD700, transparent 60%);
  border-radius: 50%; opacity: 0; transition: transform 0.4s cubic-bezier(0.25,0.1,0.25,1), opacity 0.4s;
  pointer-events: none;
}
.nav__link:hover, .nav__link:focus-visible { color: var(--color-accent); }
.nav__link:hover::after, .nav__link:focus-visible::after {
  transform: translateX(-50%) scale(1); opacity: 0.35;
}
.nav__link[aria-current="page"] { color: var(--color-gold); border-bottom: 2px solid var(--color-gold); }
.nav__link[aria-current="page"]::after { display: none; }

/* Footer */
.footer {
  background: var(--color-nav); border-top: 2px solid var(--color-accent);
  padding: 2rem 1rem; margin-top: var(--gap-section);
}
.footer__inner {
  max-width: var(--content-width); margin: 0 auto;
  display: flex; flex-direction: column; gap: 1rem; text-align: center;
}
.footer__brand .brand__text { font-size: 1.25rem; color: var(--color-gold); }
.footer__contact p { font-size: 0.875rem; color: var(--color-text-soft); }
.footer__contact a { color: var(--color-accent); }
.footer__links { list-style: none; display: flex; justify-content: center; gap: 2rem; }
.footer__links a { color: var(--color-text-soft); text-decoration: none; }
.footer__links a:hover { color: var(--color-gold); }
.footer__meta { font-size: 0.75rem; color: var(--color-text-soft); line-height: 1.8; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 0.625rem 1.5rem; border: 2px solid transparent; border-radius: 4px;
  font-family: var(--font-heading); font-weight: 700; font-size: 0.875rem;
  text-transform: uppercase; cursor: pointer; transition: all 0.3s ease;
  text-decoration: none;
}
.btn-primary { background: var(--color-accent); color: #FFF; border-color: var(--color-accent); }
.btn-primary:hover { background: #CC3700; border-color: #CC3700; }
.btn-outline { background: transparent; color: var(--color-accent); border-color: var(--color-accent); }
.btn-outline:hover { background: var(--color-accent); color: #FFF; }

/* Cards */
.card {
  background: var(--color-card); color: #1A1A1A; border-radius: 8px;
  padding: 1.5rem; background-image:
    linear-gradient(0deg, rgba(0,0,0,0.03) 0px, transparent 1px, transparent 4px);
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.card--hover:hover { transform: translateY(-4px); box-shadow: 0 8px 20px rgba(255,69,0,0.15); }

/* Section */
.section { padding: var(--gap-section) 1rem; }
.section__inner { max-width: var(--content-width); margin: 0 auto; }
.section-number {
  font-family: var(--font-heading); font-weight: 900; font-size: 4rem;
  color: var(--color-accent); opacity: 0.3; line-height: 1;
  margin-bottom: 0.25rem;
}
.section-title {
  font-family: var(--font-heading); font-weight: 700; font-size: 2.25rem;
  color: var(--color-text); margin-bottom: 1rem;
}

/* Label Tag */
.label-tag {
  display: inline-block; padding: 0.125rem 0.5rem; border: 2px solid var(--color-gold);
  background: transparent; color: var(--color-gold); font-size: 0.75rem;
  font-family: var(--font-heading); text-transform: uppercase; letter-spacing: 0.1em;
}

/* Meta Info (vertical text) */
.meta-info {
  writing-mode: vertical-rl; font-size: 0.75rem; color: var(--color-text-soft);
  text-orientation: mixed;
}

/* Filter bar */
.filter-bar {
  display: flex; flex-wrap: wrap; gap: 0.75rem; margin-bottom: 2rem;
}
.filter-bar .btn { font-size: 0.75rem; padding: 0.375rem 1rem; }
.filter-bar .btn.is-active { background: var(--color-accent); color: #FFF; border-color: var(--color-accent); }

/* Scroll Progress & Back to Top */
[data-scroll-progress] {
  position: fixed; top: 0; left: 0; width: 100%; height: 3px; z-index: 9999;
  background: rgba(255,255,255,0.1);
}
[data-scroll-progress] .progress-bar {
  height: 100%; background: linear-gradient(90deg, var(--color-accent), var(--color-gold));
  width: 0%; transition: width 0.1s linear;
}
[data-back-to-top] {
  position: fixed; bottom: 2rem; right: 2rem; z-index: 999;
  width: 48px; height: 48px; border-radius: 50%; background: var(--color-accent);
  color: #FFF; border: none; font-size: 1.5rem; cursor: pointer;
  opacity: 0; transform: translateY(20px); transition: opacity 0.3s, transform 0.3s;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}
[data-back-to-top].is-visible { opacity: 1; transform: translateY(0); }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
  html { scroll-behavior: auto; }
  .card--hover:hover { transform: none; }
}

/* Focus visible */
:focus-visible { outline: 2px solid var(--color-gold); outline-offset: 2px; }

/* Responsive */
@media (max-width: 768px) {
  .nav-toggle { display: block; }
  .nav { display: none; width: 100%; }
  .nav[data-open] { display: block; }
  .nav[data-open] .nav__list {
    flex-direction: column; align-items: center; gap: 1rem; padding: 1rem 0;
  }
  .header__inner { flex-wrap: wrap; }
  .brand { order: 1; }
  .nav-toggle { order: 2; }
  .nav { order: 3; }
  .section-number { font-size: 3rem; }
  .section-title { font-size: 1.75rem; }
  .footer__links { flex-direction: column; gap: 0.5rem; }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .section-number { font-size: 3.5rem; }
  .nav__list { gap: 1rem; }
}

/* Container utility */
.container { max-width: var(--content-width); margin: 0 auto; padding: 0 1rem; }

/* Text utilities */
.text-soft { color: var(--color-text-soft); }
.text-accent { color: var(--color-accent); }
.text-gold { color: var(--color-gold); }
