/* HD Newsletters — front-end forms and subscription pages */
.hdn-form-wrap { box-sizing: border-box; margin: 1em 0; }
.hdn-form-wrap *, .hdn-form-wrap *::before, .hdn-form-wrap *::after { box-sizing: inherit; }
.hdn-form .hdn-fields { display: flex; flex-direction: column; gap: 12px; }
.hdn-layout-inline .hdn-form .hdn-fields { flex-direction: row; flex-wrap: wrap; align-items: flex-end; }
.hdn-layout-inline .hdn-field { flex: 1 1 160px; margin: 0; }
.hdn-layout-inline .hdn-field-submit { flex: 0 0 auto; }
.hdn-field { margin: 0; }
.hdn-field label { display: block; font-weight: 600; margin-bottom: 4px; font-size: .95em; }
.hdn-field .hdn-check { font-weight: normal; display: flex; gap: 8px; align-items: flex-start; margin-bottom: 4px; }
.hdn-field .hdn-check input { margin-top: .3em; flex: 0 0 auto; }
.hdn-form input[type=text], .hdn-form input[type=email], .hdn-form input[type=number], .hdn-form input[type=date], .hdn-form select, .hdn-form textarea { width: 100%; padding: 10px 12px; border: 1px solid #d1d5db; border-radius: 6px; font: inherit; background: #fff; color: inherit; }
.hdn-form input:focus, .hdn-form select:focus, .hdn-form textarea:focus { outline: 2px solid rgba(29,78,216,.35); outline-offset: 1px; }
.hdn-form fieldset { border: 0; padding: 0; margin: 0; }
.hdn-form legend { font-weight: 600; margin-bottom: 4px; }
.hdn-button { display: inline-block; padding: 11px 22px; border: 0; border-radius: 6px; font: inherit; font-weight: 600; cursor: pointer; background: #1d4ed8; color: #fff; line-height: 1.2; }
.hdn-button:hover { filter: brightness(1.08); }
.hdn-button[disabled] { opacity: .6; cursor: wait; }
.hdn-hp { position: absolute !important; left: -9999px !important; height: 0; overflow: hidden; }
.hdn-req { color: #b91c1c; }
.hdn-form-message { padding: 10px 14px; border-radius: 6px; margin-bottom: 12px; font-size: .95em; }
.hdn-form-message.is-success { background: #dcfce7; color: #166534; }
.hdn-form-message.is-error { background: #fee2e2; color: #991b1b; }
.hdn-notice { padding: 14px 18px; border-radius: 8px; margin: 1em 0; line-height: 1.5; }
.hdn-notice-success { background: #dcfce7; color: #166534; }
.hdn-notice-info { background: #dbeafe; color: #1e3a8a; }
.hdn-notice-error { background: #fee2e2; color: #991b1b; }
.hdn-manage-form .hdn-row { display: flex; gap: 12px; }
.hdn-manage-form .hdn-row .hdn-field { flex: 1; }
.hdn-manage-form .hdn-field { margin-bottom: 14px; }
.hdn-manage-form small { display: block; color: #6b7280; font-weight: normal; }
.hdn-field-text p:last-child { margin-bottom: 0; }

/* --- Popup / slide-in / bar signup forms ------------------------------- */
.hdn-overlay { position: fixed; z-index: 99999; inset: auto; }
.hdn-overlay[hidden] { display: none !important; }
body.hdn-overlay-open { overflow: hidden; }
.hdn-overlay-backdrop { position: fixed; inset: 0; background: rgba(15, 23, 42, .55); opacity: 0; transition: opacity .28s ease; }
.hdn-overlay.is-open .hdn-overlay-backdrop { opacity: 1; }
.hdn-overlay-panel { position: relative; background: #fff; color: #111827; box-shadow: 0 18px 48px rgba(15, 23, 42, .28); border-radius: 12px; padding: 28px 28px 24px; max-width: min(560px, calc(100vw - 32px)); }
.hdn-overlay-panel .hdn-form-wrap { margin: 0; }
.hdn-overlay-panel .hdn-form-wrap.hdn-in-overlay { max-width: none; }
.hdn-overlay-heading { margin: 0 0 6px; font-size: 1.35em; line-height: 1.25; }
.hdn-overlay-sub { margin: 0 0 16px; opacity: .78; line-height: 1.45; }
.hdn-overlay-close { position: absolute; top: 8px; right: 10px; width: 34px; height: 34px; border: 0; background: transparent; color: inherit; font-size: 26px; line-height: 1; cursor: pointer; border-radius: 8px; opacity: .55; }
.hdn-overlay-close:hover { opacity: 1; background: rgba(15, 23, 42, .07); }
.hdn-overlay-close:focus-visible { outline: 2px solid #1d4ed8; outline-offset: 2px; opacity: 1; }

/* Position */
.hdn-overlay.hdn-pos-center { inset: 0; display: flex; align-items: center; justify-content: center; padding: 16px; }
.hdn-overlay.hdn-pos-bottom_right { right: 20px; bottom: 20px; }
.hdn-overlay.hdn-pos-bottom_left { left: 20px; bottom: 20px; }
.hdn-overlay.hdn-pos-top { top: 0; left: 0; right: 0; }
.hdn-overlay.hdn-pos-bottom { bottom: 0; left: 0; right: 0; }
.hdn-overlay.hdn-pos-bottom_right .hdn-overlay-panel,
.hdn-overlay.hdn-pos-bottom_left .hdn-overlay-panel { max-width: min(400px, calc(100vw - 40px)); }

/* Notification bar */
.hdn-overlay-bar { left: 0; right: 0; }
.hdn-overlay-bar.hdn-pos-center { inset: auto 0 0 0; display: block; padding: 0; }
.hdn-overlay-bar .hdn-overlay-panel { max-width: none; border-radius: 0; padding: 12px 52px 12px 20px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 20px; box-shadow: 0 -2px 14px rgba(15, 23, 42, .16); }
.hdn-overlay-bar .hdn-overlay-heading { font-size: 1.05em; margin: 0; }
.hdn-overlay-bar .hdn-overlay-sub { margin: 0; font-size: .92em; }
.hdn-overlay-bar .hdn-form-wrap { flex: 1 1 320px; }
.hdn-overlay-bar .hdn-form .hdn-fields { flex-direction: row; flex-wrap: wrap; align-items: flex-end; }
.hdn-overlay-bar .hdn-field { flex: 1 1 160px; }
.hdn-overlay-bar .hdn-field-submit { flex: 0 0 auto; }

/* Animation — all of them settle on the same open state, so a reduced-motion
   visitor still gets a fully positioned panel. */
.hdn-overlay-panel { opacity: 0; transition: opacity .28s ease, transform .28s ease; }
.hdn-overlay.is-open .hdn-overlay-panel { opacity: 1; transform: none; }
.hdn-anim-zoom .hdn-overlay-panel { transform: scale(.94); }
.hdn-anim-slide .hdn-overlay-panel { transform: translateY(24px); }
.hdn-overlay-slide_in.hdn-anim-slide.hdn-pos-bottom_right .hdn-overlay-panel,
.hdn-overlay-slide_in.hdn-anim-slide.hdn-pos-bottom_left .hdn-overlay-panel { transform: translateY(120%); }
.hdn-overlay-bar.hdn-anim-slide .hdn-overlay-panel { transform: translateY(100%); }
.hdn-anim-none .hdn-overlay-panel { transition: none; opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
	.hdn-overlay-panel, .hdn-overlay-backdrop { transition: none; }
	.hdn-overlay-panel { transform: none; }
}

@media (max-width: 600px) {
	.hdn-overlay.hdn-pos-bottom_right, .hdn-overlay.hdn-pos-bottom_left { left: 12px; right: 12px; bottom: 12px; }
	.hdn-overlay-panel { padding: 22px 20px 18px; }
}
