:root {
  --bg: #0d1117;
  --bg-alt: #11161f;
  --surface: #161c27;
  --surface-2: #1c2432;
  --border: rgba(255, 255, 255, 0.08);
  --text: #e8edf4;
  --muted: #93a1b5;
  --heat: #ff6b35;
  --water: #38bdf8;
  --power: #fbbf24;
  --accent: var(--heat);
  --radius: 16px;
  --container: 1160px;
  --header-h: 72px;
}

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

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }

body {
  font-family: "Inter", system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img, svg { display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: none; background: none; color: inherit; }

.container {
  width: min(100% - 40px, var(--container));
  margin-inline: auto;
}

.accent { color: var(--heat); }

/* ---------- Header ---------- */
.header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  background: rgba(13, 17, 23, 0.8);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s, background 0.3s;
}
.header.is-scrolled {
  border-bottom-color: var(--border);
  background: rgba(13, 17, 23, 0.92);
}
.header__inner {
  display: flex;
  align-items: center;
  gap: 24px;
  width: min(100% - 40px, var(--container));
}

.logo { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.15rem; }
.logo__icon { font-size: 1.4rem; }
.logo__text b { color: var(--heat); }
.logo--sm { font-size: 1rem; }

.nav { display: flex; gap: 28px; margin-left: auto; }
.nav__link {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--muted);
  transition: color 0.2s;
}
.nav__link:hover { color: var(--text); }

.burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  margin-left: auto;
}
.burger span {
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.3s, opacity 0.3s;
}
.burger.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger.is-open span:nth-child(2) { opacity: 0; }
.burger.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 20px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 0.95rem;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
}
.btn--lg { padding: 14px 26px; font-size: 1rem; }
.btn--primary {
  background: linear-gradient(135deg, var(--heat), #e0481a);
  color: #fff;
  box-shadow: 0 8px 24px rgba(255, 107, 53, 0.35);
}
.btn--primary:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(255, 107, 53, 0.45); }
.btn--ghost {
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
}
.btn--ghost:hover { background: rgba(255, 255, 255, 0.07); transform: translateY(-2px); }
.header__cta { margin-left: 8px; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: calc(var(--header-h) + 72px) 0 96px;
  overflow: hidden;
}
.hero__glow {
  position: absolute;
  top: -180px;
  right: -120px;
  width: 640px;
  height: 640px;
  background: radial-gradient(circle, rgba(255, 107, 53, 0.22), transparent 65%);
  pointer-events: none;
}
.hero__inner {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 56px;
  align-items: center;
}
.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  font-size: 0.85rem;
  color: var(--muted);
  margin-bottom: 24px;
}
.dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #34d399;
  box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.6);
  animation: pulse 2s infinite;
}
@keyframes pulse {
  70% { box-shadow: 0 0 0 8px rgba(52, 211, 153, 0); }
  100% { box-shadow: 0 0 0 0 rgba(52, 211, 153, 0); }
}
.hero__title {
  font-size: clamp(2.1rem, 4.6vw, 3.4rem);
  line-height: 1.12;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
}
.hero__subtitle {
  color: var(--muted);
  font-size: 1.08rem;
  max-width: 52ch;
  margin-bottom: 32px;
}
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 44px; }
.hero__stats { display: flex; gap: 40px; flex-wrap: wrap; }
.stat { display: flex; flex-direction: column; }
.stat__num, .stat__suffix {
  font-family: "JetBrains Mono", monospace;
  font-size: 1.9rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.2;
}
.stat__suffix { display: inline; color: var(--heat); }
.stat__label { font-size: 0.88rem; color: var(--muted); }

/* Hero device card */
.hero__card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 22px;
  padding: 28px;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.4);
}
.hero__card-glow {
  position: absolute;
  inset: auto -30% -40% -30%;
  height: 200px;
  background: radial-gradient(circle, rgba(255, 107, 53, 0.25), transparent 70%);
  pointer-events: none;
}
.device {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 20px;
}
.device__head { display: flex; align-items: center; gap: 10px; margin-bottom: 18px; }
.device__led {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--heat);
  box-shadow: 0 0 12px var(--heat);
}
.device__name {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  color: var(--muted);
}
.device__circuit { display: flex; flex-direction: column; gap: 12px; margin-bottom: 18px; }
.circuit-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 0.92rem;
}
.circuit-row i {
  width: 10px; height: 10px;
  border-radius: 3px;
  flex-shrink: 0;
}
.c-heat { background: var(--heat); box-shadow: 0 0 10px var(--heat); }
.c-water { background: var(--water); box-shadow: 0 0 10px var(--water); }
.c-power { background: var(--power); box-shadow: 0 0 10px var(--power); }
.device__bar {
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  overflow: hidden;
  margin-bottom: 16px;
}
.device__bar i {
  display: block;
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--heat), var(--power));
  animation: fill 2.2s ease-out forwards;
}
@keyframes fill { to { width: 86%; } }
.device__foot {
  display: flex;
  justify-content: space-between;
  font-size: 0.82rem;
  color: var(--muted);
}
.device__power { color: var(--heat); font-weight: 700; font-family: "JetBrains Mono", monospace; }
.hero__card-caption {
  margin-top: 16px;
  text-align: center;
  font-size: 0.88rem;
  color: var(--muted);
}

/* ---------- Sections ---------- */
.section { padding: 96px 0; }
.section--alt { background: var(--bg-alt); }
.section__head { max-width: 620px; margin-bottom: 44px; }
.section__title {
  font-size: clamp(1.7rem, 3.2vw, 2.4rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}
.section__desc { color: var(--muted); font-size: 1.05rem; }

/* ---------- Videos ---------- */
.videos {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 28px;
  align-items: start;
}
.player {
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  background: #000;
}
.player iframe { width: 100%; height: 100%; border: 0; }
.player--link { display: block; position: relative; }
.player__poster {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  background:
    radial-gradient(circle at 30% 20%, rgba(255, 107, 53, 0.35), transparent 55%),
    radial-gradient(circle at 80% 80%, rgba(56, 189, 248, 0.25), transparent 50%),
    var(--surface);
  transition: transform 0.3s;
}
.player--link:hover .player__poster { transform: scale(1.02); }
.player__play {
  width: 76px; height: 76px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--heat);
  color: #fff;
  font-size: 1.6rem;
  padding-left: 5px;
  box-shadow: 0 12px 40px rgba(255, 107, 53, 0.5);
}
.player__tag {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.videos__title { margin-top: 18px; font-size: 1.25rem; }
.videos__meta { color: var(--muted); font-size: 0.92rem; margin-top: 4px; }

.videos__list { display: flex; flex-direction: column; gap: 14px; }
.vcard {
  display: flex;
  gap: 14px;
  padding: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  transition: transform 0.2s, border-color 0.2s;
}
.vcard:hover { transform: translateX(4px); border-color: rgba(255, 107, 53, 0.4); }
.vcard__thumb {
  width: 110px;
  aspect-ratio: 16 / 10;
  border-radius: 10px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  position: relative;
}
.vcard__thumb--heat { background: linear-gradient(135deg, #7c2d12, #ff6b35); }
.vcard__thumb--water { background: linear-gradient(135deg, #0c4a6e, #38bdf8); }
.vcard__thumb--power { background: linear-gradient(135deg, #78350f, #fbbf24); }
.vcard__play {
  width: 32px; height: 32px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.45);
  font-size: 0.75rem;
  padding-left: 2px;
}
.vcard__body h4 { font-size: 0.98rem; line-height: 1.35; margin-bottom: 4px; }
.vcard__body span { font-size: 0.8rem; color: var(--muted); }

/* ---------- Filters + grid ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 32px; }
.filter {
  padding: 9px 18px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.2s;
}
.filter:hover { color: var(--text); border-color: rgba(255, 255, 255, 0.2); }
.filter.is-active {
  background: var(--heat);
  border-color: var(--heat);
  color: #fff;
}

.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  display: flex;
  flex-direction: column;
  transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
}
.card:hover {
  transform: translateY(-5px);
  border-color: rgba(255, 107, 53, 0.35);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
}
.card.is-hidden { display: none; }
.card__top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.card__cat {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 5px 10px;
  border-radius: 8px;
}
.card__cat--heat { background: rgba(255, 107, 53, 0.15); color: var(--heat); }
.card__cat--water { background: rgba(56, 189, 248, 0.15); color: var(--water); }
.card__cat--power { background: rgba(251, 191, 36, 0.15); color: var(--power); }
.card__level { font-size: 0.75rem; color: var(--muted); }
.card__level--1::before,
.card__level--2::before,
.card__level--3::before {
  content: "";
  display: inline-block;
  width: 7px; height: 7px;
  border-radius: 50%;
  margin-right: 6px;
}
.card__level--1::before { background: #34d399; }
.card__level--2::before { background: var(--power); }
.card__level--3::before { background: #f87171; }
.card__icon { font-size: 2rem; margin-bottom: 12px; }
.card__title { font-size: 1.12rem; margin-bottom: 8px; }
.card__desc { color: var(--muted); font-size: 0.92rem; flex: 1; margin-bottom: 16px; }
.card__link {
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--heat);
  transition: gap 0.2s;
}
.card__link:hover { text-decoration: underline; }

/* ---------- About ---------- */
.about {
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  gap: 48px;
  align-items: start;
}
.about__text p { color: var(--muted); margin-bottom: 16px; }
.about__list { list-style: none; margin-top: 8px; }
.about__list li {
  position: relative;
  padding-left: 28px;
  margin-bottom: 10px;
  color: var(--text);
}
.about__list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--heat);
  font-weight: 700;
}
.about__panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
}
.about__panel-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.92rem;
}
.about__panel-row span { color: var(--muted); }
.about__btn { width: 100%; justify-content: center; margin-top: 20px; }

/* ---------- Contact ---------- */
.contact { text-align: center; }
.contact .section__desc { margin-bottom: 32px; }
.contact__row {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}
.contact__item {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 280px;
  padding: 20px 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-align: left;
  transition: transform 0.2s, border-color 0.2s;
}
.contact__item:hover { transform: translateY(-3px); border-color: rgba(255, 107, 53, 0.4); }
.contact__icon {
  width: 46px; height: 46px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(255, 107, 53, 0.15);
  color: var(--heat);
  font-size: 1.1rem;
  flex-shrink: 0;
}
.contact__item b { display: block; }
.contact__item small { color: var(--muted); font-size: 0.85rem; }

/* ---------- Footer ---------- */
.footer {
  border-top: 1px solid var(--border);
  padding: 28px 0;
}
.footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 0.9rem;
}
.footer__link:hover { color: var(--heat); }

/* ---------- Reveal animation ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.is-visible { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .hero__inner, .videos, .about { grid-template-columns: 1fr; }
  .grid { grid-template-columns: repeat(2, 1fr); }
  .hero { padding-top: calc(var(--header-h) + 48px); }
}

@media (max-width: 720px) {
  .nav {
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: rgba(13, 17, 23, 0.98);
    border-bottom: 1px solid var(--border);
    padding: 8px 20px 16px;
    transform: translateY(-130%);
    transition: transform 0.3s ease;
    margin-left: 0;
  }
  .nav.is-open { transform: none; }
  .nav__link { padding: 14px 4px; border-bottom: 1px solid var(--border); }
  .nav__link:last-child { border-bottom: 0; }
  .header__cta { display: none; }
  .burger { display: flex; }
  .grid { grid-template-columns: 1fr; }
  .section { padding: 72px 0; }
  .hero__stats { gap: 24px; }
  .vcard__thumb { width: 88px; }
}
