:root {
  --bg: #081225;
  --bg-elev: #0f1b33;
  --card: #10203d;
  --text: #edf3ff;
  --muted: #a7b5cf;
  --line: rgba(255,255,255,0.08);
  --accent: #3b82f6;
  --accent-2: #60a5fa;
  --shadow: 0 16px 40px rgba(0,0,0,0.24);
}

body.light {
  --bg: #f7faff;
  --bg-elev: #ffffff;
  --card: #ffffff;
  --text: #0f172a;
  --muted: #475569;
  --line: rgba(15,23,42,0.08);
  --accent: #2563eb;
  --accent-2: #60a5fa;
  --shadow: 0 16px 40px rgba(15,23,42,0.10);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  background: radial-gradient(circle at top left, rgba(59,130,246,0.10), transparent 36%), linear-gradient(180deg, var(--bg), #060d1b);
  color: var(--text);
  transition: background .2s ease, color .2s ease;
}
body.light {
  background: radial-gradient(circle at top left, rgba(37,99,235,0.08), transparent 36%), linear-gradient(180deg, var(--bg), #eef4ff);
}

a { color: inherit; text-decoration: none; }
img, canvas { display: block; }

.site-shell {
  width: min(1140px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(8,18,37,0.88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
body.light .site-header { background: rgba(247,250,255,0.92); }

.site-header__inner {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.brand {
  display: inline-flex;
  align-items: center;
  min-width: 210px;
}

#logoCanvas {
  width: 210px;
  height: 44px;
}

.nav {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}

.nav__link {
  position: relative;
  font-weight: 600;
  padding: 8px 0;
}

.nav__link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 2px;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  border-radius: 999px;
  transition: width .18s ease;
}

.nav__link:hover::after,
.nav__link[aria-current="page"]::after { width: 100%; }

.theme-toggle {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--text);
  cursor: pointer;
  box-shadow: var(--shadow);
}

.page { padding: 42px 0 56px; }
.hero { padding: 18px 0 32px; }
.hero__panel {
  background: linear-gradient(180deg, rgba(255,255,255,0.03), rgba(255,255,255,0.015));
  border: 1px solid var(--line);
  border-radius: 28px;
  box-shadow: var(--shadow);
  padding: clamp(28px, 4vw, 44px);
}
body.light .hero__panel { background: linear-gradient(180deg, rgba(255,255,255,0.98), rgba(255,255,255,0.94)); }

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.03);
  color: var(--muted);
  font-size: 14px;
}
body.light .kicker { background: rgba(15,23,42,0.03); }
.kicker__dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--accent);
  box-shadow: 0 0 0 6px rgba(59,130,246,0.14);
}

.hero h1 {
  margin: 16px 0 12px;
  font-size: clamp(36px, 6vw, 62px);
  line-height: 1.04;
  letter-spacing: -0.03em;
}
.hero p {
  margin: 0;
  max-width: 760px;
  color: var(--muted);
  font-size: clamp(18px, 2vw, 21px);
  line-height: 1.65;
}
.hero__actions {
  margin-top: 26px;
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border-radius: 12px;
  border: 1px solid var(--line);
  font-weight: 700;
  transition: transform .18s ease, background .18s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn--primary {
  color: #fff;
  background: linear-gradient(180deg, var(--accent-2), var(--accent));
  border-color: transparent;
}
.btn--ghost { background: rgba(255,255,255,0.03); }
body.light .btn--ghost { background: rgba(15,23,42,0.03); }

.section { padding: 26px 0; }
.section__header {
  margin-bottom: 18px;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 12px;
}
.section__header h2 {
  margin: 0;
  font-size: clamp(24px, 4vw, 34px);
}
.section__header p { margin: 0; color: var(--muted); }

.grid {
  display: grid;
  gap: 18px;
}
.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: var(--shadow);
  padding: 22px;
}
.card h3 { margin: 0 0 10px; font-size: 21px; }
.card p { margin: 0 0 10px; color: var(--muted); line-height: 1.7; }
.card ul { margin: 0; padding-left: 18px; color: var(--muted); }
.card li { margin: 6px 0; }
.card__link {
  margin-top: 12px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  color: var(--accent-2);
}
body.light .card__link { color: var(--accent); }

.badge-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}
.badge {
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.03);
  color: var(--muted);
  font-size: 14px;
}
body.light .badge { background: rgba(15,23,42,0.03); }

.contact-card {
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  gap: 18px;
}
.form { display: grid; gap: 14px; }
.label { display: grid; gap: 8px; font-weight: 700; }
.input, .textarea {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.02);
  color: var(--text);
  outline: none;
}
body.light .input, body.light .textarea { background: #fff; }
.textarea { min-height: 140px; resize: vertical; }
.form__hint, .small { color: var(--muted); font-size: 14px; line-height: 1.6; }

.site-footer {
  padding: 28px 0 42px;
  color: var(--muted);
}
.site-footer__inner {
  border-top: 1px solid var(--line);
  padding-top: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}
.footer-links { display: flex; flex-wrap: wrap; gap: 14px; }

.reveal {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity .45s ease, transform .45s ease;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 940px) {
  .grid--2, .grid--3, .contact-card { grid-template-columns: 1fr; }
  .site-header__inner { align-items: flex-start; padding: 8px 0; min-height: 84px; }
}

@media (max-width: 720px) {
  .site-shell { width: min(1140px, calc(100% - 20px)); }
  .nav { gap: 14px; }
  .nav__link { font-size: 15px; }
}
