:root {
  color-scheme: dark;
  --bg: #061019;
  --ink: #f4f7fb;
  --muted: rgba(244, 247, 251, 0.72);
  --soft: rgba(244, 247, 251, 0.14);
  --line: rgba(143, 211, 255, 0.22);
  --accent: #7ee3d8;
  --accent-strong: #d9ff8a;
  --panel: rgba(8, 18, 29, 0.58);
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg);
  overflow-x: hidden;
}

body {
  min-height: 100svh;
  margin: 0;
  overflow-x: hidden;
  font-family: Inter, Arial, sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at var(--mx, 70%) var(--my, 22%), rgba(126, 227, 216, 0.18), transparent 34rem),
    linear-gradient(115deg, #081226 0%, #061019 50%, #092922 100%);
}

button,
input,
textarea {
  font: inherit;
}

#meshCanvas,
.ambient {
  position: fixed;
  inset: 0;
  pointer-events: none;
}

#meshCanvas {
  z-index: 0;
  opacity: 0.78;
}

.ambient {
  z-index: 1;
  background:
    linear-gradient(180deg, rgba(6, 16, 25, 0.12), rgba(6, 16, 25, 0.72)),
    radial-gradient(circle at 20% 20%, rgba(217, 255, 138, 0.08), transparent 22rem);
}

.language-switch {
  position: fixed;
  top: max(18px, env(safe-area-inset-top));
  right: max(18px, env(safe-area-inset-right));
  z-index: 5;
  display: flex;
  gap: 8px;
  padding: 9px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  background: rgba(5, 13, 22, 0.62);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(18px);
}

.lang-btn {
  display: grid;
  grid-template-rows: 36px auto;
  place-items: center;
  gap: 5px;
  min-width: 54px;
  width: 54px;
  height: 58px;
  min-height: 58px;
  padding: 5px 4px 4px;
  border: 1px solid transparent;
  border-radius: 18px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.07);
  font-size: 1.18rem;
  line-height: 1;
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.lang-btn span:last-child {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.flag-icon {
  display: block;
  width: 36px;
  height: 36px;
  flex: 0 0 auto;
  overflow: hidden;
  border-radius: 50%;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.34),
    0 8px 20px rgba(0, 0, 0, 0.28);
}

.flag-icon-uk {
  background-image: url("/assets/flag-uk.svg");
}

.flag-icon-rs {
  background-image: url("/assets/flag-serbia.svg");
  background-position: 42% center;
}

.lang-btn:hover,
.lang-btn.active {
  border-color: rgba(126, 227, 216, 0.62);
  background: rgba(126, 227, 216, 0.16);
}

.page-shell {
  position: relative;
  z-index: 2;
  display: grid;
  min-height: 100svh;
  grid-template-columns: minmax(0, 1fr);
  align-content: space-between;
  gap: clamp(36px, 8vw, 92px);
  width: min(1280px, calc(100% - 40px));
  max-width: calc(100vw - 40px);
  margin: 0 auto;
  padding: clamp(42px, 7vw, 92px) 0 clamp(26px, 5vw, 56px);
}

.hero {
  width: min(1060px, 100%);
  max-width: 1060px;
  margin-inline: auto;
  animation: enterHero 900ms cubic-bezier(.16, 1, .3, 1) both;
}

.kicker {
  margin: 0 0 18px;
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  max-width: 1060px;
  margin-bottom: 22px;
  font-size: clamp(3.4rem, 8vw, 8.2rem);
  line-height: 0.88;
  letter-spacing: 0;
  text-wrap: balance;
  text-shadow: 0 22px 80px rgba(0, 0, 0, 0.42);
}

h1 span {
  display: block;
  max-width: 100%;
  white-space: nowrap;
}

.lead {
  max-width: 650px;
  margin-bottom: 34px;
  color: var(--muted);
  font-size: clamp(1.04rem, 2.2vw, 1.35rem);
  line-height: 1.55;
}

.identity {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.identity span,
.identity a {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid var(--soft);
  border-radius: 999px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.07);
  text-decoration: none;
  backdrop-filter: blur(18px);
}

.identity a {
  color: var(--accent-strong);
}

.capabilities {
  width: min(1060px, 100%);
  max-width: 1060px;
  margin-inline: auto;
  animation: enterContact 900ms 160ms cubic-bezier(.16, 1, .3, 1) both;
}

.capabilities h2 {
  max-width: 700px;
  margin-bottom: 18px;
  font-size: clamp(1.8rem, 4vw, 3.7rem);
  line-height: 1;
}

.capabilities ul {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 18px;
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--muted);
}

.capabilities li {
  padding-left: 18px;
  border-left: 2px solid rgba(126, 227, 216, 0.4);
  line-height: 1.45;
}

.contact-section {
  display: grid;
  grid-template-columns: minmax(220px, 0.85fr) minmax(280px, 1.15fr);
  gap: clamp(24px, 5vw, 72px);
  align-items: end;
  padding-top: 26px;
  border-top: 1px solid var(--line);
  animation: enterContact 900ms 260ms cubic-bezier(.16, 1, .3, 1) both;
}

.contact-copy h2 {
  margin-bottom: 14px;
  font-size: clamp(2rem, 4vw, 4rem);
  line-height: 0.96;
}

.contact-copy p:last-child {
  max-width: 390px;
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.55;
}

.contact-form {
  display: grid;
  gap: 14px;
  padding: clamp(18px, 3vw, 28px);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 22px;
  background: var(--panel);
  box-shadow: 0 30px 100px rgba(0, 0, 0, 0.36);
  backdrop-filter: blur(22px);
}

label {
  display: grid;
  gap: 8px;
  color: rgba(244, 247, 251, 0.86);
  font-size: 0.92rem;
  font-weight: 700;
}

.hp-field {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.turnstile-widget {
  min-height: 65px;
}

input,
textarea {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 14px;
  color: var(--ink);
  background: rgba(3, 10, 18, 0.56);
  outline: none;
  transition: border-color 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

input {
  height: 48px;
  padding: 0 14px;
}

textarea {
  resize: vertical;
  min-height: 128px;
  padding: 14px;
}

input:focus,
textarea:focus {
  border-color: rgba(126, 227, 216, 0.8);
  background: rgba(3, 10, 18, 0.72);
  box-shadow: 0 0 0 4px rgba(126, 227, 216, 0.12);
}

button {
  min-height: 50px;
  border: 0;
  border-radius: 14px;
  color: #061019;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  font-weight: 800;
  cursor: pointer;
  transition: transform 160ms ease, filter 160ms ease;
}

button:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
}

.form-status {
  min-height: 20px;
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

@media (max-width: 1320px) {
  h1 {
    font-size: clamp(3.2rem, 7.2vw, 6.8rem);
  }
}

@keyframes enterHero {
  from {
    opacity: 0;
    transform: translateY(22px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes enterContact {
  from {
    opacity: 0;
    transform: translateY(26px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 820px) {
  .page-shell {
    width: min(100% - 28px, 620px);
    max-width: calc(100vw - 28px);
    padding-top: 142px;
    gap: 48px;
  }

  h1 {
    font-size: clamp(3rem, 13vw, 5.6rem);
  }

  .contact-section {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .capabilities ul {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .language-switch {
    top: max(14px, env(safe-area-inset-top));
    right: max(14px, env(safe-area-inset-right));
  }

  .page-shell {
    padding-top: 156px;
  }

  h1 {
    font-size: clamp(2.8rem, 12.5vw, 4.1rem);
  }

  .identity {
    align-items: stretch;
  }

  .identity span,
  .identity a {
    width: 100%;
    justify-content: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    transition-duration: 1ms !important;
  }
}
