/* Official popup shells, headers, masks, fields and buttons use the captured site CSS. */
#contact-popup[hidden],#help-popup[hidden]{display:none!important}
#contact-popup,#help-popup{z-index:9999}
#contact-popup .popup_title,#help-popup .popup_title{position:relative}
.hg-popup-close{position:absolute;top:50%;right:10px;width:32px;height:32px;margin:0;padding:0;transform:translateY(-50%);border:0;background:transparent;color:inherit;font:28px/1 Arial,sans-serif;cursor:pointer}
.hg-popup-close:hover{opacity:.7}
.hg-popup-close:focus-visible{outline:2px solid #19805c;outline-offset:2px}
/* Only the additional contact hint is styled here; official login errors remain untouched. */
.hg-contact-hint{display:block;max-width:100%;margin:8px auto 16px;padding:8px 12px;border:1px solid #19805c;border-radius:4px;background:#eef8f4;color:#19805c;font:600 12px/1.5 Arial,sans-serif;cursor:pointer;white-space:normal;text-decoration:underline;text-underline-offset:3px}
.hg-contact-hint[hidden]{display:none}
.hg-contact-hint:hover{background:#dcefe6}
.hg-contact-hint:focus-visible{outline:2px solid currentColor;outline-offset:2px}
/* Keep the contact actions visible while longer forms and partnership content scroll. */
#contact-popup{--contact-inset-top:max(16px,env(safe-area-inset-top,0px));--contact-inset-bottom:max(16px,env(safe-area-inset-bottom,0px));--contact-inset-left:max(16px,env(safe-area-inset-left,0px));--contact-inset-right:max(16px,env(safe-area-inset-right,0px))}
#contact-popup,#contact-popup *{box-sizing:border-box}
#contact-popup.md_alertBg,#contact-popup .popup_center{height:100vh;height:100dvh;padding:var(--contact-inset-top) var(--contact-inset-right) var(--contact-inset-bottom) var(--contact-inset-left)}
#contact-panel,#contact-dialog.md_alert{display:flex;flex-direction:column;min-width:0;min-height:0;width:100%;max-width:480px;max-height:min(720px,calc(100vh - var(--contact-inset-top) - var(--contact-inset-bottom)));max-height:min(720px,calc(100dvh - var(--contact-inset-top) - var(--contact-inset-bottom)));overflow:hidden}
#contact-popup .popup_title,#contact-popup .md_alert_title{flex:0 0 auto}
#contact-popup .popup_content,#contact-popup .md_alert_info{flex:1 1 auto;min-width:0;min-height:0;margin:0;padding:20px 16px;overflow-x:hidden;overflow-y:auto;overscroll-behavior:contain;scroll-padding-block:16px}
#contact-popup .contact-footer{flex:0 0 auto;min-width:0;border-top:1px solid #e5ebe7;background:#fff}
#contact-popup .contact-actions{display:flex;flex:0 0 auto;gap:12px;width:100%;margin:0;padding:16px;background:#fff}
#contact-popup .contact-actions>button{flex:1 1 0;min-width:0;width:auto;height:auto;min-height:48px;margin:0;padding:10px 8px;font-family:inherit;line-height:1.4;white-space:normal;overflow-wrap:anywhere;cursor:pointer}
#contact-popup .contact-actions>.btn_cancel,#contact-popup .contact-actions>.btn_submit{border:0}
#contact-popup .contact-actions>button:focus-visible{outline:2px solid #19805c;outline-offset:2px}
#contact-popup .contact-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px 12px}
#contact-popup .contact-fields>label{min-width:0;width:100%;margin:0}
#contact-popup .contact-message{width:100%;margin:0}
@media(max-width:400px){#contact-popup .contact-fields{grid-template-columns:minmax(0,1fr)}}
@media(max-height:480px){#contact-popup .popup_content,#contact-popup .md_alert_info{padding:12px 16px}#contact-popup .contact-actions{padding:10px 16px}}
/* Contact form additions inside the official popup_content/md_alert_info. */
#contact-popup fieldset{min-width:0;margin:0 0 16px;padding:0;border:0}
#contact-popup legend{margin:0 0 16px;padding:0;font-size:12px;line-height:16px}
#contact-popup .contact-intro{margin:0 0 16px;line-height:20px}
#contact-popup .contact-message{height:96px}
#contact-popup .contact-message textarea{display:block;width:100%;height:100%;margin:0;padding:12px 16px;border:1px solid rgba(0,0,0,.32);border-radius:4px;resize:none;background:#fff;color:#000;font:16px/22px Arial,sans-serif}
#contact-popup .lab_input.on textarea{border:2px solid #19805c}
#contact-popup .md_label textarea{min-width:0;flex:1;padding:0;border:0;border-radius:0;outline:none;background:transparent}
#contact-popup .md_label.--has-value code{top:auto;bottom:calc(100% - 8px);left:8px;height:16px;padding:0 8px;background:#fff;font-size:14px;line-height:16px}
#contact-popup .md_label.--disabled{pointer-events:none}
#contact-popup #contact-submit:disabled{opacity:.65;cursor:default}
.contact-trap{position:absolute;left:-10000px;top:auto;width:1px;height:1px;overflow:hidden}
#contact-status{margin:0;padding:12px 16px 0;color:#ce3636;font-size:13px;line-height:1.6;overflow-wrap:anywhere}
#contact-status:empty{display:none}
#contact-status.success{color:#19805c}
#dialog-message{margin:0;line-height:1.8}
