:root {
  --bg: #f7f8f4;
  --surface: #ffffff;
  --surface-soft: #edf4ef;
  --text: #18201d;
  --muted: #5c6862;
  --line: #d8ded8;
  --accent: #147a5f;
  --accent-dark: #0d4f40;
  --warning: #9a3412;
  --container: 1080px;
  --radius: 8px;
  --shadow: 0 22px 70px rgba(25, 32, 29, 0.12);
  color-scheme: light;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    linear-gradient(180deg, rgba(237, 244, 239, 0.9), rgba(247, 248, 244, 0) 420px),
    var(--bg);
  color: var(--text);
}

body.modal-open {
  overflow: hidden;
}

button,
input {
  font: inherit;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  width: min(var(--container), calc(100% - 32px));
  margin: 0 auto;
  padding: 26px 0 18px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: inherit;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border-radius: 50%;
  background: var(--accent);
  color: #ffffff;
  font-size: 24px;
  font-weight: 800;
}

.brand-text {
  display: grid;
  gap: 1px;
}

.brand-text strong {
  font-size: 20px;
  letter-spacing: 0;
}

.brand-text span {
  color: var(--muted);
  font-size: 14px;
}

.header-link {
  min-height: 42px;
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 16px;
  background: var(--surface);
  color: var(--text);
  font-weight: 750;
  text-decoration: none;
}

main {
  overflow: hidden;
}

.video-section,
.form-section {
  width: min(var(--container), calc(100% - 32px));
  margin: 0 auto;
}

.video-section {
  display: grid;
  gap: 30px;
  padding: 32px 0 82px;
}

.intro-copy,
.section-heading,
.form-copy {
  max-width: 760px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--accent-dark);
  font-size: 13px;
  font-weight: 750;
  letter-spacing: 0;
  text-transform: uppercase;
}

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

h1 {
  max-width: 900px;
  margin-bottom: 18px;
  font-size: clamp(42px, 7vw, 78px);
  line-height: 0.98;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 16px;
  font-size: clamp(30px, 4vw, 52px);
  line-height: 1.05;
  letter-spacing: 0;
}

.intro-copy p:not(.eyebrow),
.form-copy p {
  max-width: 650px;
  color: var(--muted);
  font-size: clamp(17px, 2vw, 21px);
  line-height: 1.55;
}

.video-frame {
  position: relative;
  min-height: clamp(260px, 32vw, 380px);
  border: 1px solid rgba(24, 32, 29, 0.12);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(20, 122, 95, 0.14), rgba(255, 255, 255, 0.9) 54%),
    repeating-linear-gradient(90deg, rgba(24, 32, 29, 0.06) 0 1px, transparent 1px 28px),
    var(--surface);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.explainer-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #101512;
  opacity: 0.22;
  pointer-events: none;
}

.video-frame.has-video .explainer-video {
  opacity: 0.38;
}

.video-open {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 18px;
  padding: 28px;
  border: 0;
  background:
    linear-gradient(180deg, rgba(16, 21, 18, 0.04), rgba(16, 21, 18, 0.22)),
    transparent;
  color: var(--text);
  cursor: pointer;
  text-align: center;
  transition: background 180ms ease, transform 180ms ease;
}

.video-open:hover {
  background:
    linear-gradient(180deg, rgba(16, 21, 18, 0.02), rgba(16, 21, 18, 0.16)),
    transparent;
}

.video-open:focus-visible {
  outline: 4px solid rgba(20, 122, 95, 0.22);
  outline-offset: -4px;
}

.play-button {
  position: relative;
  display: grid;
  width: 82px;
  height: 82px;
  place-items: center;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 18px 40px rgba(20, 122, 95, 0.28);
  transition: transform 180ms ease, background 180ms ease;
}

.video-open:hover .play-button {
  background: var(--accent-dark);
  transform: scale(1.04);
}

.play-button::after {
  content: "";
  width: 0;
  height: 0;
  margin-left: 5px;
  border-top: 14px solid transparent;
  border-bottom: 14px solid transparent;
  border-left: 21px solid #ffffff;
}

.video-open div {
  display: grid;
  gap: 6px;
}

.video-open strong {
  font-size: clamp(26px, 4vw, 44px);
}

.video-open span {
  color: var(--muted);
  font-size: 18px;
}

.video-modal {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: clamp(12px, 3vw, 34px);
}

.video-modal[hidden] {
  display: none;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(9, 13, 11, 0.86);
  cursor: pointer;
}

.modal-panel {
  position: relative;
  z-index: 1;
  width: min(1280px, 100%);
  max-height: calc(100vh - 32px);
  display: grid;
  place-items: center;
}

.modal-video {
  width: 100%;
  max-height: calc(100vh - 32px);
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  background: #000000;
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.42);
}

.modal-close {
  position: absolute;
  top: -18px;
  right: -18px;
  z-index: 2;
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 50%;
  background: #ffffff;
  color: var(--text);
  font-size: 30px;
  line-height: 1;
  cursor: pointer;
}

.form-section {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: clamp(28px, 5vw, 64px);
  align-items: start;
  padding: 86px 0 110px;
}

.contact-form {
  padding: clamp(22px, 4vw, 40px);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

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

label {
  display: grid;
  gap: 8px;
  color: var(--text);
  font-weight: 650;
}

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

input {
  width: 100%;
  min-height: 50px;
  border: 1px solid #cbd4ce;
  border-radius: var(--radius);
  background: #fbfcfb;
  color: var(--text);
  padding: 0 14px;
  outline: none;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

input:focus,
canvas:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(20, 122, 95, 0.14);
}

.signature-block {
  display: grid;
  gap: 10px;
  margin-top: 22px;
}

.signature-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.text-button {
  border: 0;
  background: transparent;
  color: var(--accent-dark);
  font-weight: 750;
  cursor: pointer;
}

canvas {
  display: block;
  width: 100%;
  height: 190px;
  border: 1px dashed #9fb0a7;
  border-radius: var(--radius);
  background:
    linear-gradient(transparent calc(100% - 42px), rgba(20, 122, 95, 0.16) calc(100% - 41px), transparent calc(100% - 40px)),
    #fbfcfb;
  touch-action: none;
}

.privacy-check {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  margin-top: 22px;
  color: var(--muted);
  font-weight: 500;
  line-height: 1.45;
}

.privacy-check input {
  width: 20px;
  min-height: 20px;
  margin-top: 2px;
  accent-color: var(--accent);
}

.form-status {
  min-height: 24px;
  margin: 18px 0 0;
  color: var(--warning);
  font-weight: 650;
}

.form-status.success {
  color: var(--accent-dark);
}

.submit-button {
  width: 100%;
  min-height: 54px;
  margin-top: 12px;
  border: 0;
  border-radius: var(--radius);
  background: var(--accent);
  color: #ffffff;
  font-weight: 800;
  cursor: pointer;
  transition: background 160ms ease, transform 160ms ease;
}

.submit-button:hover {
  background: var(--accent-dark);
  transform: translateY(-1px);
}

@media (max-width: 780px) {
  .site-header,
  .video-section,
  .form-section {
    width: min(100% - 24px, var(--container));
  }

  .brand-text span {
    max-width: 210px;
  }

  .site-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .video-section {
    padding-top: 20px;
    padding-bottom: 54px;
  }

  .form-section {
    grid-template-columns: 1fr;
    padding: 58px 0 78px;
  }

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

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

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