/* Forms & Modals */

/* ============================================================
   APPLY / FORMS SECTION
   ============================================================ */
.apply { padding: clamp(80px, 12vw, 140px) clamp(24px, 6vw, 80px); background: var(--brn-dark); }
.apply-header { text-align: center; margin-bottom: 60px; }
.apply-eyebrow { font-size: 0.7rem; font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase; color: var(--brn-blue-accent); margin-bottom: 16px; }
.apply-title { font-family: 'Instrument Sans', sans-serif; font-size: clamp(1.8rem, 3.5vw, 2.8rem); font-weight: 700; letter-spacing: -0.03em; }
.apply-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; max-width: 900px; margin: 0 auto; }
.apply-card { background: rgba(255,255,255,0.02); border: 1px solid var(--border-color); border-radius: var(--radius); padding: 36px 28px; text-align: center; cursor: pointer; transition: all 0.4s var(--ease-smooth); }
.apply-card:hover { border-color: var(--border-hover); background: rgba(255,255,255,0.04); transform: translateY(-4px); box-shadow: 0 12px 40px rgba(0,0,0,0.3); }
.apply-card-icon { width: 56px; height: 56px; border-radius: 14px; background: var(--brn-blue-glow); display: flex; align-items: center; justify-content: center; margin: 0 auto 20px; color: var(--brn-blue-accent); }
.apply-card-icon svg { width: 24px; height: 24px; }
.apply-card-title { font-family: 'Instrument Sans', sans-serif; font-size: 1.05rem; font-weight: 700; margin-bottom: 8px; }
.apply-card-desc { font-size: 0.78rem; color: var(--text-secondary); line-height: 1.6; margin-bottom: 20px; }
.apply-card-btn { display: inline-flex; align-items: center; gap: 6px; padding: 10px 24px; border-radius: var(--radius); background: transparent; border: 1px solid rgba(91,155,255,0.2); color: var(--brn-blue-accent); font-size: 0.75rem; font-weight: 600; cursor: pointer; transition: all 0.3s; }
.apply-card-btn:hover { background: rgba(91,155,255,0.08); border-color: var(--brn-blue-accent); }
/* ============================================================
   MODAL
   ============================================================ */
.modal-overlay { position: fixed; inset: 0; z-index: 10000; background: rgba(0,0,0,0.7); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); display: none; align-items: center; justify-content: center; padding: 24px; }
.modal-overlay.open { display: flex; animation: fadeIn 0.3s; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.modal { background: var(--brn-surface); border: 1px solid var(--border-color); border-radius: var(--radius); max-width: 500px; width: 100%; max-height: 90vh; overflow-y: auto; padding: 40px; position: relative; animation: slideUp 0.3s var(--ease-out); }
@keyframes slideUp { from { transform: translateY(24px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.modal-close { position: absolute; top: 16px; right: 16px; background: none; border: none; color: var(--text-muted); cursor: pointer; padding: 4px; transition: color 0.2s; }
.modal-close:hover { color: var(--text-primary); }
.modal-close svg { width: 20px; height: 20px; }
.modal-title { font-family: 'Instrument Sans', sans-serif; font-size: 1.3rem; font-weight: 700; margin-bottom: 8px; }
.modal-desc { font-size: 0.82rem; color: var(--text-secondary); margin-bottom: 28px; line-height: 1.6; }
.form-group { margin-bottom: 20px; }
.form-label { display: block; font-size: 0.72rem; font-weight: 600; color: var(--text-secondary); letter-spacing: 0.04em; margin-bottom: 6px; }
.form-input, .form-textarea, .form-select { width: 100%; padding: 12px 16px; background: rgba(255,255,255,0.03); border: 1px solid var(--border-color); border-radius: var(--radius-sm); color: var(--text-primary); font-family: inherit; font-size: 0.85rem; transition: border-color 0.2s; outline: none; }
.form-input:focus, .form-textarea:focus, .form-select:focus { border-color: var(--brn-blue-accent); }
.form-textarea { min-height: 100px; resize: vertical; }
.form-select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%23555' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 16px center; padding-right: 40px; }
.form-submit { display: block; width: 100%; padding: 14px; background: var(--brn-blue-accent); color: #fff; font-size: 0.85rem; font-weight: 700; border: none; border-radius: var(--radius); cursor: pointer; transition: all 0.3s; }
.form-submit:hover { background: #6aadff; transform: translateY(-1px); box-shadow: 0 0 30px rgba(91,155,255,0.2); }

/* --- HubSpot Embedded Form Styles (css:"" = inline, no iframe) --- */
.modal .hs-form { font-family: 'Inter', system-ui, sans-serif; }

/* Layout: force 2-col grid on all fieldsets */
.modal .hs-form fieldset {
  max-width: 100% !important;
  border: none;
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 12px;
  margin: 0 0 12px;
  padding: 0;
}
.modal .hs-form fieldset .hs-form-field {
  flex: 1 1 calc(50% - 6px) !important;
  min-width: calc(50% - 6px);
  float: none !important;
  width: auto !important;
  margin-bottom: 0;
}
/* Single field in fieldset = full width */
.modal .hs-form fieldset.form-columns-1 .hs-form-field {
  flex: 1 1 100% !important;
  min-width: 100%;
}
/* Input + wrapper fill parent */
.modal .hs-form .hs-form-field .input { margin-right: 0 !important; }
.modal .hs-form .hs-input {
  width: 100% !important;
  box-sizing: border-box !important;
}

/* Appearance — modals always light bg */
.modal {
  background: #ffffff !important;
  color: #0a0f1e !important;
  border-color: rgba(0,0,0,0.08) !important;
}
.modal-title { color: #0a0f1e !important; }
.modal-desc { color: #4a5568 !important; }
.modal .hs-form .hs-form-field > label {
  font-size: 0.72rem !important;
  font-weight: 600 !important;
  color: #4a5568 !important;
  letter-spacing: 0.04em;
  margin-bottom: 6px;
}
.modal .hs-form .hs-form-required { color: var(--brn-blue-accent) !important; }
.modal .hs-form .hs-input {
  background: #f5f7fa !important;
  border: 1px solid rgba(0,0,0,0.1) !important;
  border-radius: var(--radius-sm) !important;
  color: #0a0f1e !important;
  font-family: inherit !important;
  font-size: 0.85rem !important;
  padding: 12px 16px !important;
  transition: border-color 0.2s;
  outline: none;
}
.modal .hs-form .hs-input:focus { border-color: var(--brn-blue-accent) !important; }
.modal .hs-form textarea.hs-input { min-height: 100px; resize: vertical; }
.modal .hs-form .hs-button {
  display: block;
  width: 100% !important;
  padding: 14px;
  background: var(--brn-blue-accent) !important;
  color: #fff !important;
  font-size: 0.85rem;
  font-weight: 700;
  border: none !important;
  border-radius: var(--radius) !important;
  cursor: pointer;
  transition: all 0.3s;
  font-family: inherit;
  margin-top: 8px;
}
.modal .hs-form .hs-button:hover {
  background: #6aadff !important;
  transform: translateY(-1px);
  box-shadow: 0 0 30px rgba(91,155,255,0.2);
}
.modal .hs-form .hs-error-msgs { list-style: none; padding: 0; margin: 6px 0 0; }
.modal .hs-form .hs-error-msgs li label { color: #ff6b6b !important; font-size: 0.7rem !important; }
.modal .hs-form .hs-form-booleancheckbox-display {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.75rem;
  color: #4a5568;
  line-height: 1.5;
}
.modal .hs-form .hs-form-booleancheckbox-display input[type="checkbox"] {
  accent-color: var(--brn-blue-accent);
}
.modal .hs-form .legal-consent-container .hs-form-booleancheckbox-display span { font-size: 0.7rem; color: #6b7a8d; }
.modal-close { color: #4a5568 !important; }
