@font-face {
  font-family: "Funnel";
  src: url("assets/funnel-sans.woff2") format("woff2");
  font-display: swap;
  font-weight: 300 800;
}

:root {
  --navy: #141a2e;
  --navy-soft: #182747;
  --blue: #2f80ff;
  --paper: #f4f7fb;
  --white: #ffffff;
  --ink: #111827;
  --muted: #657084;
  --line: #dbe3ee;
  --field: #f8fafc;
  --error: #b42318;
  --success: #11734b;
  --max-width: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--paper);
  color: var(--ink);
  font-family: "Funnel", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: "";
  position: fixed;
  inset: 0 auto 0 0;
  width: 42vw;
  background: var(--navy);
  z-index: -1;
}

button,
input,
select,
textarea {
  font: inherit;
}

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

a {
  color: inherit;
}

.page-shell,
.site-footer {
  width: min(calc(100% - 56px), var(--max-width));
  margin-inline: auto;
}

.page-shell {
  min-height: calc(100vh - 34px);
  display: grid;
  grid-template-columns: minmax(0, 0.86fr) minmax(520px, 1.14fr);
  align-items: center;
  gap: clamp(34px, 5vw, 64px);
  padding: 24px 0 10px;
}

.intro-panel,
.form-panel {
  min-width: 0;
}

.intro-panel {
  max-width: 540px;
  color: var(--white);
  animation: fade-up 420ms ease both;
}

.brand {
  display: inline-flex;
  margin-bottom: clamp(28px, 5vh, 42px);
  text-decoration: none;
}

.brand img {
  width: 156px;
  height: auto;
}

.eyebrow {
  margin: 0;
  color: var(--blue);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.13em;
  line-height: 1.4;
  text-transform: uppercase;
}

h1,
h2 {
  margin: 0;
  color: inherit;
  font-family: Arial, sans-serif;
  font-weight: 400;
  letter-spacing: 0;
}

h1 {
  max-width: 520px;
  margin-top: 16px;
  font-size: clamp(3.5rem, 5vw, 4.5rem);
  line-height: 1.02;
  text-wrap: balance;
}

.lead {
  max-width: 520px;
  margin: 20px 0 0;
  color: rgba(255, 255, 255, 0.74);
  font-size: 1rem;
  line-height: 1.58;
}

.trust-list {
  display: grid;
  gap: 10px;
  margin: 28px 0 0;
  padding: 0;
  list-style: none;
  color: rgba(255, 255, 255, 0.87);
  font-size: 0.93rem;
}

.trust-list li {
  position: relative;
  padding-left: 20px;
}

.trust-list li::before {
  content: "";
  position: absolute;
  top: 0.58em;
  left: 0;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--blue);
}

.form-panel {
  width: min(100%, 660px);
  justify-self: center;
  background: var(--white);
  border: 1px solid rgba(219, 227, 238, 0.95);
  border-radius: 7px;
  box-shadow: 0 18px 46px rgba(20, 26, 46, 0.1);
  padding: clamp(18px, 2vw, 24px);
  animation: fade-up 460ms 80ms ease both;
}

.form-heading {
  margin-bottom: 12px;
}

.form-heading h2 {
  margin-top: 5px;
  color: var(--navy);
  font-size: clamp(2.25rem, 3vw, 2.75rem);
  line-height: 1.04;
}

.form-heading p:not(.eyebrow) {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 0.93rem;
  line-height: 1.45;
}

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

.field,
.field-full {
  min-width: 0;
}

.field-full {
  grid-column: 1 / -1;
}

label {
  display: block;
  margin-bottom: 4px;
  color: var(--navy);
  font-size: 0.84rem;
  line-height: 1.15;
  font-weight: 760;
}

label span {
  color: var(--blue);
}

label small {
  margin-left: 6px;
  color: #8a94a6;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid #cbd4e2;
  border-radius: 5px;
  background: var(--field);
  color: var(--ink);
  font-size: 0.95rem;
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

input,
select {
  min-height: 46px;
  padding: 0 12px;
}

textarea {
  padding: 9px 12px;
  line-height: 1.4;
  resize: vertical;
}

#primary_skills {
  min-height: 82px;
}

#additional_information {
  min-height: 72px;
}

input::placeholder,
textarea::placeholder {
  color: #8a94a6;
  opacity: 1;
}

select {
  appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, #687386 50%),
    linear-gradient(135deg, #687386 50%, transparent 50%);
  background-position:
    calc(100% - 18px) 20px,
    calc(100% - 13px) 20px;
  background-repeat: no-repeat;
  background-size: 5px 5px;
  padding-right: 38px;
}

input:focus,
select:focus,
textarea:focus {
  outline: 0;
  border-color: var(--blue);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(47, 128, 255, 0.15);
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid rgba(47, 128, 255, 0.55);
  outline-offset: 3px;
}

[aria-invalid="true"] {
  border-color: var(--error);
  box-shadow: 0 0 0 1px rgba(180, 35, 24, 0.1);
}

.field-error {
  display: none;
  margin: 3px 0 0;
  color: var(--error);
  font-size: 0.73rem;
  line-height: 1.25;
}

.field-error:not(:empty) {
  display: block;
}

.submit-button {
  width: 100%;
  min-height: 48px;
  margin-top: 12px;
  border: 0;
  border-radius: 5px;
  background: var(--navy);
  color: var(--white);
  cursor: pointer;
  font-weight: 800;
  transition: transform 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

.submit-button:hover {
  background: var(--navy-soft);
  box-shadow: 0 10px 24px rgba(20, 26, 46, 0.16);
  transform: translateY(-1px);
}

.submit-button:disabled {
  cursor: wait;
  opacity: 0.68;
  transform: none;
}

.status-region:not(:empty) {
  margin-top: 10px;
}

.form-status {
  border-radius: 5px;
  padding: 12px 13px;
  font-size: 0.86rem;
  line-height: 1.4;
}

.form-status strong {
  display: block;
}

.form-status p {
  margin: 2px 0 0;
}

.status-development {
  border: 1px solid #c6dcff;
  background: #eef5ff;
  color: #174f9f;
}

.status-success {
  border: 1px solid #bde8d2;
  background: #edf9f3;
  color: var(--success);
}

.status-error {
  border: 1px solid #ffc9c4;
  background: #fff1f0;
  color: var(--error);
}

.site-footer {
  min-height: 34px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  color: rgba(255, 255, 255, 0.62);
  font-size: 0.76rem;
}

@keyframes fade-up {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 1100px) {
  .page-shell {
    grid-template-columns: minmax(0, 0.82fr) minmax(500px, 1.18fr);
    gap: 32px;
  }

  h1 {
    font-size: clamp(3.25rem, 4.9vw, 4rem);
  }
}

@media (max-width: 980px) {
  body::before {
    width: 100%;
    height: 390px;
  }

  .page-shell,
  .site-footer {
    width: min(calc(100% - 36px), var(--max-width));
  }

  .page-shell {
    min-height: auto;
    grid-template-columns: 1fr;
    align-items: start;
    gap: 24px;
    padding-top: 28px;
    padding-bottom: 24px;
  }

  .intro-panel {
    max-width: 700px;
  }

  .brand {
    margin-bottom: 28px;
  }

  h1 {
    max-width: 620px;
    font-size: clamp(2.8rem, 7.5vw, 4.25rem);
  }

  .lead {
    max-width: 680px;
  }

  .form-panel {
    width: min(100%, 680px);
    justify-self: start;
  }
}

@media (max-width: 680px) {
  body::before {
    height: 360px;
  }

  .page-shell,
  .site-footer {
    width: min(calc(100% - 28px), var(--max-width));
  }

  .page-shell {
    gap: 20px;
    padding-top: 20px;
    padding-bottom: 24px;
  }

  .brand {
    margin-bottom: 24px;
  }

  .brand img {
    width: 140px;
  }

  h1 {
    max-width: 420px;
    margin-top: 12px;
    font-size: clamp(2.5rem, 10.5vw, 3rem);
    line-height: 1.02;
  }

  .lead {
    margin-top: 16px;
    font-size: 0.96rem;
    line-height: 1.52;
  }

  .trust-list {
    gap: 8px;
    margin-top: 20px;
    font-size: 0.9rem;
  }

  .form-panel {
    width: 100%;
    padding: 20px 16px;
  }

  .form-heading {
    margin-bottom: 15px;
  }

  .form-heading h2 {
    font-size: clamp(2rem, 9vw, 2.35rem);
  }

  .form-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .field-full {
    grid-column: auto;
  }

  input,
  select {
    min-height: 48px;
  }

  #primary_skills {
    min-height: 86px;
  }

  #additional_information {
    min-height: 76px;
  }

  .site-footer {
    min-height: auto;
    align-items: flex-start;
    flex-direction: column;
    padding-bottom: 20px;
  }
}

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

  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    transition-duration: 1ms !important;
  }
}
