/* Free-download modal: loaded on every page (home cards + Resources). Moved from pages.css. */
/* ------------------------------------------------- the free download form */
.modal{position:fixed;inset:0;z-index:60;display:grid;place-items:center;padding:var(--s-5)}
/* Any display declaration beats the UA's [hidden]{display:none}, so the dialog
   would sit open on load without this. */
.modal[hidden]{display:none}
/* ...and :target beats that again, so a free call to action still opens the
   form with no JavaScript at all. pages.js intercepts the click and handles
   focus properly when it is there. */
.modal[hidden]:target{display:grid}
.modal__scrim{position:absolute;inset:0;background:color-mix(in srgb,var(--ink) 55%,transparent)}
.modal__card{
  position:relative;width:min(100%,560px);
  padding:clamp(var(--s-6),3vw,var(--s-7));
  background:var(--paper);border-radius:var(--r-lg);box-shadow:var(--sh-lift);
  max-height:calc(100dvh - var(--s-6));overflow:auto
}
.modal__x{
  position:absolute;top:var(--s-4);right:var(--s-4);
  display:grid;place-items:center;width:38px;height:38px;
  border:0;background:none;cursor:pointer;color:var(--muted);border-radius:50%
}
.modal__x:hover{color:var(--accent);background:var(--sand)}
.modal__x svg{width:15px;height:15px}
.modal__card{text-align:center}
.modal__kicker{
  font-size:var(--fs-xs);letter-spacing:var(--tr-label);text-transform:uppercase;
  font-weight:var(--fw-semi);color:var(--accent);padding-inline:38px
}
.modal__kicker:empty{display:none}
.modal__h{text-wrap:balance}
.modal__h{margin-block-start:var(--s-3);font-size:clamp(1.25rem,2.2vw,1.625rem);line-height:1.2}
.modal__note{margin-block-start:var(--s-4);font-size:var(--fs-sm);line-height:1.6;color:var(--muted)}
/* The dialog is already a card; .pform's own card treatment would put a second
   one inside it, which the client's attachment does not have. */
.modal__form{
  margin-block-start:var(--s-6);grid-template-columns:1fr;text-align:center;
  padding:0;background:none;border:0;box-shadow:none
}
/* Labels centre over their fields with the rest of the dialog. */
/* Centred heading, left-aligned fields (client, 2026-09-21): a centred label
   floating over a full-width input is hard to pair up by eye. */
.modal__form .ffield{justify-items:stretch;text-align:start}
.modal__submit{width:100%;justify-content:center;margin-block-start:var(--s-5)}

/* ------------------------------------------------- step 2: download ready (2026-11-13) */
/* intro note is done once the form is sent */
.modal__card:has(.gform_confirmation_message) .modal__note{display:none}
.modal__form:has(.gform_confirmation_wrapper){margin-block-start:var(--s-5)}
.modal .gform_confirmation_wrapper{width:100%}
.modal .gform_confirmation_message{
  display:grid;justify-items:center;gap:var(--s-2);
  margin:0;padding:var(--s-6) var(--s-5) var(--s-5);
  font-family:var(--ff-body);font-size:var(--fs-sm);line-height:1.6;color:var(--muted);text-align:center;
  background:var(--sand);border:1px solid var(--line);border-radius:var(--r)
}
/* success check badge */
.modal .gform_confirmation_message::before{
  content:"";width:48px;height:48px;margin-block-end:var(--s-2);border-radius:50%;
  background:var(--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 24px no-repeat
}
.modal .gform_confirmation_message p{margin:0}
/* "Thank you!" line reads as a heading */
.modal .gform_confirmation_message strong:first-child,
.modal .gform_confirmation_message p:first-child strong{
  display:block;font-family:var(--ff-display);font-size:clamp(1.0625rem,1.6vw,1.1875rem);font-weight:var(--fw-semi);line-height:1.3;color:var(--ink)
}
.modal .gform_confirmation_message strong + br{display:none}
/* download link = solid button */
.modal .gform_confirmation_message a[href]{
  display:inline-flex;align-items:center;justify-content:center;gap:var(--s-3);
  width:100%;min-height:48px;margin-block-start:var(--s-4);padding:var(--s-3) var(--s-6);
  font-family:var(--ff-body);font-size:var(--fs-btn);font-weight:var(--fw-semi);line-height:1.2;letter-spacing:.04em;text-transform:uppercase;text-decoration:none;
  color:var(--on-accent);background:var(--accent);border:1px solid transparent;border-radius:var(--r-sm);
  transition:background var(--dur) var(--ease)
}
.modal .gform_confirmation_message a[href]::after{content:"\2193";transition:transform var(--dur) var(--ease)}
.modal .gform_confirmation_message a[href]:hover{background:var(--accent-press);color:var(--on-accent)}
.modal .gform_confirmation_message a[href]:hover::after{transform:translateY(2px)}
.modal .gform_confirmation_message a[href]:focus-visible{outline:2px solid var(--accent);outline-offset:3px}
/* no link: fallback message */
.modal .tci-free-fallback .gform_confirmation_message{color:var(--ink)}
.modal .tci-free-fallback .gform_confirmation_message::before{
  background:var(--sand-2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236e001f' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='M12 7v6M12 17h.01'/%3E%3C/svg%3E") center / 24px no-repeat
}
@media (max-width:480px){
  .modal .gform_confirmation_message{padding:var(--s-5) var(--s-4) var(--s-4)}
  .modal .gform_confirmation_message a[href]{padding-inline:var(--s-4)}
}
