/* Homepage forms and master modal */
.b2b {
  padding: 80px 0;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

.b2b-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

.b2b-badge {
  display: inline-block;
  background: var(--ink);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 5px 12px;
  margin-bottom: 20px;
}

.b2b h2 {
  font-family: var(--display);
  font-size: clamp(26px, 3.2vw, 42px);
  font-weight: 700;
  text-transform: uppercase;
  line-height: 1.05;
  margin-bottom: 16px;
}

.b2b h2 span {
  color: var(--accent);
}

.b2b-body {
  font-size: 15px;
  color: var(--ink-mid);
  margin-bottom: 24px;
  line-height: 1.65;
}

.b2b-points {
  list-style: none;
  display: grid;
  gap: 10px;
  margin-bottom: 28px;
}

.b2b-points li {
  padding-left: 26px;
  position: relative;
  font-size: 14px;
  color: var(--ink);
}

.b2b-points li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--ok);
  font-weight: 700;
  font-size: 15px;
  line-height: 1.4;
}

.b2b-form {
  background: var(--bg-card);
  border: 1.5px solid var(--border-strong);
  padding: 32px;
}

.b2b-form-title {
  font-family: var(--display);
  font-size: 20px;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 4px;
}

.b2b-form-sub {
  font-size: 13px;
  color: var(--ink-dim);
  margin-bottom: 20px;
}

.form-field {
  width: 100%;
  background: var(--bg);
  border: 1.5px solid var(--border);
  color: var(--ink);
  padding: 13px 14px;
  font-family: var(--body);
  font-size: 14px;
  margin-bottom: 10px;
  outline: none;
  transition: border-color 0.15s;
  border-radius: 0;
  resize: vertical;
  appearance: none;
  -webkit-appearance: none;
}

.form-field:focus {
  border-color: var(--accent);
}

.form-field::placeholder {
  color: var(--ink-dim);
}

.form-consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 4px 0 12px;
  color: var(--ink-mid);
  font-size: 12px;
  line-height: 1.35;
}

.form-consent input {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  margin: 1px 0 0;
  border: 1.5px solid var(--border-strong);
  border-radius: 2px;
  background: var(--bg);
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
}

.form-consent input:checked {
  border-color: var(--accent);
  background-color: var(--accent);
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 14 11' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1.5 5.5L5 9L12.5 1.5' fill='none' stroke='white' stroke-width='2.1' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 12px 10px;
}

.form-consent input:focus-visible {
  outline: 2px solid rgba(255,102,16,0.28);
  outline-offset: 2px;
}

.form-consent a {
  color: inherit;
  text-underline-offset: 3px;
}

.form-consent--dark {
  color: rgba(255,255,255,0.58);
}

.form-consent--dark input {
  border-color: rgba(255,255,255,0.38);
  background: transparent;
}

.form-consent--dark input:checked {
  border-color: var(--accent);
  background-color: var(--accent);
}

@media (min-width: 821px) {
  .b2b-form .form-consent,
  .lead-form .form-consent {
    align-items: center;
  }
}

.master-modal {
  position: fixed;
  inset: 0;
  z-index: 240;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(17,17,16,0.56);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
}

.master-modal[hidden] {
  display: none;
}

.master-modal.open {
  opacity: 1;
  pointer-events: auto;
}

.master-modal-panel {
  position: relative;
  width: min(460px, 100%);
  max-height: min(92vh, 720px);
  overflow-y: auto;
  background: var(--bg-card);
  border-top: 4px solid var(--accent);
  box-shadow: 0 28px 80px rgba(0,0,0,0.28);
  padding: 40px 32px 30px;
  transform: translateY(12px);
  transition: transform 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

.master-modal.open .master-modal-panel {
  transform: translateY(0);
}

.master-modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 36px;
  height: 36px;
  border: 1.5px solid var(--border);
  background: var(--bg-card);
  color: var(--ink);
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.master-modal-eyebrow {
  margin-bottom: 8px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.master-modal-title {
  margin-bottom: 4px;
  font-family: var(--display);
  font-size: 30px;
  font-weight: 700;
  line-height: 1.05;
  text-transform: uppercase;
}

.master-modal-sub {
  margin-bottom: 22px;
  color: var(--ink-mid);
  font-size: 14px;
  line-height: 1.45;
}

.master-modal-form .form-field {
  margin-bottom: 10px;
  padding: 14px 15px;
  min-height: 46px;
}

.master-modal-form textarea.form-field {
  min-height: 78px;
}

.master-modal-select {
  background-image:
    linear-gradient(45deg, transparent 50%, var(--ink-dim) 50%),
    linear-gradient(135deg, var(--ink-dim) 50%, transparent 50%);
  background-position:
    calc(100% - 20px) 20px,
    calc(100% - 14px) 20px;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
}

.master-modal-submit {
  margin: 10px 0 14px;
  min-height: 50px;
  font-size: 15px;
}

.master-modal-trust {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
  color: var(--ink-mid);
  font-size: 13px;
}

.master-modal-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ok);
  box-shadow: 0 0 0 3px rgba(30,138,76,0.18);
  flex: 0 0 auto;
  animation: blink 2s infinite;
}

.master-modal-fine {
  margin-top: 10px;
  color: var(--ink-dim);
  font-size: 11px;
  line-height: 1.45;
}

.success-modal-panel {
  max-height: min(92vh, 720px);
}

.success-modal-title {
  margin-bottom: 8px;
  line-height: 1.05;
}

.success-modal-sub {
  margin-bottom: 18px;
}

.success-modal-note {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
  padding: 14px 15px;
  background: rgba(30,138,76,0.1);
  color: var(--ink);
  font-size: 14px;
  line-height: 1.45;
}

.success-modal-note strong {
  font-weight: 700;
}

.success-modal-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  border-radius: 50%;
  background: var(--ok);
  color: #fff;
}

.success-modal-check svg {
  width: 20px;
  height: 20px;
}

.success-modal-after {
  margin-bottom: 18px;
  color: var(--ink-mid);
  font-size: 13px;
  line-height: 1.45;
}

.success-modal-primary,
.success-modal-call {
  min-height: 50px;
  font-size: 15px;
}

.success-modal-call {
  margin-top: 10px;
  border-color: var(--accent);
  color: var(--accent);
}

.success-modal-fine {
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
  font-size: 11px;
}

.success-modal-fine a {
  color: inherit;
  text-underline-offset: 3px;
}

.lead {
  padding: 80px 0;
  background: #3a3630;
}

.lead-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.lead h2 {
  font-family: var(--display);
  font-size: clamp(26px, 3.5vw, 48px);
  font-weight: 700;
  text-transform: uppercase;
  line-height: 1.05;
  color: #fff;
  margin-bottom: 12px;
}

.lead-sub {
  font-size: 15px;
  color: rgba(255,255,255,0.62);
  line-height: 1.6;
}

.lead-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.lead .lead-form {
  background: transparent;
  border: 0;
  padding: 0;
  position: static;
}

.lead .lead-form::before {
  content: none;
}

.lead-form .form-field {
  background: rgba(255,255,255,0.08);
  border-color: rgba(255,255,255,0.2);
  color: #fff;
}

.lead-form .form-field::placeholder {
  color: rgba(255,255,255,0.42);
}

.lead-form .form-field:focus {
  border-color: var(--accent);
}

.lead-form .btn-primary {
  font-size: 16px;
  padding: 16px 24px;
}

.lead-fine {
  font-size: 11px;
  color: rgba(255,255,255,0.35);
  line-height: 1.5;
}

@media (max-width: 820px) {
  .b2b-inner {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .lead-inner {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

@media (max-width: 640px) {
  .b2b,
  .lead {
    padding: 56px 0;
  }

  .master-modal {
    padding: 14px;
    align-items: start;
    padding-top: 18px;
  }

  .master-modal-panel {
    width: 100%;
    max-height: calc(100vh - 28px);
    padding: 38px 24px 24px;
  }

  .master-modal-title {
    font-size: 27px;
  }

  .master-modal-sub {
    font-size: 13px;
  }

  .success-modal-title {
    margin-bottom: 8px;
  }

  .success-modal-sub {
    margin-bottom: 16px;
  }

  .success-modal-note {
    gap: 10px;
    margin-bottom: 16px;
    padding: 12px;
    font-size: 13px;
  }

  .success-modal-check {
    width: 34px;
    height: 34px;
    flex-basis: 34px;
  }

  .success-modal-check svg {
    width: 18px;
    height: 18px;
  }

  .success-modal-after {
    margin-bottom: 16px;
    font-size: 14px;
  }

  .success-modal-fine {
    margin-top: 18px;
  }

  .b2b-form {
    padding: 20px;
  }

  .lead-inner {
    gap: 24px;
  }

  .lead h2 {
    margin-bottom: 8px;
  }
}
