:root {
  --ais-navy: #071631;
  --ais-green: #42b722;
  --ais-green-dark: #178d16;
  --ais-border: #d8dde5;
  --ais-muted: #5b6370;
}

html.ais-demo-open,
html.ais-demo-open body { overflow: hidden; }

.ais-demo-overlay[hidden] { display: none !important; }
.ais-demo-overlay {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(2, 11, 27, .78);
  opacity: 0;
  transition: opacity .18s ease;
  box-sizing: border-box;
}
.ais-demo-overlay.is-open { opacity: 1; }

.ais-demo-modal {
  width: min(920px, 100%);
  max-height: calc(100vh - 48px);
  overflow-y: auto;
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 28px 90px rgba(0, 0, 0, .42);
  transform: translateY(10px) scale(.985);
  transition: transform .18s ease;
  position: relative;
  color: #0a1225;
  font-family: 'Roboto', sans-serif !important;
}
.ais-demo-overlay.is-open .ais-demo-modal { transform: translateY(0) scale(1); }

.ais-demo-header {
  height: 150px;
  overflow: hidden;
  border-radius: 18px 18px 0 0;
  background: #071631;
}
.ais-demo-header img { width: 100%; height: 100%; object-fit: cover; display: block; }

.ais-demo-close {
  position: absolute;
  top: 18px;
  right: 19px;
  z-index: 2;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 50%;
  background: rgba(0, 0, 0, .18);
  color: #fff;
  font-size: 38px;
  line-height: 38px;
  font-weight: 200;
  cursor: pointer;
}
.ais-demo-close:hover { background: rgba(0, 0, 0, .35); }

.ais-demo-body { padding: 32px 48px 30px; }
.ais-demo-body h2 { font-family: 'Roboto', sans-serif !important; margin: 0; color: var(--ais-navy) !important; font-size: 42px; line-height: 1.05; font-weight: 800; letter-spacing: -1px; }
.ais-demo-kicker { margin-top: 8px; color: var(--ais-green); font-size: 26px; line-height: 1.2; font-weight: 500; }
.ais-demo-intro { margin: 13px 0 24px; max-width: 700px; color: #1b2230; font-size: 18px; line-height: 1.48; }
#ais-demo-form { border-top: 1px solid #e2e5ea; padding-top: 24px; }

.ais-demo-grid { display: grid; gap: 28px; }
.ais-demo-grid-2 { grid-template-columns: 1fr 1fr; }
.ais-demo-field { margin-bottom: 23px; }
.ais-demo-field label { display: block; margin-bottom: 8px; color: #101827; font-size: 16px; font-weight: 700; }
.ais-demo-field label span { color: var(--ais-green); }
.ais-demo-field label em { color: #5e6470; font-style: normal; font-weight: 400; }
.ais-demo-field input,
.ais-demo-field textarea {
  width: 100%;
  border: 1px solid #cfd5df;
  border-radius: 8px;
  padding: 13px 16px;
  background: #fff;
  color: #111827;
  font: inherit;
  font-size: 16px;
  box-sizing: border-box;
  outline: none;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.ais-demo-field input:focus,
.ais-demo-field textarea:focus { border-color: #53b935; box-shadow: 0 0 0 3px rgba(67, 183, 34, .13); }
.ais-demo-field textarea { resize: vertical; min-height: 88px; }
.ais-demo-honeypot { position: absolute !important; left: -9999px !important; opacity: 0 !important; pointer-events: none !important; }

.ais-demo-note {
  display: flex;
  gap: 16px;
  align-items: center;
  margin: 2px 0 18px;
  padding: 15px 18px;
  background: linear-gradient(90deg, rgba(67, 183, 34, .08), rgba(67, 183, 34, .035));
  border-radius: 8px;
  color: #151d2a;
  font-size: 15px;
  line-height: 1.4;
}
.ais-demo-clock {
  flex: 0 0 38px;
  width: 38px;
  height: 38px;
  border: 3px solid #2d9f26;
  border-radius: 50%;
  position: relative;
}
.ais-demo-clock:before { content: ''; position: absolute; left: 17px; top: 7px; width: 2px; height: 11px; background: #2d9f26; }
.ais-demo-clock:after { content: ''; position: absolute; left: 17px; top: 17px; width: 10px; height: 2px; background: #2d9f26; transform: rotate(35deg); transform-origin: left center; }

.ais-demo-submit {
  width: 100%;
  border: 0;
  border-radius: 8px;
  padding: 18px 22px;
  background: linear-gradient(#49c124, #189219);
  color: #fff;
  font-weight: 800;
  font-size: 24px;
  letter-spacing: .2px;
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.16);
}
.ais-demo-submit:hover { filter: brightness(1.04); }
.ais-demo-submit:disabled { opacity: .65; cursor: wait; }
.ais-demo-arrow { margin-left: 18px; font-size: 38px; line-height: 0; vertical-align: -3px; font-weight: 300; }
.ais-demo-submit.is-loading span:first-child:after { content: '…'; }

.ais-demo-status { min-height: 20px; margin-top: 12px; font-size: 14px; font-weight: 600; text-align: center; }
.ais-demo-status.is-success { color: #188117; }
.ais-demo-status.is-error { color: #b42318; }
.ais-demo-privacy { display: flex; gap: 10px; justify-content: center; align-items: flex-start; margin-top: 10px; color: #5b6370; font-size: 14px; line-height: 1.45; text-align: left; }
.ais-demo-privacy a { color: #278f1d; text-decoration: underline; }
.ais-demo-lock { font-size: 14px; }

@media (max-width: 700px) {
  .ais-demo-overlay { padding: 10px; align-items: flex-start; }
  .ais-demo-modal { max-height: calc(100vh - 20px); border-radius: 14px; }
  .ais-demo-header { height: 108px; border-radius: 14px 14px 0 0; }
  .ais-demo-body { padding: 24px 20px 22px; }
  .ais-demo-body h2 { font-size: 31px; }
  .ais-demo-kicker { font-size: 20px; }
  .ais-demo-intro { font-size: 16px; }
  .ais-demo-grid-2 { grid-template-columns: 1fr; gap: 0; }
  .ais-demo-field { margin-bottom: 17px; }
  .ais-demo-submit { font-size: 20px; }
  .ais-demo-close { top: 10px; right: 10px; width: 36px; height: 36px; font-size: 31px; line-height: 31px; }
}

@media (max-width: 700px) {
  .ais-demo-body {
    padding: 23px 20px 60px;
  }
  .ais-demo-header img {
    object-fit: contain;
  }
}
