/* ============================================================
   DefCon — ООО «ТЕХКОНТРОЛВИЖН»
   Лендинг: тёмный hi-tech стиль, синий акцент, хром-градиенты
   ============================================================ */

:root {
  --bg-dark: #05070d;
  --bg-dark-2: #0a0e18;
  --bg-light: #ffffff;
  --bg-light-2: #f4f6fb;
  --accent: #2f5bff;
  --accent-2: #5b84ff;
  --accent-soft: rgba(47, 91, 255, 0.12);
  --text-dark: #0d1220;
  --text-light: #f2f5fa;
  --muted-dark: #5b6478;
  --muted-light: #9aa5bb;
  --line-dark: rgba(13, 18, 32, 0.08);
  --line-light: rgba(255, 255, 255, 0.09);
  --radius: 20px;
  --radius-sm: 12px;
  --container: 1200px;
  --font: "Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --transition: 0.25s ease;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 90px;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  color: var(--text-dark);
  background: var(--bg-light);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

a { color: inherit; text-decoration: none; }

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px 32px;
  border: none;
  border-radius: 100px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  font-family: var(--font);
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition), filter var(--transition);
  box-shadow: 0 8px 24px rgba(47, 91, 255, 0.35);
  white-space: nowrap;
}
.btn:hover {
  transform: translateY(-2px);
  filter: brightness(1.08);
  box-shadow: 0 12px 32px rgba(47, 91, 255, 0.45);
}
.btn:active { transform: translateY(0); }

.btn--ghost {
  background: transparent;
  color: var(--text-light);
  box-shadow: none;
  border: 1px solid rgba(255, 255, 255, 0.25);
}
.btn--ghost:hover {
  border-color: var(--accent-2);
  color: #fff;
  box-shadow: none;
  background: rgba(47, 91, 255, 0.12);
}

.btn--small { padding: 11px 22px; font-size: 14px; }

/* ---------- Logo ---------- */
.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: var(--text-light);
  text-transform: lowercase;
}
.logo__mark {
  width: 14px;
  height: 14px;
  border-radius: 4px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  box-shadow: 0 0 14px rgba(47, 91, 255, 0.8);
  flex: none;
}

/* ---------- Header ---------- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  transition: background var(--transition), box-shadow var(--transition), backdrop-filter var(--transition);
}
.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 76px;
}
.header.is-scrolled {
  background: rgba(5, 7, 13, 0.82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 1px 0 var(--line-light);
}
.nav {
  display: flex;
  align-items: center;
  gap: 32px;
}
.nav__link {
  color: var(--muted-light);
  font-size: 15px;
  font-weight: 600;
  transition: color var(--transition);
}
.nav__link:hover { color: #fff; }
.nav__cta { margin-left: 8px; }

.burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: transparent;
  border: 1px solid var(--line-light);
  border-radius: 10px;
  cursor: pointer;
}
.burger span {
  display: block;
  height: 2px;
  width: 100%;
  background: #fff;
  border-radius: 2px;
  transition: transform var(--transition), opacity var(--transition);
}
.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); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background:
    radial-gradient(60% 50% at 75% 45%, rgba(47, 91, 255, 0.16), transparent 70%),
    linear-gradient(180deg, #04060c 0%, var(--bg-dark) 60%, #070b14 100%);
  color: var(--text-light);
  overflow: hidden;
  padding: 130px 0 80px;
}
.hero__glow {
  position: absolute;
  top: 50%;
  right: -10%;
  width: 60vw;
  height: 60vw;
  max-width: 900px;
  max-height: 900px;
  transform: translateY(-50%);
  background: radial-gradient(circle, rgba(47, 91, 255, 0.28) 0%, rgba(47, 91, 255, 0.08) 40%, transparent 68%);
  pointer-events: none;
  animation: pulse 6s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 0.8; transform: translateY(-50%) scale(1); }
  50% { opacity: 1; transform: translateY(-50%) scale(1.06); }
}
.hero__inner {
  position: relative;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: 48px;
}
.hero__badge {
  display: inline-block;
  margin: 0 0 22px;
  padding: 8px 18px;
  border: 1px solid rgba(91, 132, 255, 0.4);
  border-radius: 100px;
  background: rgba(47, 91, 255, 0.1);
  color: var(--accent-2);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.hero__title {
  margin: 0 0 24px;
  font-size: clamp(34px, 4.6vw, 62px);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.02em;
}
.hero__title .accent {
  background: linear-gradient(120deg, var(--accent-2), #9db8ff);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.hero__lead {
  margin: 0 0 36px;
  max-width: 520px;
  color: var(--muted-light);
  font-size: 19px;
}
.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 40px;
}
.hero__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.hero__tags li {
  padding: 7px 16px;
  border: 1px solid var(--line-light);
  border-radius: 100px;
  color: var(--muted-light);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.03em;
}
.hero__visual {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
}
.hero__net {
  position: relative;
  z-index: 2;
  display: block;
  width: min(100%, 540px);
  aspect-ratio: 1 / 1;
  border-radius: 24px;
  background:
    radial-gradient(55% 55% at 50% 45%, rgba(47, 91, 255, 0.14), transparent 72%),
    rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(91, 132, 255, 0.22);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45), inset 0 0 60px rgba(47, 91, 255, 0.06);
}
.hero__net-caption {
  position: relative;
  z-index: 2;
  margin: 0;
  max-width: 420px;
  text-align: center;
  color: var(--muted-light);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.hero__scroll {
  position: absolute;
  left: 50%;
  bottom: 26px;
  transform: translateX(-50%);
  width: 26px;
  height: 42px;
  border: 2px solid rgba(255, 255, 255, 0.28);
  border-radius: 14px;
}
.hero__scroll span {
  position: absolute;
  top: 7px;
  left: 50%;
  width: 4px;
  height: 8px;
  margin-left: -2px;
  border-radius: 2px;
  background: var(--accent-2);
  animation: scrollHint 1.8s ease-in-out infinite;
}
@keyframes scrollHint {
  0% { transform: translateY(0); opacity: 1; }
  70% { transform: translateY(14px); opacity: 0; }
  100% { transform: translateY(0); opacity: 0; }
}

/* ---------- Sections ---------- */
.section { padding: 110px 0; }
.section--dark {
  background: linear-gradient(180deg, var(--bg-dark) 0%, var(--bg-dark-2) 100%);
  color: var(--text-light);
}
.section__head {
  max-width: 720px;
  margin-bottom: 64px;
}
.section__label {
  margin: 0 0 14px;
  color: var(--accent);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.section--dark .section__label { color: var(--accent-2); }
.section__title {
  margin: 0;
  font-size: clamp(30px, 3.6vw, 48px);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

/* ---------- Services ---------- */
.services { background: var(--bg-light); }
.services__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.service-card {
  position: relative;
  padding: 36px 32px;
  border: 1px solid var(--line-dark);
  border-radius: var(--radius);
  background: #fff;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}
.service-card:hover {
  transform: translateY(-6px);
  border-color: rgba(47, 91, 255, 0.35);
  box-shadow: 0 24px 48px rgba(13, 18, 32, 0.1);
}
.service-card__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  margin-bottom: 22px;
  border-radius: 16px;
  background: var(--accent-soft);
  color: var(--accent);
}
.service-card__icon svg { width: 28px; height: 28px; }
.service-card h3 {
  margin: 0 0 10px;
  font-size: 21px;
  font-weight: 800;
  letter-spacing: -0.01em;
}
.service-card p {
  margin: 0 0 16px;
  color: var(--muted-dark);
  font-size: 15px;
}
.service-card ul {
  margin: 0;
  padding: 0;
  list-style: none;
}
.service-card li {
  position: relative;
  padding: 6px 0 6px 22px;
  color: var(--text-dark);
  font-size: 14.5px;
}
.service-card li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 14px;
  width: 10px;
  height: 10px;
  border-radius: 3px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
}
.service-card--cta {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: 8px;
  background: linear-gradient(150deg, #0a0e18, #101a33 70%, #16224a);
  border: none;
  color: var(--text-light);
}
.service-card--cta p { color: var(--muted-light); }
.service-card--cta .btn { margin-top: 12px; }

/* ---------- Projects ---------- */
.projects { position: relative; }
.projects__list {
  display: flex;
  flex-direction: column;
  gap: 56px;
}
.case {
  position: relative;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 56px;
  align-items: center;
  padding: 48px;
  border: 1px solid var(--line-light);
  border-radius: calc(var(--radius) + 8px);
  background: rgba(255, 255, 255, 0.03);
  overflow: hidden;
}
.case--reverse .case__media { order: 2; }
.case__media {
  position: relative;
  z-index: 2;
  border-radius: var(--radius-sm);
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5);
  transition: transform 0.4s ease;
}
.case__media:hover { transform: scale(1.02); }
.case__media img { width: 100%; }
.case__body { position: relative; z-index: 2; }
.case__name {
  margin: 0 0 6px;
  font-size: 30px;
  font-weight: 800;
  letter-spacing: -0.01em;
  background: linear-gradient(120deg, #fff, #9db8ff);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.case__subtitle {
  margin: 0 0 18px;
  color: var(--accent-2);
  font-size: 17px;
  font-weight: 700;
}
.case__body > p:not(.case__subtitle) {
  margin: 0 0 14px;
  color: var(--muted-light);
  font-size: 15.5px;
}
.case__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 24px;
}
.case__client {
  padding: 8px 18px;
  border-radius: 100px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid var(--line-light);
  font-size: 14px;
  font-weight: 700;
}
.case__link {
  padding: 8px 18px;
  border-radius: 100px;
  background: transparent;
  border: 1px solid rgba(91, 132, 255, 0.4);
  color: var(--accent-2);
  font-size: 14px;
  font-weight: 700;
  transition: background var(--transition), color var(--transition), border-color var(--transition);
}
.case__link:hover {
  background: var(--accent-soft);
  border-color: var(--accent-2);
  color: #fff;
}
.case__status {
  position: relative;
  padding: 8px 18px 8px 34px;
  border-radius: 100px;
  background: var(--accent-soft);
  border: 1px solid rgba(91, 132, 255, 0.4);
  color: var(--accent-2);
  font-size: 14px;
  font-weight: 700;
}
.case__status::before {
  content: "";
  position: absolute;
  left: 16px;
  top: 50%;
  width: 8px;
  height: 8px;
  margin-top: -4px;
  border-radius: 50%;
  background: var(--accent-2);
  animation: blink 1.6s ease-in-out infinite;
}
@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.25; }
}
.case__deco {
  position: absolute;
  z-index: 1;
  opacity: 0.35;
  pointer-events: none;
  filter: saturate(0.9);
}
.case__deco--bottle { right: -90px; bottom: -70px; width: 340px; transform: rotate(-18deg); }
.case__deco--egg { left: -110px; bottom: -90px; width: 320px; }
.case__deco--star { right: -110px; top: -100px; width: 300px; transform: rotate(14deg); }

/* ---------- Process ---------- */
.process { background: var(--bg-light-2); }
.process__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
}
.process__step {
  position: relative;
  padding: 36px 28px;
  border-radius: var(--radius);
  background: #fff;
  border: 1px solid var(--line-dark);
  transition: transform var(--transition), box-shadow var(--transition);
}
.process__step:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 44px rgba(13, 18, 32, 0.09);
}
.process__num {
  display: block;
  margin-bottom: 18px;
  font-size: 44px;
  font-weight: 800;
  line-height: 1;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.process__step h3 {
  margin: 0 0 10px;
  font-size: 19px;
  font-weight: 800;
}
.process__step p {
  margin: 0;
  color: var(--muted-dark);
  font-size: 14.5px;
}

/* ---------- Contacts ---------- */
.contacts {
  position: relative;
  overflow: hidden;
}
.contacts__glow {
  position: absolute;
  top: -20%;
  left: -15%;
  width: 55vw;
  height: 55vw;
  max-width: 760px;
  max-height: 760px;
  background: radial-gradient(circle, rgba(47, 91, 255, 0.2), transparent 65%);
  pointer-events: none;
}
.contacts__inner {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 72px;
  align-items: start;
}
.contacts__lead {
  margin: 18px 0 40px;
  color: var(--muted-light);
  font-size: 18px;
  max-width: 440px;
}
.contacts__list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 22px;
}
.contacts__name {
  font-size: 20px;
  font-weight: 800;
}
.contacts__link {
  display: block;
  font-size: 22px;
  font-weight: 800;
  color: #fff;
  transition: color var(--transition);
}
.contacts__link:hover { color: var(--accent-2); }
.contacts__hint {
  color: var(--muted-light);
  font-size: 13.5px;
}

/* ---------- Form ---------- */
.form {
  padding: 44px 40px;
  border-radius: calc(var(--radius) + 4px);
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid var(--line-light);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.form__title {
  margin: 0 0 28px;
  font-size: 22px;
  font-weight: 800;
}
.form__field { margin-bottom: 20px; }
.form__field label {
  display: block;
  margin-bottom: 8px;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-light);
}
.req { color: var(--accent-2); }
.form__field input,
.form__field textarea {
  width: 100%;
  padding: 15px 18px;
  border: 1px solid var(--line-light);
  border-radius: var(--radius-sm);
  background: rgba(5, 7, 13, 0.5);
  color: #fff;
  font-family: var(--font);
  font-size: 16px;
  transition: border-color var(--transition), box-shadow var(--transition);
  resize: vertical;
}
.form__field input::placeholder,
.form__field textarea::placeholder { color: rgba(154, 165, 187, 0.55); }
.form__field input:focus,
.form__field textarea:focus {
  outline: none;
  border-color: var(--accent-2);
  box-shadow: 0 0 0 4px rgba(47, 91, 255, 0.18);
}
.form__field.has-error input,
.form__field.has-error textarea { border-color: #ff5b6e; }
.form__error {
  display: block;
  min-height: 18px;
  margin-top: 6px;
  color: #ff8291;
  font-size: 13px;
  font-weight: 600;
}
.form__hp {
  position: absolute;
  left: -9999px;
  top: -9999px;
  height: 0;
  overflow: hidden;
}
.form__submit {
  width: 100%;
  margin-top: 6px;
  position: relative;
}
.form__submit[disabled] { opacity: 0.7; cursor: wait; transform: none; }
.form__spinner {
  display: none;
  width: 18px;
  height: 18px;
  border: 2.5px solid rgba(255, 255, 255, 0.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
.form.is-sending .form__spinner { display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }
.form__status {
  margin: 16px 0 0;
  min-height: 22px;
  font-size: 14.5px;
  font-weight: 700;
  text-align: center;
}
.form__status.is-ok { color: #4ade80; }
.form__status.is-err { color: #ff8291; }
.form__note {
  margin: 14px 0 0;
  color: var(--muted-light);
  font-size: 12.5px;
  text-align: center;
}

/* ---------- Footer ---------- */
.footer {
  padding: 40px 0;
  background: #04060c;
  border-top: 1px solid var(--line-light);
}
.footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.footer__legal, .footer__copy {
  margin: 0;
  color: var(--muted-light);
  font-size: 14px;
}

/* ---------- Reveal animation ---------- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero__glow, .hero__scroll span, .case__status::before { animation: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .services__grid { grid-template-columns: repeat(2, 1fr); }
  .process__grid { grid-template-columns: repeat(2, 1fr); }
  .case { grid-template-columns: 1fr; gap: 32px; padding: 36px; }
  .case--reverse .case__media { order: 0; }
  .case__deco { opacity: 0.22; }
  .contacts__inner { grid-template-columns: 1fr; gap: 48px; }
}

@media (max-width: 760px) {
  body { font-size: 16px; }
  .section { padding: 72px 0; }
  .burger { display: flex; }
  .nav {
    position: fixed;
    top: 76px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    padding: 20px 24px 28px;
    background: rgba(5, 7, 13, 0.97);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--line-light);
    transform: translateY(-12px);
    opacity: 0;
    visibility: hidden;
    transition: opacity var(--transition), transform var(--transition), visibility var(--transition);
  }
  .nav.is-open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }
  .nav__link { padding: 12px 4px; font-size: 17px; }
  .nav__cta { margin: 12px 0 0; text-align: center; }
  .hero { padding: 110px 0 70px; }
  .hero__inner { grid-template-columns: 1fr; gap: 40px; }
  .hero__visual { order: -1; }
  .hero__net { width: min(100%, 340px); }
  .hero__scroll { display: none; }
  .services__grid { grid-template-columns: 1fr; }
  .process__grid { grid-template-columns: 1fr; }
  .case { padding: 24px; }
  .case__deco { display: none; }
  .form { padding: 30px 22px; }
  .footer__inner { flex-direction: column; text-align: center; }
}
