:root {
  --agclp-navy: #0f2f4f;
  --agclp-navy-dark: #09243d;
  --agclp-teal: #07958f;
  --agclp-teal-dark: #046f6b;
  --agclp-aqua: #8fe5df;
  --agclp-mint: #e8f8f6;
  --agclp-text: #263443;
  --agclp-muted: #667580;
  --agclp-border: #dfe9ed;
  --agclp-white: #ffffff;
}

.agclp-overlay,
.agclp-overlay *,
.agclp-overlay *::before,
.agclp-overlay *::after {
  box-sizing: border-box;
}

.agclp-overlay {
  position: fixed;
  inset: 0;
  z-index: 2147483000;
  display: none;
  align-items: center;
  justify-content: center;
  overflow-y: auto;
  padding: 24px;
  background: rgba(9, 36, 61, 0.76);
  font-family: Arial, Helvetica, sans-serif;
  backdrop-filter: blur(7px);
  -webkit-backdrop-filter: blur(7px);
}

.agclp-overlay.is-visible {
  display: flex;
  animation: agclp-fade 0.22s ease both;
}

.agclp-dialog {
  position: relative;
  width: min(720px, 100%);
  max-height: calc(100vh - 48px);
  overflow-y: auto;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 28px;
  background: var(--agclp-white);
  box-shadow: 0 34px 100px rgba(0, 0, 0, 0.29);
  animation: agclp-enter 0.3s ease both;
  scrollbar-width: thin;
  scrollbar-color: rgba(15, 47, 79, 0.35) transparent;
}

.agclp-dialog::-webkit-scrollbar {
  width: 8px;
}

.agclp-dialog::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(15, 47, 79, 0.32);
}

.agclp-header {
  position: relative;
  padding: 34px 44px 28px;
  background:
    radial-gradient(
      circle at 92% 8%,
      rgba(143, 229, 223, 0.18),
      transparent 35%
    ),
    linear-gradient(135deg, var(--agclp-navy-dark), var(--agclp-navy));
  color: #ffffff;
}

.agclp-close {
  position: absolute;
  top: 17px;
  right: 17px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.27);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.10);
  color: #ffffff;
  cursor: pointer;
  font: 400 27px/1 Arial, Helvetica, sans-serif;
}

.agclp-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 15px;
  color: var(--agclp-aqua);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.9px;
  text-transform: uppercase;
}

.agclp-eyebrow::before {
  content: "";
  width: 27px;
  height: 2px;
  background: var(--agclp-aqua);
}

.agclp-header h2 {
  max-width: 590px;
  margin: 0;
  color: #ffffff;
  font-size: clamp(32px, 4.3vw, 43px);
  font-weight: 800;
  letter-spacing: -1.4px;
  line-height: 1.04;
}

.agclp-header p {
  max-width: 590px;
  margin: 13px 0 0;
  color: rgba(255, 255, 255, 0.79);
  font-size: 15px;
  line-height: 1.68;
}

.agclp-content {
  padding: 22px 44px 27px;
}

.agclp-privacy-note {
  margin-bottom: 15px;
  padding: 11px 14px;
  border-left: 4px solid var(--agclp-teal);
  background: var(--agclp-mint);
  color: var(--agclp-navy-dark);
  font-size: 12px;
  line-height: 1.62;
}

.agclp-form-area .ff-el-group {
  margin-bottom: 10px !important;
}

.agclp-form-area .ff-el-input--label label {
  color: var(--agclp-navy-dark) !important;
  font-size: 13px !important;
  font-weight: 800 !important;
}

.agclp-form-area .ff-el-form-control {
  width: 100% !important;
  min-height: 44px !important;
  padding: 10px 13px !important;
  border: 1px solid var(--agclp-border) !important;
  border-radius: 12px !important;
  background: #ffffff !important;
  color: var(--agclp-text) !important;
  box-shadow: none !important;
  font-family: Arial, Helvetica, sans-serif !important;
  font-size: 15px !important;
}

.agclp-form-area .ff-el-form-control:focus {
  border-color: var(--agclp-teal) !important;
  box-shadow: 0 0 0 4px rgba(7, 149, 143, 0.11) !important;
}

.agclp-form-area .ff-btn-submit,
.agclp-form-area button[type="submit"] {
  width: 100% !important;
  min-height: 51px !important;
  padding: 13px 20px !important;
  border: 0 !important;
  border-radius: 999px !important;
  background: linear-gradient(
    135deg,
    var(--agclp-teal),
    #0aaba3
  ) !important;
  color: #ffffff !important;
  cursor: pointer !important;
  font-family: Arial, Helvetica, sans-serif !important;
  font-size: 13px !important;
  font-weight: 900 !important;
}

.agclp-form-area .ff-el-form-check-label,
.agclp-form-area .ff-el-form-check-label span,
.agclp-form-area .ff_t_c {
  color: var(--agclp-muted) !important;
  font-size: 12px !important;
  line-height: 1.55 !important;
}

.agclp-form-area .text-danger,
.agclp-form-area .error {
  color: #a63c34 !important;
  font-size: 12px !important;
}

.agclp-form-area .ff-message-success {
  margin-top: 12px !important;
  padding: 15px !important;
  border: 0 !important;
  border-left: 4px solid var(--agclp-teal) !important;
  background: var(--agclp-mint) !important;
  color: var(--agclp-navy-dark) !important;
}

.agclp-later {
  display: block;
  margin: 15px auto 0;
  padding: 7px 14px;
  border: 0;
  background: transparent;
  color: var(--agclp-muted);
  cursor: pointer;
  font: 700 12px/1.4 Arial, Helvetica, sans-serif;
  text-decoration: underline;
  text-underline-offset: 3px;
}

body.agclp-lock {
  overflow: hidden !important;
}

.agclp-overlay button:focus-visible,
.agclp-overlay input:focus-visible,
.agclp-overlay a:focus-visible {
  outline: 3px solid rgba(7, 149, 143, 0.30);
  outline-offset: 3px;
}

@keyframes agclp-fade {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes agclp-enter {
  from {
    opacity: 0;
    transform: translateY(18px) scale(0.98);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@media (max-width: 640px) {
  .agclp-overlay {
    align-items: flex-end;
    padding: 0;
  }

  .agclp-dialog {
    width: 100%;
    max-height: 94vh;
    border-radius: 24px 24px 0 0;
  }

  .agclp-header {
    padding: 58px 23px 28px;
  }

  .agclp-header h2 {
    font-size: 35px;
  }

  .agclp-content {
    padding: 25px 23px 28px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .agclp-overlay,
  .agclp-dialog,
  .agclp-overlay * {
    animation: none !important;
    transition: none !important;
  }
}


/* Required-field safety-net errors */
.agclp-form-area .agclp-field-invalid .ff-el-form-control,
.agclp-form-area .agclp-field-invalid input[type="checkbox"] {
  border-color: #c63c32 !important;
  box-shadow: 0 0 0 3px rgba(198, 60, 50, 0.10) !important;
}

.agclp-required-error {
  margin-top: 6px;
  color: #c63c32;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.45;
}

.agclp-form-area .ff-el-is-error .ff-el-form-control {
  border-color: #c63c32 !important;
  box-shadow: 0 0 0 3px rgba(198, 60, 50, 0.10) !important;
}

.agclp-form-area .ff-el-is-error .text-danger,
.agclp-form-area .ff-el-is-error .error {
  display: block !important;
  margin-top: 6px !important;
  color: #c63c32 !important;
  font-weight: 700 !important;
}

/* =========================================================
   ALL-DEVICE RESPONSIVE STABILITY — VERSION 1.2.1
   CSS only. Popup logic and Fluent Forms behaviour unchanged.
========================================================= */

.agclp-overlay {
  overscroll-behavior: contain;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

.agclp-dialog {
  max-width: 720px;
  max-height: calc(100vh - 48px);
  max-height: calc(100svh - 48px);
  max-height: calc(100dvh - 48px);
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-gutter: stable;
}

.agclp-header,
.agclp-content,
.agclp-form-area,
.agclp-form-area form,
.agclp-form-area .ff-el-group,
.agclp-form-area .ff-el-input--content {
  min-width: 0;
  max-width: 100%;
}

.agclp-header h2,
.agclp-header p,
.agclp-privacy-note,
.agclp-form-area label,
.agclp-form-area .ff-el-form-check-label,
.agclp-form-area .ff-el-form-check-label span,
.agclp-form-area .ff_t_c,
.agclp-required-error {
  overflow-wrap: break-word;
  word-break: normal;
}

.agclp-form-area input,
.agclp-form-area select,
.agclp-form-area textarea,
.agclp-form-area button {
  max-width: 100% !important;
}

.agclp-form-area textarea.ff-el-form-control {
  min-height: 100px !important;
  resize: vertical;
}

/* Tablet and smaller laptop windows. */
@media (max-width: 900px) {
  .agclp-overlay {
    padding: 18px;
  }

  .agclp-dialog {
    width: min(680px, 100%);
    max-height: calc(100vh - 36px);
    max-height: calc(100svh - 36px);
    max-height: calc(100dvh - 36px);
    border-radius: 25px;
  }

  .agclp-header {
    padding: 32px 36px 27px;
  }

  .agclp-header h2 {
    font-size: clamp(32px, 5.2vw, 41px);
  }

  .agclp-content {
    padding: 22px 36px 27px;
  }
}

/* Phones and narrow portrait tablets. */
@media (max-width: 640px) {
  .agclp-overlay {
    align-items: center;
    justify-content: center;
    padding:
      max(8px, env(safe-area-inset-top))
      max(8px, env(safe-area-inset-right))
      max(8px, env(safe-area-inset-bottom))
      max(8px, env(safe-area-inset-left));
  }

  .agclp-dialog {
    width: 100%;
    max-height: calc(100vh - 16px);
    max-height: calc(100svh - 16px);
    max-height: calc(100dvh - 16px);
    border-radius: 22px;
  }

  .agclp-dialog::-webkit-scrollbar {
    width: 5px;
  }

  .agclp-header {
    padding: 45px 20px 23px;
  }

  .agclp-close {
    top: 11px;
    right: 11px;
    width: 40px;
    height: 40px;
    font-size: 25px;
  }

  .agclp-eyebrow {
    gap: 8px;
    max-width: calc(100% - 48px);
    margin-bottom: 13px;
    font-size: 10px;
    line-height: 1.35;
    letter-spacing: 0.72px;
  }

  .agclp-eyebrow::before {
    flex: 0 0 24px;
    width: 24px;
  }

  .agclp-header h2 {
    max-width: 100%;
    font-size: clamp(28px, 8.4vw, 34px);
    line-height: 1.07;
    letter-spacing: -0.9px;
  }

  .agclp-header p {
    max-width: 100%;
    margin-top: 14px;
    font-size: 14px;
    line-height: 1.58;
  }

  .agclp-content {
    padding: 20px 20px 24px;
  }

  .agclp-privacy-note {
    margin-bottom: 17px;
    padding: 12px 13px;
    font-size: 11.5px;
    line-height: 1.55;
  }

  /*
   * Stack any Fluent Forms multi-column row on phones without changing
   * field names, validation, or form submission.
   */
  .agclp-form-area .ff-t-container,
  .agclp-form-area .ff-el-group.ff_list_buttons,
  .agclp-form-area .ff-el-group .ff-el-input--content {
    max-width: 100% !important;
  }

  .agclp-form-area .ff-t-container {
    display: block !important;
  }

  .agclp-form-area .ff-t-cell {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
  }

  .agclp-form-area .ff-el-group {
    margin-bottom: 13px !important;
  }

  .agclp-form-area .ff-el-input--label label {
    font-size: 13px !important;
    line-height: 1.35 !important;
  }

  /*
   * 16px prevents automatic browser zoom when an input receives focus on
   * iOS and improves touch readability on Android.
   */
  .agclp-form-area .ff-el-form-control {
    min-height: 49px !important;
    padding: 12px 13px !important;
    border-radius: 13px !important;
    font-size: 16px !important;
    line-height: 1.35 !important;
  }

  .agclp-form-area textarea.ff-el-form-control {
    min-height: 105px !important;
  }

  .agclp-form-area input[type="checkbox"],
  .agclp-form-area input[type="radio"] {
    min-width: 18px;
    min-height: 18px;
  }

  .agclp-form-area .ff-el-form-check-label,
  .agclp-form-area .ff-el-form-check-label span,
  .agclp-form-area .ff_t_c {
    font-size: 11.5px !important;
    line-height: 1.5 !important;
  }

  .agclp-form-area .ff-btn-submit,
  .agclp-form-area button[type="submit"] {
    min-height: 50px !important;
    padding: 13px 17px !important;
    font-size: 13px !important;
  }

  .agclp-later {
    margin-top: 13px;
    min-height: 42px;
    padding: 9px 14px;
  }
}

/* Common 360–430px phones. */
@media (max-width: 430px) {
  .agclp-overlay {
    padding:
      max(6px, env(safe-area-inset-top))
      max(6px, env(safe-area-inset-right))
      max(6px, env(safe-area-inset-bottom))
      max(6px, env(safe-area-inset-left));
  }

  .agclp-dialog {
    max-height: calc(100vh - 12px);
    max-height: calc(100svh - 12px);
    max-height: calc(100dvh - 12px);
    border-radius: 19px;
  }

  .agclp-header {
    padding: 42px 17px 21px;
  }

  .agclp-close {
    top: 9px;
    right: 9px;
    width: 38px;
    height: 38px;
  }

  .agclp-eyebrow {
    max-width: calc(100% - 42px);
    margin-bottom: 11px;
    font-size: 9.5px;
    letter-spacing: 0.62px;
  }

  .agclp-eyebrow::before {
    flex-basis: 21px;
    width: 21px;
  }

  .agclp-header h2 {
    font-size: clamp(27px, 8.2vw, 32px);
    line-height: 1.08;
  }

  .agclp-header p {
    margin-top: 12px;
    font-size: 13.5px;
    line-height: 1.55;
  }

  .agclp-content {
    padding: 18px 17px 21px;
  }

  .agclp-privacy-note {
    padding: 11px 12px;
    border-left-width: 3px;
    font-size: 11px;
  }
}

/* Very small phones and high browser zoom. */
@media (max-width: 360px) {
  .agclp-header {
    padding: 40px 14px 19px;
  }

  .agclp-content {
    padding: 16px 14px 19px;
  }

  .agclp-header h2 {
    font-size: 26px;
    letter-spacing: -0.65px;
  }

  .agclp-header p {
    font-size: 13px;
  }

  .agclp-eyebrow {
    font-size: 9px;
  }

  .agclp-form-area .ff-el-form-control {
    padding-left: 11px !important;
    padding-right: 11px !important;
  }
}

/* Short laptop displays and landscape mobile devices. */
@media (max-height: 640px) {
  .agclp-overlay {
    align-items: center;
    padding: 7px;
  }

  .agclp-dialog {
    max-height: calc(100vh - 14px);
    max-height: calc(100svh - 14px);
    max-height: calc(100dvh - 14px);
    border-radius: 18px;
  }

  .agclp-header {
    padding-top: 39px;
    padding-bottom: 17px;
  }

  .agclp-close {
    top: 8px;
    right: 8px;
    width: 36px;
    height: 36px;
  }

  .agclp-eyebrow {
    margin-bottom: 9px;
  }

  .agclp-header h2 {
    font-size: clamp(26px, 6vw, 33px);
  }

  .agclp-header p {
    margin-top: 9px;
    font-size: 12.5px;
    line-height: 1.48;
  }

  .agclp-content {
    padding-top: 15px;
    padding-bottom: 17px;
  }

  .agclp-privacy-note {
    margin-bottom: 12px;
    padding-top: 9px;
    padding-bottom: 9px;
  }

  .agclp-form-area .ff-el-group {
    margin-bottom: 9px !important;
  }
}

/* Landscape phones receive a wider, compact dialog. */
@media (orientation: landscape) and (max-height: 500px) {
  .agclp-overlay {
    padding:
      max(4px, env(safe-area-inset-top))
      max(6px, env(safe-area-inset-right))
      max(4px, env(safe-area-inset-bottom))
      max(6px, env(safe-area-inset-left));
  }

  .agclp-dialog {
    width: min(680px, 100%);
    max-height: calc(100dvh - 8px);
  }

  .agclp-header {
    padding: 37px 20px 15px;
  }

  .agclp-header h2 {
    font-size: clamp(25px, 5vw, 31px);
  }

  .agclp-header p {
    max-width: 620px;
  }

  .agclp-content {
    padding: 14px 20px 16px;
  }
}

