/* ============ ПЕРЕМЕННЫЕ ============ */
:root {
  --bg:        #06060a;
  --bg-alt:    #0b0b12;
  --panel:     #10101a;
  --panel-2:   #15151f;
  --border:    #1e1e2e;
  --red:       #9c0200;
  --magenta:   #ff2bd6;
  --yellow:    #ffe600;
  --text:      #d6d6e0;
  --muted:     #7c7c90;
  --danger:    #ff4d6d;

  --font-display: 'Orbitron', sans-serif;
  --font-body:    'Rajdhani', sans-serif;
  --font-mono:    'Share Tech Mono', monospace;
}

/* ============ RESET / BASE ============ */
* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.55;
  overflow-x: hidden;
  position: relative;
}

/* сетка на фоне */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    linear-gradient(rgba(156, 2, 0, 0.05) 1px, transparent 1px) 0 0 / 40px 40px,
    linear-gradient(90deg, rgba(156, 2, 0, 0.05) 1px, transparent 1px) 0 0 / 40px 40px,
    radial-gradient(ellipse at top, #0d0d18 0%, #06060a 60%);
}

/* сканлайны */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: repeating-linear-gradient(
    to bottom,
    transparent 0,
    transparent 3px,
    rgba(0, 0, 0, 0.18) 3px,
    rgba(0, 0, 0, 0.18) 4px
  );
  opacity: .6;
}

main { flex: 1; }

a { color: var(--red); text-decoration: none; transition: color .2s; }
a:hover { color: var(--yellow); }

img { max-width: 100%; display: block; }

/* ============ ХЕДЕР ============ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 16px 48px;
  background: rgba(6, 6, 10, 0.82);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.site-header::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -1px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--red), var(--magenta), transparent);
  opacity: .9;
}

.logo {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: 2px;
  color: #fff;
  text-transform: uppercase;
  position: relative;
  white-space: nowrap;
}
.logo span { color: var(--red); }
.logo:hover { color: #fff; }
.logo:hover span { color: var(--magenta); }

.main-nav {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.main-nav a {
  font-family: var(--font-display);
  font-size: .82rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--muted);
  padding: 10px 16px;
  border: 1px solid transparent;
  position: relative;
  transition: all .2s;
}
.main-nav a:hover { color: var(--red); border-color: var(--border); }
.main-nav a.active {
  color: var(--red);
  border-color: var(--red);
  box-shadow: 0 0 12px rgba(156, 2, 0, .55), inset 0 0 12px rgba(156, 2, 0, .15);
}

/* ============ КНОПКИ ============ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-display);
  font-size: .8rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  font-weight: 600;
  padding: 14px 26px;
  border: none;
  cursor: pointer;
  color: #fff;
  background: var(--red);
  clip-path: polygon(12px 0, 100% 0, 100% calc(100% - 12px), calc(100% - 12px) 100%, 0 100%, 0 12px);
  transition: all .2s;
  position: relative;
}
.btn:hover {
  background: var(--yellow);
  color: #000;
  box-shadow: 0 0 24px rgba(255, 230, 0, .55);
}
.btn--ghost {
  background: transparent;
  color: var(--red);
  border: 1px solid var(--red);
  clip-path: none;
}
.btn--ghost:hover {
  background: rgba(156, 2, 0, .25);
  color: #fff;
  box-shadow: 0 0 20px rgba(156, 2, 0, .6);
}
.btn--magenta {
  background: var(--magenta);
  color: #fff;
}
.btn--magenta:hover {
  background: var(--yellow);
  color: #000;
}

/* ============ ОБЩИЕ СЕКЦИИ ============ */
.section { padding: 80px 48px; max-width: 1400px; margin: 0 auto; }

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #fff;
  margin-bottom: 12px;
  position: relative;
  padding-left: 22px;
}
.section-title::before {
  content: "";
  position: absolute;
  left: 0; top: 50%;
  transform: translateY(-50%);
  width: 6px; height: 80%;
  background: var(--red);
  box-shadow: 0 0 14px var(--red);
}

.section-sub {
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: .95rem;
  margin-bottom: 48px;
  padding-left: 22px;
}

/* ============ HERO ============ */
.hero {
  min-height: calc(100vh - 80px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 60px 24px;
  position: relative;
}

.hero-tag {
  font-family: var(--font-mono);
  font-size: .85rem;
  letter-spacing: 4px;
  color: var(--magenta);
  margin-bottom: 24px;
  text-transform: uppercase;
}

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 7vw, 5.5rem);
  font-weight: 900;
  letter-spacing: 4px;
  text-transform: uppercase;
  line-height: 1.05;
  color: #fff;
  margin-bottom: 28px;
  position: relative;
}

/* глитч-эффект на заголовке */
.glitch { position: relative; display: inline-block; }
.glitch::before,
.glitch::after {
  content: attr(data-text);
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.glitch::before {
  color: var(--red);
  animation: glitch-1 2.6s infinite linear alternate-reverse;
}
.glitch::after {
  color: var(--magenta);
  animation: glitch-2 3.2s infinite linear alternate-reverse;
}
@keyframes glitch-1 {
  0%, 92%, 100% { transform: translate(0); opacity: 0; }
  93% { transform: translate(-3px, 2px); opacity: .9; clip-path: inset(0 0 55% 0); }
  95% { transform: translate(3px, -2px); opacity: .9; clip-path: inset(50% 0 0 0); }
  97% { transform: translate(-2px, 1px); opacity: .9; clip-path: inset(20% 0 40% 0); }
}
@keyframes glitch-2 {
  0%, 90%, 100% { transform: translate(0); opacity: 0; }
  91% { transform: translate(3px, -2px); opacity: .8; clip-path: inset(40% 0 20% 0); }
  94% { transform: translate(-3px, 2px); opacity: .8; clip-path: inset(10% 0 60% 0); }
  96% { transform: translate(2px, 1px); opacity: .8; clip-path: inset(60% 0 5% 0); }
}

.hero p.lead {
  max-width: 720px;
  font-size: 1.15rem;
  color: var(--muted);
  margin-bottom: 44px;
}

.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; }

/* ============ FEATURES (главная) ============ */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.feature {
  background: var(--panel);
  border: 1px solid var(--border);
  padding: 32px 28px;
  position: relative;
  transition: all .25s;
}
.feature::before {
  content: "";
  position: absolute;
  top: 0; left: 0;
  width: 40px; height: 2px;
  background: var(--red);
}
.feature:hover {
  border-color: var(--red);
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(156, 2, 0, .25);
}
.feature h3 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #fff;
  margin-bottom: 12px;
}
.feature p { color: var(--muted); font-size: .98rem; }

/* ============ СЕТКА ТОВАРОВ (3 в ряд) ============ */
.product-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.product-card {
  background: var(--panel);
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  transition: all .25s;
  position: relative;
  overflow: hidden;
}
.product-card::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  border: 1px solid transparent;
  transition: border-color .25s;
}
.product-card:hover {
  transform: translateY(-6px);
  border-color: var(--red);
  box-shadow: 0 16px 50px rgba(156, 2, 0, .35);
}
.product-card:hover::after { border-color: rgba(255, 43, 214, .35); }

.product-image {
  aspect-ratio: 4 / 3;
  background:
    repeating-linear-gradient(45deg,
      rgba(156, 2, 0, .06) 0 10px,
      transparent 10px 20px),
    var(--panel-2);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: .8rem;
  text-align: center;
  padding: 20px;
  position: relative;
}
.product-image img {
  width: 100%; height: 100%;
  object-fit: cover;
  position: absolute;
  inset: 0;
}

.product-body {
  padding: 24px 24px 26px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  flex: 1;
}

.product-name {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 1px;
  color: #fff;
  text-transform: uppercase;
}
.product-name small {
  display: block;
  font-family: var(--font-mono);
  font-size: .72rem;
  letter-spacing: 3px;
  color: var(--magenta);
  margin-top: 4px;
  font-weight: 400;
}

.specs {
  list-style: none;
  font-size: .92rem;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  gap: 8px;
  border-top: 1px dashed var(--border);
  border-bottom: 1px dashed var(--border);
  padding: 16px 0;
}
.specs li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}
.specs li span:first-child {
  font-family: var(--font-mono);
  font-size: .8rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}
.specs li span:last-child {
  color: var(--text);
  text-align: right;
}

.product-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
}

.price {
  font-family: var(--font-display);
  font-size: .95rem;
  letter-spacing: 1px;
  color: var(--red);
  text-transform: uppercase;
  text-shadow: 0 0 8px rgba(156, 2, 0, .8);
}

/* ============ МОДАЛКА ЗАКАЗА ============ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .8);
  backdrop-filter: blur(6px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 100;
}
.modal-overlay.open { display: flex; }

.modal {
  width: 100%;
  max-width: 480px;
  background: var(--bg-alt);
  border: 1px solid var(--red);
  padding: 36px 32px 32px;
  position: relative;
  box-shadow: 0 0 60px rgba(156, 2, 0, .55);
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 20px), calc(100% - 20px) 100%, 0 100%);
}
.modal::before {
  content: "";
  position: absolute;
  top: 0; left: 0;
  width: 60px; height: 3px;
  background: var(--magenta);
}

.modal-close {
  position: absolute;
  top: 14px; right: 18px;
  background: none;
  border: none;
  color: var(--muted);
  font-size: 1.8rem;
  cursor: pointer;
  line-height: 1;
  transition: color .2s;
}
.modal-close:hover { color: var(--red); }

.modal h2 {
  font-family: var(--font-display);
  font-size: 1.3rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #fff;
  margin-bottom: 8px;
}
.modal .modal-product {
  font-family: var(--font-mono);
  font-size: .85rem;
  color: var(--muted);
  margin-bottom: 26px;
}
.modal .modal-product span { color: var(--red); }

.order-form { display: flex; flex-direction: column; gap: 16px; }

.order-form label {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: .75rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--muted);
}
.order-form input {
  background: var(--panel);
  border: 1px solid var(--border);
  padding: 13px 16px;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1rem;
  outline: none;
  transition: all .2s;
}
.order-form input:focus {
  border-color: var(--red);
  box-shadow: 0 0 0 3px rgba(156, 2, 0, .3);
}
.order-form .btn { margin-top: 8px; }

.form-success {
  display: none;
  text-align: center;
  padding: 20px 0 10px;
  font-family: var(--font-mono);
  color: var(--red);
}
.form-success.show { display: block; }
.form-success .big {
  font-family: var(--font-display);
  font-size: 1.2rem;
  color: var(--yellow);
  margin-bottom: 10px;
}

/* ============ FOOTER ============ */
.site-footer {
  border-top: 1px solid var(--border);
  background: var(--bg-alt);
  padding: 48px 48px 24px;
  margin-top: 80px;
  position: relative;
}
.site-footer::before {
  content: "";
  position: absolute;
  top: -1px; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--magenta), var(--red), transparent);
}

.footer-inner {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 40px;
  flex-wrap: wrap;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--border);
}

.footer-brand .logo { font-size: 1.1rem; margin-bottom: 10px; }
.footer-brand p {
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: .82rem;
  max-width: 320px;
}

.footer-partners {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.partners-label {
  font-family: var(--font-mono);
  font-size: .75rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--muted);
}
.partner-logos { 
  display: flex; 
  gap: 24px; 
  flex-wrap: wrap;
}

.partner-logo {
  width: 360px;
  max-width: 100%;
  height: 160px;
  background: var(--panel);
  border: 1px dashed var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  transition: all .2s;
}
.partner-logo:hover {
  border-color: var(--red);
  box-shadow: 0 0 20px rgba(156, 2, 0, .5);
}
.partner-logo img {
  max-height: 100%;
  max-width: 100%;
  object-fit: contain;
}

.footer-copy {
  max-width: 1400px;
  margin: 22px auto 0;
  text-align: center;
  font-family: var(--font-mono);
  font-size: .78rem;
  color: var(--muted);
  letter-spacing: 1px;
}

/* ============ АДАПТИВ ============ */
@media (max-width: 1000px) {
  .site-header { padding: 14px 24px; }
  .section { padding: 60px 24px; }
  .product-grid, .features-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
  .site-header { flex-direction: column; align-items: flex-start; gap: 12px; }
  .main-nav { width: 100%; }
  .main-nav a { padding: 8px 12px; font-size: .72rem; }
  .product-grid, .features-grid { grid-template-columns: 1fr; }
  .footer-inner { flex-direction: column; }
  .modal { padding: 28px 22px; }
}