:root {
  --green: #0b6e4f;
  --green-deep: #056e2e;
  --ink: #06241b;
  --ink-soft: #0d3328;
  --paper: #f3f7f4;
  --cream: #e7f1ec;
  --card: #ffffff;
  --muted: #5b7168;
  --line: rgba(11, 110, 79, 0.16);
  --blue: #00a0ff;
  --copper: #e3742a;
  --danger: #9b2c2c;
  --shadow: 0 18px 50px rgba(6, 36, 27, 0.12);
  --font-serif: "Times New Roman", Times, Georgia, serif;
  --font-sans: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --max: 1120px;
}

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

html { scroll-behavior: smooth; overflow-y: scroll; scrollbar-gutter: stable; }

body {
  font-family: var(--font-sans);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.55;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

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

a { color: var(--green); }

a:hover { color: var(--green-deep); }

.wrap {
  width: min(var(--max), calc(100% - 2.4rem));
  margin-inline: auto;
}

.top {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.7rem 1.2rem;
  background: rgba(243, 247, 244, 0.92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  text-decoration: none;
  color: inherit;
  min-width: 0;
}

.brand img.logo {
  height: 72px;
  width: auto;
}

.top-end {
  display: flex;
  align-items: center;
  gap: 0.85rem 1.1rem;
  position: relative;
}

.lang {
  display: inline-flex;
  align-items: center;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 1px 0 rgba(6, 36, 27, 0.04);
}

.lang a {
  min-width: 2.05rem;
  text-align: center;
  text-decoration: none;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1;
  padding: 0.42rem 0.5rem;
  border-radius: 999px;
  border: 0;
}

.lang a:hover {
  color: var(--green);
}

.lang a[aria-current="true"] {
  background: var(--green);
  color: #fff;
}

.lang a[aria-current="true"]:hover {
  color: #fff;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem 1.05rem;
  align-items: center;
}

.nav a {
  text-decoration: none;
  color: var(--ink-soft);
  font-size: 0.92rem;
  padding: 0.25rem 0;
  border-bottom: 2px solid transparent;
}

.nav a:hover,
.nav a[aria-current="page"] {
  color: var(--green);
  border-bottom-color: var(--green);
}

.nav-toggle {
  display: none;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  border-radius: 8px;
  padding: 0.4rem 0.65rem;
  font: inherit;
}

.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(ellipse at 18% 20%, rgba(11, 110, 79, 0.10), transparent 42%),
    radial-gradient(ellipse at 88% 80%, rgba(0, 160, 255, 0.08), transparent 40%),
    linear-gradient(180deg, #ffffff 0%, #eef6f2 100%);
  color: var(--ink);
  padding: 3.4rem 0 3.8rem;
  border-bottom: 1px solid var(--line);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("https://scada.esp-forum.com/img/hero-collage.jpg?v=2") center / cover no-repeat;
  opacity: 0.2;
  filter: saturate(0.85);
  -webkit-mask-image: radial-gradient(ellipse 60% 70% at 50% 45%, transparent 25%, #000 85%);
  mask-image: radial-gradient(ellipse 60% 70% at 50% 45%, transparent 25%, #000 85%);
  pointer-events: none;
}

html[lang="en"] .hero::before {
  background-image: url("https://scada.esp-forum.com/img/hero-collage-en.jpg?v=2");
}

html[lang="kk"] .hero::before {
  background-image: url("https://scada.esp-forum.com/img/hero-collage-kk.jpg?v=2");
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0) 55%, #eef6f2 100%);
  pointer-events: none;
}

.hero > .wrap { position: relative; z-index: 1; }

.hero-lockup {
  display: block;
  width: min(42rem, 100%);
  margin: 0 auto 2rem;
}

.hero-copy {
  text-align: center;
  max-width: 40rem;
  margin-inline: auto;
}

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--green);
  margin: 0 0 0.85rem;
}

.led {
  width: 0.62rem;
  height: 0.62rem;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #b6ffc4, #12d040 45%, #087a28);
  box-shadow: 0 0 10px #12d040;
}

.hero h1 {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(2rem, 4.4vw, 3.1rem);
  line-height: 1.12;
  margin: 0 auto 0.9rem;
}

.hero .lead {
  font-size: 1.08rem;
  color: var(--muted);
  margin: 0 auto 1.6rem;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  justify-content: center;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  border-radius: 999px;
  padding: 0.72rem 1.25rem;
  font-weight: 600;
  border: 1px solid transparent;
}

.btn-primary {
  background: var(--green);
  color: #fff;
}

.btn-primary:hover { background: var(--green-deep); color: #fff; }

.btn-ghost {
  background: transparent;
  color: var(--green);
  border-color: var(--green);
}

.btn-ghost:hover { background: var(--cream); color: var(--ink); }

.section {
  padding: 3.4rem 0;
}

.section + .section { padding-top: 0; }

.section h2 {
  font-family: var(--font-serif);
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 400;
  margin: 0 0 1rem;
}

.section .intro {
  color: var(--muted);
  margin: -0.4rem 0 1.4rem;
}

.grid {
  display: grid;
  gap: 1rem;
}

.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 1.25rem 1.3rem 1.35rem;
  box-shadow: var(--shadow);
}

.card h3 {
  margin: 0 0 0.45rem;
  font-size: 1.05rem;
}

.card p, .card li { color: var(--muted); margin: 0; }

.shots {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
  align-items: start;
}

.shot { margin: 0; }
.shot-wide { grid-column: 1 / -1; }

.shot a {
  display: block;
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: var(--card);
}

.shot a { cursor: zoom-in; }

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3.5rem 1rem 1rem;
  background: rgba(6, 36, 27, 0.88);
  cursor: zoom-out;
}

.lightbox[hidden] { display: none; }

.lightbox img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
}

.lightbox-close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  width: 2.6rem;
  height: 2.6rem;
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
}

.lightbox-close:hover,
.lightbox-close:focus-visible { background: rgba(255, 255, 255, 0.28); }

body.lightbox-open { overflow: hidden; }

.shot figcaption {
  margin-top: 0.5rem;
  color: var(--muted);
  font-size: 0.92rem;
}

.icon-dot {
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 50%;
  background: var(--cream);
  color: var(--green);
  display: grid;
  place-items: center;
  font-weight: 700;
  margin-bottom: 0.8rem;
}

.page-head {
  background:
    linear-gradient(180deg, #e7f1ec, var(--paper));
  border-bottom: 1px solid var(--line);
  padding: 2.4rem 0 1.8rem;
}

.page-head h1 {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  margin: 0 0 0.5rem;
}

.page-head p {
  margin: 0;
  color: var(--muted);
}

.prose p { margin: 0 0 1rem; color: #2c3f38; }

.prose ol, .prose ul { padding-left: 1.2rem; color: #2c3f38; }

.prose li { margin: 0.4rem 0; }

.steps {
  counter-reset: step;
  display: grid;
  gap: 0.9rem;
}

.steps li {
  list-style: none;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 1rem 1.1rem 1rem 4.1rem;
  position: relative;
}

.steps { padding: 0; margin: 0; }

.steps li::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 1rem;
  top: 1rem;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 0.85rem;
  font-weight: 700;
}

.warn {
  background: #fff6f4;
  border: 1px solid #e7c1b6;
  border-left: 6px solid var(--copper);
  border-radius: 14px;
  padding: 1.1rem 1.2rem;
}

.warn strong {
  display: block;
  color: var(--danger);
  letter-spacing: 0.04em;
  margin-bottom: 0.35rem;
}

.spec {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid var(--line);
}

.spec th, .spec td {
  text-align: left;
  padding: 0.7rem 0.9rem;
  border-bottom: 1px solid var(--line);
  font-size: 0.95rem;
}

.spec th { width: 42%; color: var(--muted); font-weight: 600; }

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.foot {
  background: var(--ink);
  color: #c5ddd3;
  padding: 2rem 0 2.4rem;
  margin-top: auto;
}

.foot a { color: #9fe0c6; }

.foot .wrap {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.muted { color: var(--muted); }

.section-continue { padding-top: 0; }

.note-gap { margin-top: 1rem; }

.changelog {
  display: grid;
  gap: 1.1rem;
}

.release {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 1.15rem 1.25rem 1.2rem;
  box-shadow: 0 8px 24px rgba(6, 36, 27, 0.06);
}

.release h2 {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: 1.35rem;
  margin: 0 0 0.65rem;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.45rem 0.85rem;
}

.release time {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  color: var(--muted);
  font-weight: 600;
  letter-spacing: 0.02em;
}

.release ul {
  margin: 0;
  padding-left: 1.15rem;
  color: #2c3f38;
}

.release li {
  margin: 0.35rem 0;
}

.faq {
  display: grid;
  gap: 0.7rem;
}

.faq details {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0.2rem 1.1rem;
}

.faq details[open] {
  border-color: var(--green);
  padding-bottom: 0.9rem;
}

.faq summary {
  cursor: pointer;
  font-weight: 600;
  padding: 0.75rem 0;
  list-style: none;
  position: relative;
  padding-right: 1.8rem;
}

.faq summary::-webkit-details-marker { display: none; }

.faq summary::after {
  content: "+";
  position: absolute;
  right: 0;
  top: 0.62rem;
  color: var(--green);
  font-size: 1.25rem;
  line-height: 1;
}

.faq details[open] summary::after { content: "-"; }

.faq details p {
  margin: 0;
  color: #2c3f38;
}


.banner-links {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.banner-links a {
  text-decoration: none;
  color: inherit;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 1.2rem;
  min-height: 8.5rem;
  box-shadow: var(--shadow);
}

.banner-links a:hover {
  border-color: var(--green);
  color: inherit;
}

.banner-links h3 {
  margin: 0 0 0.4rem;
  color: var(--green);
}

.banner-links p { margin: 0; color: var(--muted); font-size: 0.95rem; }

@media (max-width: 860px) {
  .grid-3, .grid-2, .banner-links, .contact-grid, .shots {
    grid-template-columns: 1fr;
  }
  .nav-toggle { display: inline-flex; }
  .nav {
    display: none;
    position: absolute;
    right: 1rem;
    top: 3.6rem;
    flex-direction: column;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 0.7rem 1rem;
    box-shadow: var(--shadow);
  }
  body.nav-open .nav { display: flex; }
  .nav { top: calc(100% + 0.45rem); right: 0; }
  .brand img.logo { height: 52px; }
}

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

/* ESP-Forum banner (header, right of logo): link back to esp-forum.com */
.esp-forum-banner {
  display: flex;
  flex-direction: column;
  justify-content: center;
  height: 56px;
  margin: 0 auto 0 1.2rem;
  padding-left: 14px;
  border-left: 3px solid var(--green);
  font-family: var(--font-serif);
  font-weight: 400;
  text-align: left;
  white-space: nowrap;
  line-height: 1;
}
.esp-forum-banner,
.esp-forum-banner:hover,
.esp-forum-banner:focus,
.esp-forum-banner:active,
.esp-forum-banner span { text-decoration: none !important; }
.esp-forum-banner-title { font-size: 36px; line-height: 1; color: #00A3EB; letter-spacing: 0.078em; margin-right: -0.078em; }
.esp-forum-banner-sub { margin-top: 2px; font-size: 16px; line-height: 1; color: #000; }
.esp-forum-banner:hover .esp-forum-banner-title { color: #0086C3; }
.esp-forum-banner:hover .esp-forum-banner-sub { color: var(--green); }
@media (min-width: 861px) and (max-width: 1279px) {
  .esp-forum-banner { height: 50px; margin-left: 0.9rem; padding-left: 11px; }
  .esp-forum-banner-title { font-size: 29px; }
  .esp-forum-banner-sub { font-size: 13px; }
}
@media (max-width: 860px) {
  .esp-forum-banner { height: 44px; margin-left: 0.7rem; padding-left: 9px; }
  .esp-forum-banner-title { font-size: 25px; }
  .esp-forum-banner-sub { font-size: 11px; }
}
@media (max-width: 700px) {
  .top { flex-wrap: wrap; }
  .esp-forum-banner {
    order: 3;
    flex-basis: 100%;
    display: block;
    height: auto;
    margin: 8px 0 0;
    padding: 0;
    border-left: 0;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .esp-forum-banner-title,
  .esp-forum-banner-sub { display: inline; margin: 0; font-size: 15px; line-height: 1.3; }
  .esp-forum-banner-title { letter-spacing: 0; margin-right: 0; }
  .esp-forum-banner-sub::before { content: " - "; }
}

/* Text lockup: vector emblem + live text (header + home hero), fitted to img/logo.png */
@font-face { font-family: "Tinos"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("../fonts/tinos-400-latin.woff2") format("woff2"); }
@font-face { font-family: "Orbitron"; font-style: normal; font-weight: 800; font-display: swap;
  src: url("../fonts/orbitron-800-latin.woff2") format("woff2"); }
@font-face { font-family: "Barlow Semi Condensed"; font-style: normal; font-weight: 500; font-display: swap;
  src: url("../fonts/barlow-semi-condensed-500-latin.woff2") format("woff2"); }
.lockup-text { display: flex; flex-direction: column; align-items: center; }
.lt-1, .lt-2, .lt-3 { display: block; position: relative; white-space: nowrap; text-align: center; }
.lt-1 { font-family: "Tinos", "Times New Roman", Times, serif; font-weight: 400; color: #0C99D3;
  line-height: 0.65; top: -0.01em; }
.lt-2 { font-family: "Orbitron", "Eurostile", sans-serif; font-weight: 800; color: #006028;
  letter-spacing: 0.15em; margin-right: -0.15em; line-height: 0.72; top: -0.025em; }
.lt-3 { font-family: "Barlow Semi Condensed", "Bahnschrift", "Arial Narrow", sans-serif; font-weight: 500;
  color: #484848; text-transform: uppercase; letter-spacing: -0.0204em; margin-right: 0.0204em;
  line-height: 0.7; top: -0.05em; }
/* header: 1 source px = var(--u) */
.brand { --u: calc(72px / 148); gap: calc(28 * var(--u)); }
.brand img.logo { height: calc(140 * var(--u)); width: auto; }
.brand .lt-1 { font-size: calc(36.77 * var(--u)); letter-spacing: 0.2057em; margin-right: -0.2057em; }
.brand .lt-2 { font-size: calc(74.39 * var(--u)); margin-top: calc(12 * var(--u)); }
.brand .lt-3 { font-size: calc(21.43 * var(--u)); margin-top: calc(12 * var(--u)); }
/* header row: logo and forum banner keep their width (nowrap text would spill), the nav wraps instead */
.top .brand, .top .esp-forum-banner { flex-shrink: 0; }
.top .top-end { min-width: 0; flex-shrink: 1; }
@media (min-width: 861px) and (max-width: 919px) {
  .nav-toggle { display: inline-flex; }
  .nav { display: none; position: absolute; top: calc(100% + 0.45rem); right: 0; flex-direction: column;
    background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 0.7rem 1rem; box-shadow: var(--shadow); }
  body.nav-open .nav { display: flex; }
}
@media (min-width: 920px) and (max-width: 980px) {
  .esp-forum-banner { height: 44px; margin-left: 0.6rem; padding-left: 8px; }
  .esp-forum-banner-title { font-size: 22px; }
  .esp-forum-banner-sub { font-size: 11px; }
}
@media (max-width: 860px) { .brand { --u: calc(52px / 148); } }
@media (max-width: 560px) {
  .brand { --u: calc(36px / 148); }
  .brand .lt-1 { font-size: calc(52 * var(--u)); letter-spacing: 0.0888em; margin-right: -0.0888em; }
  .brand .lt-3 { display: none; }
}
@media (max-width: 380px) { .brand { --u: calc(30px / 148); } }
/* home hero: container is 791 source px wide, 1 source px = 0.126422cqw */
.hero-lockup { display: block; width: min(32.45rem, 100%); margin: 0 auto 2rem; container-type: inline-size; }
.hl-inner { display: flex; align-items: center; justify-content: center; gap: 5.0569cqw; padding: 1.0114cqw; }
.hl-emblem { display: block; height: 28.066cqw; width: auto; }
.hero-lockup .lt-1 { font-size: 4.6485cqw; letter-spacing: 0.3360em; margin-right: -0.3360em; }
.hero-lockup .lt-2 { font-size: 13.1453cqw; margin-top: 2.0228cqw; }
.hero-lockup .lt-3 { font-size: 2.7092cqw; margin-top: 2.0228cqw; }
