/*
 * The Innovation Foundry join and waiting-list forms, in the Active Digital AI look.
 * Ported from site/css/site.css and scoped to .foundry-forms. The class names, data-* attributes and
 * messages are the ones site/js/forms.js (assets/js/foundry-forms.js) relies on, so do not rename them.
 */

.foundry-forms form { margin: 0; font-family: Poppins, system-ui, sans-serif; color: #151A2D; }
.foundry-forms .required-note { margin: 0 0 20px; font-size: 14px; color: #5B6273; }
.foundry-forms .field { margin: 0 0 20px; }
.foundry-forms fieldset { border: 0; margin: 0 0 20px; padding: 0; min-width: 0; }
.foundry-forms .field > label,
.foundry-forms .field legend { display: block; font-size: 14px; font-weight: 600; margin: 0 0 8px; padding: 0; color: #151A2D; }
.foundry-forms .req { color: #B42318; font-weight: 600; margin-left: 2px; }

.foundry-forms input[type="text"],
.foundry-forms input[type="email"],
.foundry-forms textarea,
.foundry-forms select {
  display: block; width: 100%;
  font: 400 16px Poppins, sans-serif; color: #151A2D;
  background: #F2F3F7; border: 1.5px solid #D9DCE3; border-radius: 14px;
  min-height: 52px; padding: 12px 16px;
}
.foundry-forms textarea { min-height: 120px; resize: vertical; }
.foundry-forms input::placeholder, .foundry-forms textarea::placeholder { color: #6F7685; }
.foundry-forms input[type="text"]:focus, .foundry-forms input[type="email"]:focus, .foundry-forms textarea:focus, .foundry-forms select:focus {
  border-color: #2F6FC8; outline: none; box-shadow: 0 0 0 3px rgba(47,111,200,.25);
}
.foundry-forms .is-invalid input[type="text"],
.foundry-forms .is-invalid input[type="email"],
.foundry-forms .is-invalid textarea { border-color: #B42318; border-width: 2px; }

/* Radio tiles (tier) */
.foundry-forms .tiles { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); }
.foundry-forms .tile { position: relative; display: block; cursor: pointer; }
.foundry-forms .tile input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.foundry-forms .tile-body {
  position: relative; display: flex; flex-direction: column; gap: 2px; height: 100%;
  min-height: 52px; padding: 14px 16px 14px 46px;
  border: 1.5px solid #D9DCE3; border-radius: 20px; background: #fff;
}
.foundry-forms .tile-body::before {
  content: ""; position: absolute; left: 16px; top: 17px; width: 18px; height: 18px;
  border: 2px solid #8A90A0; border-radius: 50%; background: #fff;
}
.foundry-forms .tile-name { font-weight: 600; }
.foundry-forms .tile-price { font-size: 14px; color: #5B6273; line-height: 1.45; }
.foundry-forms .tile input:checked + .tile-body { border-color: #C2551F; background: #FBE3D6; }
.foundry-forms .tile input:checked + .tile-body::before { border-color: #C2551F; background: radial-gradient(circle, #C2551F 0 45%, #fff 50%); }
.foundry-forms .tile input:focus-visible + .tile-body { outline: 3px solid #2F6FC8; outline-offset: 3px; }

/* Plain radio lists and tick boxes */
.foundry-forms .choices { display: grid; gap: 8px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); }
.foundry-forms .choice,
.foundry-forms .tick { display: flex; align-items: flex-start; gap: 12px; cursor: pointer; font-size: 15px; line-height: 1.5; }
.foundry-forms .choice { padding: 12px 14px; border: 1.5px solid #D9DCE3; border-radius: 14px; background: #fff; }
.foundry-forms .tick { padding: 4px 0; font-weight: 500; }
.foundry-forms .choice input,
.foundry-forms .tick input { flex: none; width: 20px; height: 20px; margin: 2px 0 0; accent-color: #C2551F; }

.foundry-forms .hint,
.foundry-forms .small { font-size: 14px; color: #5B6273; margin: 0 0 20px; }
.foundry-forms a { color: #B4501C; }
.foundry-forms a:hover { color: #8A3410; }

.foundry-forms .error-msg { display: block; color: #B42318; font-size: 14px; font-weight: 500; margin-top: 6px; }
.foundry-forms .error-msg[hidden] { display: none; }

/* The notice under the button: an information notice (blue), or an error (red) */
.foundry-forms .notice {
  margin-top: 16px; padding: 14px 16px 14px 18px; border-radius: 14px;
  background: #EEF1F6; border: 1.5px solid #C9CEDA; border-left: 5px solid #2F6FC8;
  color: #151A2D; font: 500 14px/1.55 Poppins, sans-serif;
}
.foundry-forms .notice[hidden] { display: none; }
.foundry-forms .notice-error { background: #FDECEA; border-color: #F3C7C2; border-left-color: #B42318; }
.foundry-forms .notice p { margin: 0; }

/* Honeypot: off screen, not display:none, so simple bots still fill it */
.foundry-forms .hp { position: absolute !important; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

/* The submit button, in the theme's orange pill */
.foundry-forms .btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 26px; border-radius: 999px; border: 0; cursor: pointer;
  font: 600 15px/1.2 Poppins, sans-serif; text-decoration: none;
}
.foundry-forms .btn-primary { background: #C2551F; color: #fff; }
.foundry-forms .btn-primary:hover { background: #A2461A; color: #fff; }
.foundry-forms .btn-primary:disabled { opacity: .7; cursor: wait; }
.foundry-forms .btn-block { width: 100%; }
