/* ==========================================================
   Start / edit campaign wizard (page-campaign-form.php + campaign-form.js)
   ========================================================== */
.rhh-cform { font-family: var(--rhh-font); color: var(--rhh-text); background: linear-gradient(180deg, #fff4f8 0, #fff 340px); padding-bottom: 72px; }
.rhh-cform h1, .rhh-cform h2, .rhh-cform h3 { font-family: var(--rhh-font); color: var(--rhh-ink); letter-spacing: -.01em; }
.rhh-cform__hero { padding: 40px 0 24px; text-align: center; }
.rhh-cform__hero h1 { margin: 0 0 8px; font-size: clamp(28px, 4.2vw, 42px); font-weight: 700; }
.rhh-cform__hero p { margin: 0 auto; max-width: 56ch; font-size: 17px; color: var(--rhh-muted); }
.rhh-btn--sm { padding: 7px 14px; font-size: 14px; }
.rhh-btn--sm .rhh-icon { width: 16px; height: 16px; }
.rhh-btn[disabled] { opacity: .6; cursor: progress; }
.rhh-linkbtn { padding: 4px 6px; border: 0; background: none; color: var(--rhh-pink-dark); font: 700 14px var(--rhh-font); text-decoration: underline; cursor: pointer; border-radius: 6px; }
.rhh-cform :focus-visible { outline: none; box-shadow: var(--rhh-focus); }

/* Logged-out gate */
.rhh-cform__gate { max-width: 560px; margin: 8px auto 0; padding: 40px 28px; text-align: center; background: #fff; border: 1px solid var(--rhh-line); border-radius: 24px; box-shadow: 0 18px 48px rgba(29,32,36,.08); }
.rhh-cform__gate-icon { display: inline-grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; background: #fde7ef; color: var(--rhh-pink-dark); }
.rhh-cform__gate-icon .rhh-icon { width: 32px; height: 32px; }
.rhh-cform__gate h2 { margin: 16px 0 8px; font-size: 24px; }
.rhh-cform__gate p { margin: 0 0 24px; color: var(--rhh-muted); }
.rhh-cform__gate-actions { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }

/* ---------- Wizard shell ---------- */
.rhh-wiz { max-width: 1080px; margin: 0 auto; }
.rhh-wiz__nav { margin: 0 auto 24px; max-width: 820px; }
.rhh-wiz__nav ol { display: flex; justify-content: space-between; gap: 4px; margin: 0; padding: 0; list-style: none; counter-reset: none; }
.rhh-wiz__nav li { flex: 1; margin: 0; padding: 0; background: none; }
.rhh-wiz__nav li::before { display: none; }
.rhh-wiz__nav button { display: flex; flex-direction: column; align-items: center; gap: 6px; width: 100%; padding: 6px 2px; border: 0; background: none; font: 600 13px/1.25 var(--rhh-font); color: var(--rhh-muted); cursor: pointer; border-radius: 12px; }
.rhh-wiz__nav button[disabled] { cursor: default; opacity: .75; }
.rhh-wiz__num { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: #fff; border: 2px solid var(--rhh-line); color: var(--rhh-muted); transition: background-color .2s, border-color .2s, color .2s; }
.rhh-wiz__num .rhh-icon { width: 20px; height: 20px; }
.rhh-wiz__nav .is-done .rhh-wiz__num { border-color: var(--rhh-pink); color: var(--rhh-pink-dark); }
.rhh-wiz__nav .is-current .rhh-wiz__num { background: var(--rhh-pink); border-color: var(--rhh-pink); color: #fff; box-shadow: 0 6px 16px rgba(233,75,134,.35); }
.rhh-wiz__nav .is-current button { color: var(--rhh-ink); }
.rhh-wiz__nav button:not([disabled]):hover .rhh-wiz__num { border-color: var(--rhh-pink); }
.rhh-wiz__meter { height: 6px; margin-top: 14px; border-radius: 99px; background: #f1e3ea; overflow: hidden; }
.rhh-wiz__meter span { display: block; height: 100%; width: 20%; border-radius: inherit; background: var(--rhh-pink); transition: width .35s ease; }
@media (max-width: 640px) {
	.rhh-wiz__label { display: none; }
	.rhh-wiz__nav .is-current .rhh-wiz__label { display: block; position: absolute; left: 0; right: 0; top: 100%; text-align: center; }
	.rhh-wiz__nav li { position: relative; }
	.rhh-wiz__nav ol { padding-bottom: 22px; }
	.rhh-wiz__num { width: 40px; height: 40px; }
}

.rhh-wiz__layout { display: grid; gap: 24px; align-items: start; }
@media (min-width: 960px) { .rhh-wiz__layout { grid-template-columns: minmax(0, 1fr) 280px; } .rhh-wiz.is-done .rhh-wiz__layout { grid-template-columns: 1fr; } }
.rhh-wiz__card { position: relative; background: #fff; border: 1px solid var(--rhh-line); border-radius: 24px; padding: 28px 20px; box-shadow: 0 18px 48px rgba(29,32,36,.07); }
@media (min-width: 640px) { .rhh-wiz__card { padding: 36px 40px; } }

.rhh-wiz__tips { position: sticky; top: calc(var(--rhh-header-h) + 20px); padding: 22px 22px 8px; border-radius: 20px; background: #fff8e0; border: 1px solid #f7e4a3; font-size: 15px; }
.rhh-wiz__tips h2 { display: flex; align-items: center; gap: 8px; margin: 0 0 10px; font-size: 17px; }
.rhh-wiz__tips h2 .rhh-icon { width: 20px; height: 20px; color: #b8860b; }
.rhh-wiz__tips ul { margin: 0; padding: 0 0 0 18px; }
.rhh-wiz__tips li { margin: 0 0 12px; line-height: 1.5; }
.rhh-wiz.is-done .rhh-wiz__tips, .rhh-wiz.is-done .rhh-wiz__nav { display: none; }
@media (max-width: 959px) { .rhh-wiz__tips { position: static; order: 2; } }

/* Loading state (while the script restructures the form) */
.rhh-wiz__skeleton { display: none; }
.rhh-wiz.is-loading #wpneofrontenddata, .rhh-wiz.is-loading .rhh-wiz__tips { visibility: hidden; height: 0; overflow: hidden; }
.rhh-wiz.is-loading .rhh-wiz__skeleton { display: grid; gap: 18px; }
.rhh-wiz__skeleton span { height: 52px; border-radius: 14px; background: linear-gradient(90deg, #f3f4f6, #fafafa, #f3f4f6); background-size: 200% 100%; animation: rhh-shimmer 1.2s infinite; }
.rhh-wiz__skeleton span:first-child { width: 45%; height: 30px; }
@keyframes rhh-shimmer { to { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { .rhh-wiz__skeleton span { animation: none; } .rhh-wiz__meter span { transition: none; } }
.rhh-wiz.is-plain #wpneofrontenddata { visibility: visible; height: auto; }

.rhh-wiz__alert { margin: 0 0 20px; padding: 14px 16px; border-radius: 14px; background: #fdecee; border: 1px solid #f5c2c7; color: #8a1c2b; font-size: 15px; }
.rhh-wiz__alert:focus { outline: none; box-shadow: var(--rhh-focus); }
.rhh-wiz__noscript { margin: 0; }

/* ---------- Steps ---------- */
.rhh-wiz__step[hidden] { display: none !important; }
.rhh-wiz__head { margin: 0 0 24px; }
.rhh-wiz__eyebrow { margin: 0 0 4px; font-size: 13px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--rhh-pink-dark); }
.rhh-wiz__head h2 { margin: 0 0 6px; font-size: clamp(24px, 3vw, 30px); font-weight: 700; }
.rhh-wiz__head h2:focus { outline: none; }
.rhh-wiz__lead { margin: 0; color: var(--rhh-muted); font-size: 16px; }
.rhh-wiz__fields { display: grid; grid-template-columns: 1fr 1fr; gap: 22px 18px; }
.rhh-wiz__fields > * { grid-column: 1 / -1; }
@media (min-width: 560px) {
	.rhh-wiz__fields > .wpneo-first-half { grid-column: 1; }
	.rhh-wiz__fields > .wpneo-second-half { grid-column: 2; }
}
.rhh-wiz__foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-top: 32px; padding-top: 24px; border-top: 1px solid var(--rhh-line); }
.rhh-wiz__foot > :last-child { margin-left: auto; }
@media (max-width: 480px) { .rhh-wiz__foot { flex-direction: column-reverse; align-items: stretch; } .rhh-wiz__foot > * { width: 100%; margin: 0 !important; } }
#wpneofrontenddata.is-busy { cursor: progress; }

/* ---------- Fields (override Backer/plugin styles) ---------- */
.rhh-cform #wpneofrontenddata { margin: 0; padding: 0; background: none; border: 0; }
.rhh-cform #wpneofrontenddata .wpneo-single { float: none; width: auto; margin: 0; padding: 0; border: 0; background: none; }
.rhh-cform #wpneofrontenddata .wpneo-name { display: flex; align-items: center; gap: 8px; float: none; width: auto; margin: 0 0 6px; padding: 0; font: 700 15px/1.3 var(--rhh-font); color: var(--rhh-ink); text-transform: none; }
.rhh-cform #wpneofrontenddata .wpneo-fields { float: none; width: auto; margin: 0; padding: 0; }
.rhh-tag { padding: 2px 8px; border-radius: 99px; background: #f3f4f6; color: var(--rhh-muted); font-size: 11px; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; }
.rhh-tag--req { background: #fde7ef; color: var(--rhh-pink-dark); }
.rhh-cform #wpneofrontenddata .wpneo-fields small, .rhh-cform .rhh-help { display: block; margin: 0 0 8px; font-size: 14px; line-height: 1.45; color: var(--rhh-muted); font-style: normal; }
.rhh-cform #wpneofrontenddata input[type="text"],
.rhh-cform #wpneofrontenddata input[type="number"],
.rhh-cform #wpneofrontenddata input[type="url"],
.rhh-cform #wpneofrontenddata select,
.rhh-cform #wpneofrontenddata textarea:not(.wp-editor-area) {
	display: block; width: 100%; max-width: none; height: auto; min-height: 50px; margin: 0; padding: 12px 14px;
	border: 1.5px solid #d6d8de; border-radius: 12px; background: #fff; box-shadow: none;
	font: 500 16px/1.4 var(--rhh-font); color: var(--rhh-ink); transition: border-color .15s, box-shadow .15s;
}
.rhh-cform #wpneofrontenddata select { appearance: none; -webkit-appearance: none; padding-right: 40px; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 14px center; }
.rhh-cform #wpneofrontenddata input:hover, .rhh-cform #wpneofrontenddata select:hover { border-color: #a9adb8; }
.rhh-cform #wpneofrontenddata input:focus, .rhh-cform #wpneofrontenddata select:focus, .rhh-cform #wpneofrontenddata textarea:focus { outline: none; border-color: var(--rhh-pink); box-shadow: 0 0 0 4px rgba(233,75,134,.18); }
.rhh-cform #wpneofrontenddata input::placeholder { color: #9aa0ab; }
.rhh-cform .has-error input, .rhh-cform .has-error select, .rhh-cform .has-error .wp-editor-container, .rhh-cform .has-error .rhh-photo__drop { border-color: #c62839 !important; }
.rhh-err { display: flex; gap: 6px; margin: 8px 0 0; color: #b3192b; font-size: 14px; font-weight: 600; }
.rhh-err::before { content: "!"; display: inline-grid; place-items: center; flex: none; width: 18px; height: 18px; border-radius: 50%; background: #b3192b; color: #fff; font-size: 12px; }
.rhh-err[hidden] { display: none; }

.rhh-money { position: relative; }
.rhh-money__cur { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); font-weight: 700; color: var(--rhh-ink); pointer-events: none; }
.rhh-money__code { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); font-size: 13px; font-weight: 700; color: var(--rhh-muted); pointer-events: none; }
.rhh-cform #wpneofrontenddata .rhh-money input { padding-left: 30px; padding-right: 56px; font-weight: 700; }
.rhh-cform #wpneofrontenddata input[type=number]::-webkit-inner-spin-button { opacity: .4; }

/* Checkboxes */
.rhh-field--check .wpneo-fields { display: flex; align-items: flex-start; gap: 10px; }
.rhh-cform #wpneofrontenddata .rhh-field--check input[type="checkbox"] { flex: none; width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--rhh-pink); }
.rhh-field--check label { font-size: 15px; color: var(--rhh-ink); cursor: pointer; }

/* "More options" */
.rhh-more { border: 1.5px solid var(--rhh-line); border-radius: 16px; background: #fcfcfd; }
.rhh-more > summary { display: flex; align-items: center; gap: 8px; padding: 16px 18px; font-weight: 700; color: var(--rhh-ink); cursor: pointer; list-style: none; border-radius: 16px; }
.rhh-more > summary::-webkit-details-marker { display: none; }
.rhh-more > summary::after { content: ""; width: 10px; height: 10px; margin-left: auto; border: solid var(--rhh-muted); border-width: 0 2px 2px 0; transform: rotate(45deg); transition: transform .2s; }
.rhh-more[open] > summary::after { transform: rotate(-135deg); }
.rhh-more > summary span { font-weight: 500; color: var(--rhh-muted); }
.rhh-more > .rhh-wiz__fields { padding: 4px 18px 20px; }
.rhh-rewards h3 { margin: 8px 0 12px; font-size: 17px; }
.rhh-rewards .reward_group { padding: 16px; margin-bottom: 12px; border: 1px dashed #d6d8de; border-radius: 14px; }
.rhh-rewards .reward_group .wpneo-single { margin-bottom: 14px !important; }
.rhh-rewards input.button, .rhh-rewards #addreward { padding: 8px 16px; border-radius: 99px; border: 1.5px solid var(--rhh-line); background: #fff; font: 700 14px var(--rhh-font); cursor: pointer; }

/* TinyMCE editor */
.rhh-cform .wp-editor-wrap { margin-top: 4px; }
.rhh-cform .wp-editor-container { border: 1.5px solid #d6d8de; border-radius: 12px; overflow: hidden; }
.rhh-cform .wp-editor-tabs { float: right; }
.rhh-cform .wp-switch-editor { border-radius: 8px 8px 0 0; font-family: var(--rhh-font); }
.rhh-cform .mce-toolbar-grp { background: #f7f7f9 !important; border-bottom: 1px solid var(--rhh-line) !important; }
.rhh-cform #wp-wpneo-form-description-wrap .mce-edit-area iframe { min-height: 320px; }
.rhh-cform .wp-media-buttons .button { border-radius: 8px; }
.rhh-cform #wpneofrontenddata .wpneo-single .wpneo-fields > small.rhh-help { margin-top: 8px; }

/* ---------- Photo uploader ---------- */
.rhh-photo__drop { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-height: 220px; padding: 28px 20px; text-align: center; border: 2px dashed #d3c2ca; border-radius: 18px; background: #fff7fa; cursor: pointer; transition: border-color .15s, background-color .15s; }
.rhh-photo__drop:hover, .rhh-photo__drop.is-over { border-color: var(--rhh-pink); background: #ffeef4; }
.rhh-photo__drop .rhh-icon { width: 40px; height: 40px; padding: 10px; box-sizing: content-box; border-radius: 50%; background: #fff; color: var(--rhh-pink-dark); box-shadow: 0 6px 16px rgba(233,75,134,.18); }
.rhh-photo__drop strong { margin-top: 6px; font-size: 17px; color: var(--rhh-ink); }
.rhh-photo__drop span { max-width: 42ch; font-size: 14px; color: var(--rhh-muted); }
.rhh-photo__drop[hidden], .rhh-photo__preview[hidden] { display: none; }
.rhh-photo__preview { position: relative; margin: 0; }
.rhh-photo__preview img { display: block; width: 100%; aspect-ratio: 16 / 10; object-fit: cover; border-radius: 18px; background: #f1f2f4; }
.rhh-photo__preview.is-uploading img { opacity: .6; }
.rhh-photo__preview figcaption { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.rhh-photo__progress { position: absolute; left: 16px; right: 16px; top: calc(50% - 4px); height: 8px; border-radius: 99px; background: rgba(255,255,255,.8); overflow: hidden; }
.rhh-photo__progress[hidden] { display: none; }
.rhh-photo__progress span { display: block; height: 100%; width: 0; background: var(--rhh-pink); transition: width .2s; }
.rhh-photo__msg { margin: 8px 0 0; font-size: 14px; color: #1f7a55; }
.rhh-photo__msg:empty { display: none; }
.rhh-photo__msg.is-error { color: #b3192b; font-weight: 600; }

.rhh-gallery__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px; margin: 0; padding: 0; list-style: none; }
.rhh-gallery__grid li { position: relative; margin: 0; padding: 0; background: none; aspect-ratio: 1; }
.rhh-gallery__grid li::before { display: none; }
.rhh-gallery__item img { width: 100%; height: 100%; object-fit: cover; border-radius: 14px; }
.rhh-gallery__item.is-uploading img { opacity: .5; }
.rhh-gallery__rm { position: absolute; top: 6px; right: 6px; display: grid; place-items: center; width: 32px; height: 32px; padding: 0; border: 0; border-radius: 50%; background: rgba(29,32,36,.75); color: #fff; cursor: pointer; }
.rhh-gallery__rm .rhh-icon { width: 16px; height: 16px; }
.rhh-gallery__spin { position: absolute; inset: 0; margin: auto; width: 28px; height: 28px; border: 3px solid #fff; border-top-color: var(--rhh-pink); border-radius: 50%; animation: rhh-spin .8s linear infinite; }
@keyframes rhh-spin { to { transform: rotate(360deg); } }
.rhh-gallery__add { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; height: 100%; border: 2px dashed #d3c2ca; border-radius: 14px; background: #fff7fa; color: var(--rhh-pink-dark); font-size: 14px; font-weight: 700; cursor: pointer; }
.rhh-gallery__add:hover, .rhh-gallery__add.is-over { border-color: var(--rhh-pink); }

.rhh-yt { display: flex; align-items: center; gap: 12px; margin-top: 10px; padding: 8px; border-radius: 14px; background: #eef8f3; }
.rhh-yt[hidden] { display: none; }
.rhh-yt img { width: 120px; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 10px; }
.rhh-yt span { display: flex; align-items: center; gap: 6px; font-weight: 700; color: #1f7a55; font-size: 14px; }
.rhh-yt .rhh-icon { width: 18px; height: 18px; }

/* ---------- Review ---------- */
.rhh-review dl { margin: 0; border: 1px solid var(--rhh-line); border-radius: 16px; overflow: hidden; }
.rhh-review__row { display: grid; grid-template-columns: 130px 1fr auto; gap: 12px; align-items: center; padding: 14px 16px; border-top: 1px solid var(--rhh-line); }
.rhh-review__row:first-child { border-top: 0; }
.rhh-review dt { font-weight: 700; color: var(--rhh-muted); font-size: 14px; }
.rhh-review dd { margin: 0; color: var(--rhh-ink); font-weight: 600; overflow-wrap: anywhere; }
.rhh-review dd img { width: 120px; aspect-ratio: 16 / 10; object-fit: cover; border-radius: 10px; }
.rhh-review dd em { color: #b3192b; font-style: normal; }
@media (max-width: 520px) { .rhh-review__row { grid-template-columns: 1fr auto; } .rhh-review dt { grid-column: 1 / -1; } }
.rhh-terms { padding: 18px; border-radius: 16px; background: #f7f7f9; }
.rhh-terms .wpneo-title { margin: 0 0 6px; font-weight: 700; color: var(--rhh-ink); }
.rhh-terms .wpneo-text { margin: 0 0 12px; font-size: 14px; max-height: 180px; overflow: auto; }
.rhh-terms .wpneo-requirement-title { display: flex; gap: 10px; align-items: flex-start; font-weight: 600; }
.rhh-terms input[type=checkbox] { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--rhh-pink); flex: none; }

/* ---------- Success ---------- */
.rhh-wiz__success { max-width: 520px; margin: 0 auto; padding: 24px 0; text-align: center; }
.rhh-wiz__success:focus { outline: none; }
.rhh-wiz__success-icon { display: inline-grid; place-items: center; width: 72px; height: 72px; border-radius: 50%; background: #e7f6ef; color: #1f9d6b; }
.rhh-wiz__success-icon .rhh-icon { width: 36px; height: 36px; stroke-width: 3; }
.rhh-wiz__success h2 { margin: 16px 0 8px; font-size: 28px; }
.rhh-wiz__success p { margin: 0 0 24px; color: var(--rhh-muted); font-size: 17px; }

/* The plugin's own pop-up is replaced by inline messages on this page. */
.wpneo-modal-wrapper { display: none !important; }

/* jQuery UI datepicker (plugin) */
.ui-datepicker { z-index: 200 !important; padding: 10px; border: 1px solid var(--rhh-line) !important; border-radius: 14px; background: #fff; box-shadow: 0 18px 48px rgba(29,32,36,.14); font-family: var(--rhh-font); }
.ui-datepicker .ui-state-active, .ui-datepicker .ui-state-highlight { background: var(--rhh-pink) !important; color: #fff !important; border-radius: 8px; }
