:root {
  --bg: #07090f;
  --panel: #121723;
  --panel-2: #0b111a;
  --text: #f5f7ff;
  --muted: #9ca8c4;
  --primary: #4da3ff;
  --secondary: #6ef3ff;
  --accent: #ff6b6b;
  --border: #2a354b;
}

[data-theme="competitive"] {
  --bg: #120a05;
  --panel: #24160d;
  --panel-2: #160f08;
  --text: #fff7ef;
  --muted: #e0c5ad;
  --primary: #ff9f43;
  --secondary: #ffd166;
  --accent: #ff6b6b;
  --border: #5a3a22;
}

* { box-sizing: border-box; }
html, body {
  margin: 0;
  padding: 0;
  font-family: "Segoe UI", "Trebuchet MS", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background: radial-gradient(circle at 12% 8%, #13203f, var(--bg) 46%), var(--bg);
}
body { position: relative; overflow-x: hidden; }

.bg-glow {
  position: fixed; width: 420px; height: 420px; border-radius: 50%;
  filter: blur(90px); opacity: 0.3; z-index: -1;
}
.bg-glow-1 { top: -120px; left: -120px; background: var(--primary); }
.bg-glow-2 { right: -120px; bottom: 10%; background: var(--secondary); }

.container { width: min(1120px, 92%); margin: 0 auto; }
.site-header {
  position: sticky; top: 0; z-index: 10; backdrop-filter: blur(10px);
  background: rgba(8, 12, 24, 0.75); border-bottom: 1px solid rgba(124, 77, 255, 0.2);
}
.nav { display: flex; align-items: center; justify-content: space-between; min-height: 68px; gap: 16px; }
.brand { color: var(--text); text-decoration: none; font-weight: 700; }
.brand {
  letter-spacing: 0.6px;
  text-transform: uppercase;
}
.menu { display: flex; gap: 20px; }
.top-actions { display: flex; gap: 8px; align-items: center; }
.lang-switch {
  background: rgba(10, 16, 30, 0.9);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 7px 10px;
  font-size: 13px;
}
.menu a, .links a { color: var(--muted); text-decoration: none; }
.menu a:hover, .links a:hover { color: var(--text); }

.hero { padding: 72px 0 48px; }
.hero-grid { display: grid; gap: 24px; grid-template-columns: 1.4fr 1fr; }
.eyebrow { color: var(--secondary); font-weight: 600; }
h1 { margin: 10px 0 8px; font-size: clamp(32px, 4.8vw, 52px); line-height: 1.15; }
h2 { margin: 0 0 20px; font-size: clamp(26px, 4vw, 34px); }
h3 { margin: 0 0 10px; font-size: 20px; }
.lead { color: var(--muted); max-width: 650px; font-size: 17px; line-height: 1.7; }
.hero-actions { display: flex; gap: 12px; margin-top: 24px; }

.hero-panel, .card, .machine-card, .banner {
  border: 1px solid var(--border);
  background: linear-gradient(160deg, rgba(18, 23, 35, 0.96), rgba(11, 17, 26, 0.96));
  border-radius: 18px;
  box-shadow: 0 18px 40px rgba(2, 5, 14, 0.45);
}
.hero-panel, .card, .machine-card { padding: 20px; }

.status-list { list-style: none; margin: 16px 0 0; padding: 0; }
.status-list li {
  display: flex; justify-content: space-between; align-items: center; padding: 12px 0;
  border-bottom: 1px dashed rgba(162, 175, 207, 0.2);
}
.status-list li:last-child { border-bottom: 0; }

.section { padding: 64px 0; }
.section-alt { background: rgba(9, 14, 30, 0.6); }
.luxury-scene {
  padding-top: 8px;
}
.luxury-hero {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid rgba(255, 214, 102, 0.35);
  box-shadow: 0 24px 50px rgba(5, 8, 20, 0.55);
}
.luxury-hero img {
  width: 100%;
  height: 360px;
  object-fit: cover;
  display: block;
  filter: saturate(1.2) contrast(1.08);
}
.luxury-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(6, 10, 20, 0.82), rgba(6, 10, 20, 0.2) 60%);
  display: flex;
  flex-direction: column;
  justify-content: center;
  max-width: 620px;
  padding: 28px;
}
.luxury-overlay h2 {
  margin-bottom: 10px;
}
.luxury-overlay p {
  margin: 0;
  color: #d9e4ff;
}
.luxury-grid {
  margin-top: 16px;
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.luxury-card {
  margin: 0;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 14px 30px rgba(4, 7, 18, 0.45);
}
.luxury-card img {
  width: 100%;
  height: 150px;
  object-fit: cover;
  display: block;
}
.grid { display: grid; gap: 16px; }
.grid.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.machine-card {
  transform-style: preserve-3d;
  transition: transform 0.28s ease, box-shadow 0.28s ease;
}
.machine-card:hover {
  transform: translateY(-6px) rotateX(3deg);
  box-shadow: 0 26px 46px rgba(2, 5, 14, 0.55);
}
.machine-media {
  margin: -6px -6px 14px;
  border-radius: 14px;
  overflow: hidden;
  position: relative;
  border: 1px solid rgba(255, 255, 255, 0.12);
  transform: perspective(1000px) rotateX(6deg);
  transform-origin: center top;
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.42);
}
.machine-media::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0) 38%);
  pointer-events: none;
}
.machine-media img {
  width: 100%;
  height: 170px;
  object-fit: cover;
  display: block;
  transform: scale(1.03);
  transition: transform 0.35s ease;
}
.machine-card:hover .machine-media img {
  transform: scale(1.08);
}
.machine-card .meta { color: var(--muted); margin: 0 0 14px; }

.steps {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px;
  list-style: none; margin: 0; padding: 0; counter-reset: flow;
}
.steps li {
  background: rgba(18, 26, 47, 0.8); border: 1px solid var(--border); border-radius: 14px;
  padding: 18px 18px 18px 52px; position: relative; counter-increment: flow;
}
.steps li::before {
  content: counter(flow); position: absolute; left: 16px; top: 16px;
  width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center;
  background: linear-gradient(135deg, var(--primary), var(--accent)); font-weight: 700;
}

.section-banner .banner {
  display: flex; justify-content: space-between; align-items: center; padding: 24px; gap: 18px;
}
.subtle { color: var(--muted); margin-top: 14px; }

.btn {
  display: inline-block; text-align: center; text-decoration: none; border: 0; cursor: pointer;
  color: #fff; font-weight: 700; padding: 12px 18px; border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), #6bc1ff 56%, var(--accent));
  transition: transform 0.18s ease, box-shadow 0.18s ease, opacity 0.18s ease;
  box-shadow: 0 8px 22px rgba(77, 163, 255, 0.35);
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); opacity: 0.9; }
.btn-ghost { background: transparent; border: 1px solid var(--border); box-shadow: none; }
.btn-ghost:hover {
  border-color: var(--secondary);
  color: #fff;
}
.btn-small { padding: 8px 12px; border-radius: 10px; }
.btn-block { width: 100%; margin-top: 14px; }

.tag {
  display: inline-block; padding: 4px 10px; border-radius: 999px; font-size: 12px;
  background: rgba(162, 175, 207, 0.2); color: var(--text);
}
.tag-green { background: rgba(29, 209, 161, 0.2); color: #9df7dc; }
.tag-orange { background: rgba(245, 166, 35, 0.2); color: #ffd085; }

.site-footer { border-top: 1px solid var(--border); padding: 20px 0 32px; }
.site-footer p {
  letter-spacing: 0.2px;
}
.footer-wrap { display: flex; justify-content: space-between; gap: 18px; align-items: center; }
.links { display: flex; flex-wrap: wrap; gap: 16px; }

.modal-backdrop {
  position: fixed; inset: 0; background: rgba(2, 4, 10, 0.7); display: none;
  place-items: center; z-index: 30; padding: 16px;
}
.modal-backdrop.is-open { display: grid; }
.modal {
  width: min(460px, 100%); border: 1px solid var(--border);
  background: linear-gradient(160deg, rgba(18, 26, 47, 0.98), rgba(14, 21, 40, 0.98));
  border-radius: 16px; box-shadow: 0 22px 50px rgba(2, 5, 14, 0.55);
  padding: 22px; position: relative;
}
.modal-close {
  position: absolute; right: 10px; top: 8px; border: 0; background: transparent;
  color: var(--muted); font-size: 24px; cursor: pointer;
}
.auth-form { margin-top: 12px; display: grid; gap: 12px; }
.auth-form label { display: grid; gap: 6px; color: var(--muted); font-size: 14px; }
.auth-form input {
  width: 100%; border: 1px solid var(--border); border-radius: 10px;
  background: rgba(8, 12, 24, 0.55); color: var(--text); padding: 10px 12px; outline: none;
}
.auth-form input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(124, 77, 255, 0.2); }
.inline-field { display: grid; grid-template-columns: 1fr auto; gap: 8px; }

@media (max-width: 980px) {
  .menu { display: none; }
  .hero-grid, .grid.four, .grid.three, .steps { grid-template-columns: 1fr; }
  .luxury-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .luxury-hero img { height: 280px; }
  .section-banner .banner, .footer-wrap { flex-direction: column; align-items: flex-start; }
  .top-actions { width: 100%; justify-content: flex-end; }
}
