/* Capture App — dark-theme dashboard + signup styles.
   Scoped under .capture-app so nothing leaks onto the rest of the theme. */

/* Full-bleed: neutralise the theme's narrow-content containers on our
   pages. Broad selectors because block themes nest layout wrappers deeply. */
.capture-app-page .wp-site-blocks,
.capture-app-page .wp-site-blocks > main,
.capture-app-page main,
.capture-app-page main > *,
.capture-app-page .wp-block-post-content,
.capture-app-page .wp-block-post-content > *,
.capture-app-page .entry-content,
.capture-app-page .entry-content > *,
.capture-app-page .is-layout-constrained,
.capture-app-page .is-layout-constrained > *,
.capture-app-page .is-layout-flow,
.capture-app-page .is-layout-flow > *,
.capture-app-page .wp-block-group {
	max-width: none !important;
	width: auto !important;
	margin-left: 0 !important;
	margin-right: 0 !important;
	padding-left: 0 !important;
	padding-right: 0 !important;
}

.capture-app-page {
	--wp--style--global--content-size: 100%;
	--wp--style--global--wide-size: 100%;
}

/* The page-with-title template renders an empty hero group where the title
   used to live; the extendable theme gives it a tertiary background colour
   which shows as a light strip. Hide it on our pages. */
.capture-app-page .wp-block-group.has-tertiary-background-color {
	display: none !important;
}

/* Custom properties scoped to the whole page (not just .capture-app),
   because the shared support modal is rendered to wp_footer and lives
   OUTSIDE .capture-app in the DOM. Without this, every var(--*) used by
   the modal silently resolves to invalid → fields had no visible
   background or border.

   Palette aligned with the marketing site (capture.ee). The body
   gradient lives on body.capture-app-page in the theme; tokens here
   reference the bottom-of-gradient navy + new accent family so the
   plugin surfaces blend with the gradient instead of fighting it. */
body.capture-app-page,
.capture-app {
	/* Marketing-site gradient stops (top→bottom) */
	--grad-1:    #1e3160;
	--grad-2:    #16264d;
	--grad-3:    #0f1c3a;
	--grad-4:    #0a1428;
	--grad-5:    #050a1a;

	/* Brand accents */
	--accent:        #3b82f6;
	--accent-soft:   #93c5fd;
	/* CTA: green-700 / -800 are WCAG AA-compliant with white text
	   (4.5:1 / 5.7:1). Green-500 (#22c55e) only reaches 2.3:1 and was
	   reserved for backgrounds with dark text — using it as a button
	   colour with white text would have failed contrast. */
	--cta:           #15803d;
	--cta-hover:     #166534;
	--ink:           #0a0a14;

	/* Text + hairlines on dark */
	--white-soft:    rgba(255, 255, 255, 0.85);
	--white-mute:    rgba(255, 255, 255, 0.65);
	--white-line:    rgba(255, 255, 255, 0.18);

	/* Glass surface (semi-transparent white over the gradient) */
	--glass-bg:      rgba(255, 255, 255, 0.08);
	--glass-border:  rgba(255, 255, 255, 0.18);

	/* Legacy semantic tokens — kept for the rest of the stylesheet,
	   re-pointed at the new palette so the visual shift cascades
	   without a thousand find-and-replaces. */
	--bg:        #050a1a;
	--surface:   rgba(255, 255, 255, 0.08);
	--surface-2: rgba(255, 255, 255, 0.12);
	--border:    rgba(255, 255, 255, 0.18);
	--border-2:  rgba(255, 255, 255, 0.28);
	--text:      #f1f5f9;
	--text-2:    rgba(255, 255, 255, 0.85);
	--text-3:    rgba(255, 255, 255, 0.65);
	--text-4:    rgba(255, 255, 255, 0.45);
	--primary:   #3b82f6;
	--primary-2: #93c5fd;
	--ok:        #22c55e;
	--warn:      #f59e0b;
	--danger:    #ef4444;
	--radius:    16px;
	--radius-sm: 12px;
}

.capture-app {
	/* Transparent so the body gradient (set in the theme) shows through
	   the wrapper and the atmospheric scroll effect works. */
	background: transparent;
	color: var(--text);
	font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	line-height: 1.5;
	padding: 40px 24px 60px;
}

.capture-app *,
.capture-app *::before,
.capture-app *::after {
	box-sizing: border-box;
}

.capture-app a { color: var(--primary-2); text-decoration: none; }
.capture-app a:hover { color: var(--primary); }

.capture-main { max-width: 1024px; margin: 0 auto; }

.capture-welcome h1 { font-size: 28px; font-weight: 700; color: #fff; margin: 0 0 6px; }
.capture-welcome p  { color: var(--text-3); margin: 0 0 32px; font-size: 14px; }

.capture-grid {
	display: grid;
	grid-template-columns: 2fr 1fr;
	gap: 24px;
}
.capture-col-main, .capture-col-side { display: flex; flex-direction: column; gap: 24px; }

@media (max-width: 900px) {
	.capture-grid { grid-template-columns: 1fr; }
	/* Flatten the two columns so all cards become direct grid children,
	   then `order` reshuffles them so the Account Status card sits right
	   after the top banners — most important info at a glance on mobile.
	   Cards without an explicit order default to 0, so the top banners
	   (welcome / identity / business CTAs inside col-main) stay first. */
	.capture-col-main,
	.capture-col-side {
		display: contents;
	}
	.capture-card--status     { order: 2; }
	.capture-card--billing    { order: 3; }
	.capture-card--formation  { order: 4; }
	.capture-card--profile    { order: 5; }
	.capture-card--business   { order: 6; }
	.capture-card--actions    { order: 7; }
	.capture-footer-badges    { order: 8; }
}

/* Cards ------------------------------------------------------------- */
.capture-card {
	background: var(--glass-bg);
	backdrop-filter: blur(10px);
	-webkit-backdrop-filter: blur(10px);
	border: 1px solid var(--glass-border);
	border-radius: var(--radius);
	overflow: hidden;
}
.capture-card__header {
	display: flex; align-items: center; justify-content: space-between;
	padding: 16px 24px;
	border-bottom: 1px solid var(--border);
}
.capture-card__header h2 { margin: 0; font-size: 15px; font-weight: 600; color: #fff; }
.capture-card__body { padding: 24px; }
.capture-card--list { padding: 0; }
.capture-card--list > * + * { border-top: 1px solid var(--border); }
.capture-card--form { padding: 32px; }

.capture-link {
	background: none; border: 0; cursor: pointer;
	color: var(--primary-2); font-size: 13px; font-weight: 500;
	display: inline-flex; align-items: center; gap: 6px;
}
.capture-link:hover { color: var(--primary); }

/* Profile ----------------------------------------------------------- */
.capture-profile { display: flex; align-items: center; gap: 20px; margin-bottom: 24px; }
.capture-avatar {
	width: 64px; height: 64px; border-radius: 50%;
	background: var(--surface-2); border: 2px solid var(--border-2);
	display: flex; align-items: center; justify-content: center;
	font-size: 20px; font-weight: 700; color: var(--primary-2);
}
.capture-profile__name { font-size: 17px; font-weight: 600; color: #fff; }
.capture-profile__email { font-size: 13px; color: var(--text-3); }

/* Info grid --------------------------------------------------------- */
.capture-info-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 16px;
}
.capture-info--wide { grid-column: span 2; }
.capture-info__label {
	font-size: 11px; text-transform: uppercase; letter-spacing: .05em;
	color: var(--text-4); margin-bottom: 4px;
}
.capture-info__value { font-size: 14px; color: var(--text-2); }

.capture-section + .capture-section {
	margin-top: 20px; padding-top: 20px; border-top: 1px solid var(--border);
}
.capture-section__label {
	font-size: 11px; text-transform: uppercase; letter-spacing: .05em;
	color: rgba(56, 189, 248, .7); font-weight: 600; margin-bottom: 12px;
}

/* Empty state ------------------------------------------------------- */
.capture-empty { text-align: center; padding: 16px 0; }
.capture-empty__icon {
	width: 48px; height: 48px; border-radius: 50%;
	background: var(--surface-2);
	display: flex; align-items: center; justify-content: center;
	margin: 0 auto 12px; color: var(--text-4);
}
.capture-empty__icon svg { width: 24px; height: 24px; }
.capture-empty p { color: var(--text-4); margin: 0 0 4px; font-size: 14px; }
.capture-empty small { color: var(--text-4); font-size: 12px; }

/* Formation card lives in the sidebar — it follows the same shape as
   the Billing card (header + body + block button), no extra layout
   needed beyond setting the body's leading paragraph spacing so the
   button doesn't crowd it. */
.capture-card--formation .capture-card__body p {
	margin: 0 0 16px;
	font-size: 14px;
	color: var(--text-3);
	line-height: 1.55;
}

/* Welcome banner (one-shot, post-payment) ------------------------- */
.capture-welcome-banner {
	display: flex;
	gap: 16px;
	padding: 24px;
	background: linear-gradient(135deg, rgba(16, 185, 129, .12), rgba(14, 165, 233, .08));
	border: 1px solid rgba(16, 185, 129, .3);
	border-radius: var(--radius);
}
.capture-welcome-banner__icon {
	font-size: 32px;
	line-height: 1;
	flex-shrink: 0;
}
.capture-welcome-banner__body { flex: 1; }
.capture-welcome-banner h3 {
	margin: 0 0 8px;
	color: #34d399;
	font-size: 18px;
	font-weight: 600;
}
.capture-welcome-banner p {
	margin: 0 0 12px;
	color: var(--text-2);
	font-size: 14px;
}
.capture-welcome-banner ol {
	margin: 0 0 12px;
	padding-left: 24px;
	color: var(--text-2);
	font-size: 14px;
}
.capture-welcome-banner li { margin-bottom: 8px; }
.capture-welcome-banner li strong { color: #fff; font-weight: 600; }
.capture-welcome-banner__foot {
	margin: 0 !important;
	color: var(--text-3) !important;
	font-size: 13px !important;
}

/* CTA --------------------------------------------------------------- */
.capture-cta {
	display: flex; gap: 16px;
	padding: 20px;
	border-radius: var(--radius);
	border: 1px solid;
}
.capture-cta--identity { background: rgba(14, 165, 233, .08); border-color: rgba(14, 165, 233, .3); }
.capture-cta--business { background: rgba(245, 158, 11, .08); border-color: rgba(245, 158, 11, .3); }
.capture-cta--review   { background: rgba(100, 116, 139, .12); border-color: rgba(148, 163, 184, .3); }
.capture-cta__icon {
	width: 40px; height: 40px; border-radius: 12px;
	display: flex; align-items: center; justify-content: center;
	flex-shrink: 0; margin-top: 2px;
}
.capture-cta--identity .capture-cta__icon { background: rgba(14, 165, 233, .2); color: #7dd3fc; }
.capture-cta--business .capture-cta__icon { background: rgba(245, 158, 11, .2); color: #fbbf24; }
.capture-cta--review   .capture-cta__icon { background: rgba(148, 163, 184, .2); color: #cbd5e1; }
.capture-cta__icon svg { width: 20px; height: 20px; }
.capture-cta__body h3 { margin: 0 0 4px; font-size: 15px; font-weight: 600; }
.capture-cta--identity .capture-cta__body h3 { color: #7dd3fc; }
.capture-cta--business .capture-cta__body h3 { color: #fcd34d; }
.capture-cta--review   .capture-cta__body h3 { color: #e2e8f0; }
.capture-cta__body p { margin: 0 0 12px; font-size: 13px; }
.capture-cta--identity .capture-cta__body p { color: rgba(125, 211, 252, .7); }
.capture-cta--business .capture-cta__body p { color: rgba(252, 211, 77, .7); }
.capture-cta--review   .capture-cta__body p { color: rgba(203, 213, 225, .8); }

/* Buttons ----------------------------------------------------------- */
.capture-btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px;
	padding: 12px 24px;
	border-radius: var(--radius-sm);
	border: 1px solid transparent;
	font-size: 14px; font-weight: 600; font-family: inherit;
	cursor: pointer;
	transition: background .15s, color .15s, border-color .15s, box-shadow .15s;
	text-decoration: none;
	line-height: 1;
}
/* Background is blue-700 (#1d4ed8) rather than --accent (blue-500
   #3b82f6) so white text clears WCAG AA 4.5:1 — blue-500 only reaches
   3.67:1. The blue-500 brand colour is preserved everywhere else
   (icons, focus rings, links, gradients). Hover deepens further to
   blue-800 to keep contrast on press. */
.capture-btn--primary {
	background: #1d4ed8;
	color: #fff !important;
	box-shadow: 0 10px 15px -3px rgba(59, 130, 246, .25),
				0 4px 6px -4px rgba(59, 130, 246, .25);
}
.capture-btn--primary:hover {
	background: #1e40af;
	color: #fff !important;
	box-shadow: 0 10px 15px -3px rgba(59, 130, 246, .35),
				0 4px 6px -4px rgba(59, 130, 246, .35);
}
.capture-btn--warning { background: var(--warn); color: #fff; }
.capture-btn--warning:hover { background: #fbbf24; color: #fff; }
.capture-btn--ghost { background: var(--surface-2); color: #fff; }
.capture-btn--ghost:hover { background: var(--border-2); }
.capture-btn--block { width: 100%; }
.capture-btn:disabled { opacity: .5; cursor: not-allowed; }

/* Status ------------------------------------------------------------ */
.capture-status { padding: 20px; }
.capture-status__row {
	display: flex; align-items: center; justify-content: space-between;
	padding: 6px 0;
}
.capture-status__label { display: inline-flex; align-items: center; gap: 10px; font-size: 14px; color: var(--text-2); }
.capture-dot {
	width: 10px; height: 10px; border-radius: 50%; display: inline-block;
}
.capture-dot--ok   { background: var(--ok); }
.capture-dot--warn { background: var(--warn); }
.capture-dot--idle { background: var(--text-4); }

.capture-badge {
	font-size: 11px; font-weight: 500; padding: 2px 10px; border-radius: 999px;
}
.capture-badge--ok   { background: rgba(16, 185, 129, .15); color: #34d399; }
.capture-badge--warn { background: rgba(245, 158, 11, .15); color: #fbbf24; }
.capture-badge--idle { background: rgba(100, 116, 139, .15); color: var(--text-3); }

/* Billing plan info ------------------------------------------------ */
.capture-billing { margin-bottom: 16px; }
.capture-billing__plan {
	font-size: 11px; text-transform: uppercase; letter-spacing: .05em;
	color: var(--text-4); margin-bottom: 4px;
}
.capture-billing__price {
	font-size: 24px; font-weight: 700; color: #fff; line-height: 1.1;
}
.capture-billing__price span { font-size: 14px; font-weight: 400; color: var(--text-3); }
.capture-billing__renewal {
	margin-top: 8px; font-size: 12px; color: var(--text-3);
}
.capture-billing__next { color: var(--text-4); }
.capture-billing__status {
	display: inline-block;
	margin-top: 4px;
	padding: 4px 10px;
	border-radius: 999px;
	font-size: 12px;
	font-weight: 600;
}
.capture-billing__status--canceled { background: rgba(239, 68, 68, .15); color: #fca5a5; }
.capture-billing__status--past-due { background: rgba(245, 158, 11, .15); color: #fbbf24; }

/* List items ------------------------------------------------------- */
.capture-list-item {
	display: flex; align-items: center; justify-content: space-between;
	padding: 14px 20px; width: 100%;
	background: none; border: 0; color: var(--text-2); font: inherit;
	text-align: left; cursor: pointer; text-decoration: none;
}
/* Beat `.capture-app a { color: var(--primary-2) }` and its :hover
   variant for anchor versions of this list item. Covers every anchor
   pseudo-state explicitly (LVHFA) so no global link rule can flip the
   colour mid-interaction. !important is the sledgehammer — using it
   here so this doesn't regress into the blue-link bug a third time
   after some future cascade change. */
.capture-app a.capture-list-item,
.capture-app a.capture-list-item:link,
.capture-app a.capture-list-item:visited,
.capture-app a.capture-list-item:hover,
.capture-app a.capture-list-item:focus,
.capture-app a.capture-list-item:active {
	color: var(--text-2) !important;
}
.capture-list-item:hover { background: rgba(30, 41, 59, .5); }

.capture-footer-badges {
	text-align: center; padding: 16px;
	background: rgba(15, 23, 42, .5);
	border: 1px solid rgba(30, 41, 59, .5);
	border-radius: var(--radius);
	font-size: 12px; color: var(--text-4);
}
.capture-footer-badges span + span { margin-left: 12px; }
.capture-footer-badges div { margin-top: 4px; }

/* Modals ----------------------------------------------------------- */
.capture-modal {
	position: fixed; inset: 0; z-index: 10000;
	display: flex; align-items: flex-start; justify-content: center;
	padding: 40px 16px; overflow-y: auto;
}
.capture-modal[hidden] { display: none; }
.capture-modal__backdrop {
	position: fixed; inset: 0;
	background: rgba(2, 6, 23, .85);
	backdrop-filter: blur(12px) saturate(120%);
	-webkit-backdrop-filter: blur(12px) saturate(120%);
}
.capture-modal__panel {
	position: relative;
	/* Modal needs to stay readable — use a navy-tinted opaque surface
	   rather than the translucent white card recipe. Sits comfortably
	   on top of the body gradient + backdrop blur. */
	background: rgba(15, 28, 58, 0.96);
	backdrop-filter: blur(16px);
	-webkit-backdrop-filter: blur(16px);
	border: 1px solid var(--glass-border);
	border-radius: 20px;
	width: 100%; max-width: 520px;
	box-shadow: 0 25px 50px -12px rgba(0, 0, 0, .5);
	overflow: hidden;
}
.capture-modal--wide .capture-modal__panel { max-width: 720px; }
.capture-modal__panel > header {
	display: flex; align-items: center; justify-content: space-between;
	padding: 16px 24px; border-bottom: 1px solid var(--glass-border);
	position: sticky; top: 0; background: rgba(15, 28, 58, 0.96); z-index: 1;
}
.capture-modal__panel > header h3 { margin: 0; font-size: 17px; font-weight: 600; color: #fff; }
.capture-modal__close {
	background: none; border: 0; cursor: pointer;
	color: var(--text-3); font-size: 24px; line-height: 1;
}
.capture-modal__close:hover { color: #fff; }

/* Forms ------------------------------------------------------------ */
.capture-form { padding: 24px; display: flex; flex-direction: column; gap: 16px; }
.capture-form label { display: block; }
.capture-form label > span {
	display: flex; align-items: center; gap: 4px;
	font-size: 13px; color: var(--text-3); margin-bottom: 6px;
}
.capture-required { color: #f87171; font-style: normal; }
.capture-tip {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 18px;
	height: 18px;
	margin-left: 4px;
	border-radius: 50%;
	background: var(--surface-2);
	color: var(--text-3);
	font-size: 11px;
	font-weight: 700;
	line-height: 1;
	cursor: help;
	border: 1px solid var(--border-2);
	transition: background .15s, color .15s, border-color .15s;
	flex-shrink: 0;
}
.capture-tip:hover {
	background: var(--border-2);
	color: var(--text);
	border-color: var(--text-4);
}

.capture-form input[type="text"],
.capture-form input[type="email"],
.capture-form input[type="password"],
.capture-form input[type="number"],
.capture-form input[type="tel"],
.capture-form select,
.capture-form textarea {
	width: 100%; padding: 10px 12px;
	background: var(--bg);
	border: 1px solid var(--border-2);
	border-radius: var(--radius-sm);
	color: #fff; font-size: 14px; font-family: inherit;
}
.capture-form textarea { resize: vertical; min-height: 76px; }
.capture-form input:focus,
.capture-form select:focus,
.capture-form textarea:focus {
	outline: none; border-color: var(--primary);
}
.capture-form input:disabled { opacity: .5; cursor: not-allowed; }
.capture-form small { display: block; color: var(--text-4); font-size: 12px; margin-top: 4px; }

.capture-form__actions {
	display: flex; gap: 12px; padding-top: 12px;
	border-top: 1px solid var(--border);
}
.capture-form__actions .capture-btn { flex: 1; }

.capture-form__notice {
	background: rgba(15, 23, 42, .5);
	border: 1px solid rgba(30, 41, 59, .5);
	border-radius: var(--radius-sm);
	padding: 16px;
	font-size: 13px; color: var(--text-3);
}
.capture-form__notice p { margin: 0 0 8px; }
.capture-form__notice p:last-child { margin: 0; color: var(--text-4); font-size: 12px; }

.capture-form__section {
	margin: 8px 0 0; padding-top: 16px;
	border-top: 1px solid var(--border);
	font-size: 12px; font-weight: 600;
	color: var(--primary-2);
	text-transform: uppercase; letter-spacing: .05em;
}
.capture-form--business .capture-form__section:first-of-type { border-top: 0; padding-top: 0; }

.capture-radio-group { display: flex; gap: 24px; }
.capture-radio { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; color: var(--text-2); cursor: pointer; }
.capture-radio input { accent-color: var(--primary); }

.capture-field[data-show-if] { display: none; }
.capture-field[data-show-if].is-visible { display: block; }

.capture-form__error {
	background: rgba(239, 68, 68, .1);
	border: 1px solid rgba(239, 68, 68, .3);
	border-radius: var(--radius-sm);
	padding: 12px 16px; margin: 16px auto;
	max-width: 640px; color: #fca5a5; font-size: 13px;
}
.capture-form__error ul { margin: 6px 0 0 18px; padding: 0; }

.capture-form__feedback {
	margin: 0; padding: 8px 12px; font-size: 13px;
	border-radius: 8px;
}
.capture-form__feedback--ok    { color: #34d399; background: rgba(16, 185, 129, .1); }
.capture-form__feedback--error { color: #fca5a5; background: rgba(239, 68, 68, .1); }

.capture-form__notice-inline {
	background: rgba(16, 185, 129, .1);
	border: 1px solid rgba(16, 185, 129, .3);
	border-radius: var(--radius-sm);
	padding: 12px 16px; margin: 0 0 16px;
	color: #34d399; font-size: 13px;
}

/* Password show/hide toggle — wraps the input so the button positions
   relative to JUST the input, not the surrounding label. */
.capture-password-wrap { position: relative; }
.capture-password-wrap input { padding-right: 40px; }
.capture-password-toggle {
	position: absolute;
	right: 12px;
	top: 50%;
	transform: translateY(-50%);
	background: none;
	border: 0;
	padding: 4px;
	color: var(--text-4);
	cursor: pointer;
	font-size: 16px;
	line-height: 1;
	display: inline-flex;
	align-items: center;
	justify-content: center;
}
.capture-password-toggle:hover { color: var(--text-2); }

/* Signup ----------------------------------------------------------- */
.capture-signup { padding: 40px 24px; }
.capture-signup-form { max-width: 1024px; margin: 0 auto; }
.capture-signup-hero { text-align: center; margin-bottom: 40px; }
.capture-signup-hero h1 { margin: 0 0 16px; font-size: 30px; color: #fff; }
.capture-signup-trust, .capture-signup-value {
	display: flex; flex-wrap: wrap; gap: 24px; justify-content: center;
	color: var(--text-3); font-size: 13px;
}
.capture-signup-trust { margin-bottom: 12px; }

.capture-step { margin-bottom: 32px; }
.capture-step h2 {
	display: flex; align-items: center; gap: 12px;
	margin: 0 0 20px; font-size: 17px; color: #fff;
}
.capture-step__num {
	display: inline-flex; align-items: center; justify-content: center;
	width: 28px; height: 28px; border-radius: 50%;
	background: rgba(14, 165, 233, .2);
	border: 1px solid rgba(14, 165, 233, .4);
	font-size: 12px; font-weight: 700; color: var(--primary-2);
}
.capture-step--narrow { max-width: 640px; margin-left: auto; margin-right: auto; }

.capture-plans {
	display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px;
}
@media (max-width: 768px) {
	.capture-plans { grid-template-columns: 1fr; }
}
.capture-plan {
	position: relative; display: block; cursor: pointer;
	padding: 24px;
	background: rgba(30, 41, 59, .3);
	border: 2px solid var(--border-2); border-radius: 16px;
	transition: background .15s, border-color .15s;
}
.capture-plan:hover { background: rgba(30, 41, 59, .5); border-color: var(--text-4); }
.capture-plan.is-selected { background: rgba(14, 165, 233, .1); border-color: var(--primary); }
.capture-plan input { position: absolute; opacity: 0; pointer-events: none; }
.capture-plan__badge {
	position: absolute; top: -10px; left: 20px;
	background: var(--primary); color: #fff;
	padding: 2px 10px; border-radius: 999px;
	font-size: 11px; font-weight: 600;
}
.capture-plan__head { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 12px; }
.capture-plan__name { font-size: 17px; font-weight: 600; color: #fff; }
.capture-plan__price { font-size: 22px; font-weight: 700; color: #fff; }
.capture-plan__price span { font-size: 13px; font-weight: 400; color: var(--text-4); }
.capture-plan__check {
	display: inline-block; width: 24px; height: 24px; border-radius: 50%;
	border: 2px solid var(--border-2); margin-top: 4px;
}
.capture-plan.is-selected .capture-plan__check {
	border-color: var(--primary); background: var(--primary);
	box-shadow: inset 0 0 0 3px var(--surface);
}
.capture-plan__features { margin: 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 6px 16px; }
.capture-plan__features li { font-size: 13px; color: var(--text-3); }
.capture-plan__features li::before { content: "✓ "; color: var(--text-4); }
.capture-plan.is-selected .capture-plan__features li::before { color: var(--primary-2); }

.capture-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 560px) { .capture-grid-2 { grid-template-columns: 1fr; } }
.capture-card--form label { display: block; margin-bottom: 16px; }
.capture-card--form label:last-child { margin-bottom: 0; }
.capture-card--form label > span {
	display: block; font-size: 13px; color: var(--text-2); font-weight: 500; margin-bottom: 6px;
}
.capture-card--form input {
	width: 100%; padding: 12px 14px;
	background: rgba(30, 41, 59, .5);
	border: 1px solid var(--border-2); border-radius: 12px;
	color: #fff; font: inherit;
}
.capture-card--form input:focus { outline: none; border-color: var(--primary); }

.capture-agreements { margin-top: 24px; display: flex; flex-direction: column; gap: 12px; }
.capture-agreements label { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; color: var(--text-3); }
.capture-agreements input { accent-color: var(--primary); margin-top: 2px; }

.capture-signup-submit {
	display: flex; align-items: center; justify-content: space-between;
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: 12px;
	padding: 16px;
	margin-top: 24px;
}
.capture-signup-submit__label { font-size: 13px; color: var(--text-3); }
.capture-signup-submit__price { font-size: 18px; font-weight: 700; color: #fff; }
.capture-signup-submit__price small { font-size: 12px; font-weight: 400; color: var(--text-4); }

.capture-signup-finepr {
	text-align: center; font-size: 12px; color: var(--text-4); margin: 8px 0 0;
}

/* "You're already signed in" notice on the signup page ------------- */
.capture-signup-already {
	max-width: 520px;
	margin: 0 auto;
	padding: 56px 24px;
	text-align: center;
}
.capture-signup-already__icon {
	width: 56px; height: 56px;
	margin: 0 auto 20px;
	border-radius: 50%;
	background: rgba(16, 185, 129, .15);
	color: #34d399;
	display: flex; align-items: center; justify-content: center;
}
.capture-signup-already__icon svg { width: 28px; height: 28px; }
.capture-signup-already h1 {
	font-size: 24px; font-weight: 700; color: #fff;
	margin: 0 0 12px;
	letter-spacing: -0.01em;
}
.capture-signup-already > p {
	color: var(--text-3); font-size: 15px;
	margin: 0 0 24px;
}
.capture-signup-already .capture-btn { padding: 14px 28px; }
.capture-signup-already__alt {
	margin-top: 24px !important;
	font-size: 13px;
	color: var(--text-4) !important;
}

/* Login ------------------------------------------------------------- */
.capture-login { padding: 80px 24px; }
.capture-login-card {
	max-width: 440px; margin: 0 auto;
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: 20px;
	padding: 40px;
}
.capture-login-card h1 {
	margin: 0 0 8px; font-size: 24px; color: #fff;
	text-align: center;
}
.capture-login-subtitle {
	margin: 0 0 24px; color: var(--text-3); text-align: center; font-size: 14px;
}
.capture-login-form { display: flex; flex-direction: column; gap: 16px; }
.capture-login-form label:not(.capture-remember) { display: block; }
.capture-login-form label:not(.capture-remember) > span {
	display: block; font-size: 13px; font-weight: 500; color: var(--text-2); margin-bottom: 6px;
}
.capture-login-form input[type="text"],
.capture-login-form input[type="password"] {
	width: 100%; padding: 12px 14px;
	background: rgba(30, 41, 59, .5);
	border: 1px solid var(--border-2); border-radius: 12px;
	color: #fff; font: inherit;
}
.capture-login-form input:focus { outline: none; border-color: var(--primary); }
.capture-remember {
	display: flex; align-items: center; gap: 8px;
	font-size: 13px; color: var(--text-3); cursor: pointer;
}
.capture-remember input { accent-color: var(--primary); }
.capture-login-form .capture-btn { margin-top: 8px; padding: 14px 24px; }

.capture-login-footer {
	margin-top: 20px; padding-top: 20px;
	border-top: 1px solid var(--border);
	text-align: center; font-size: 13px; color: var(--text-3);
}
.capture-login-footer a { color: var(--primary-2); }
.capture-login-footer a:hover { color: var(--primary); }
.capture-login-divider { margin: 0 8px; color: var(--text-4); }

/* Already-subscribed card */
.capture-already-subscribed { text-align: center; }
.capture-already-subscribed__icon {
	width: 56px; height: 56px;
	margin: 0 auto 20px;
	border-radius: 50%;
	background: rgba(16, 185, 129, .15);
	color: #34d399;
	display: flex; align-items: center; justify-content: center;
}
.capture-already-subscribed__icon svg { width: 28px; height: 28px; }
.capture-already-subscribed h1 { text-align: center; }
.capture-already-subscribed .capture-login-subtitle { margin-bottom: 24px; }
.capture-already-subscribed__actions {
	display: flex;
	flex-direction: column;
	gap: 10px;
}
.capture-already-subscribed__actions .capture-btn { width: 100%; }
@media (min-width: 480px) {
	.capture-already-subscribed__actions {
		flex-direction: row;
		justify-content: center;
	}
	.capture-already-subscribed__actions .capture-btn { width: auto; min-width: 180px; }
}

/* Inline link-styled <button> — used where we want a link's appearance
   but a button's behaviour (e.g. opens a modal). */
.capture-link-inline {
	background: none;
	border: 0;
	padding: 0;
	font: inherit;
	color: var(--primary-2);
	cursor: pointer;
	text-decoration: underline;
	text-underline-offset: 2px;
}
.capture-link-inline:hover { color: var(--primary); }

/* ── Support modal ─────────────────────────────────────────────── */
.capture-support-modal .capture-modal__panel { max-width: 520px; }
/* Honour the [hidden] attribute on view containers — the explicit
   display:flex below otherwise wins over the user-agent rule. */
[data-support-view][hidden] { display: none !important; }
.capture-support {
	display: flex;
	flex-direction: column;
	gap: 12px;
	padding: 24px;
}
.capture-support__intro {
	margin: 0 0 4px;
	font-size: 14px;
	color: var(--text-3);
}
.capture-support__option {
	display: flex;
	align-items: center;
	gap: 16px;
	padding: 16px;
	border: 1px solid var(--border-2);
	border-radius: 14px;
	background: rgba(15, 23, 42, .5);
	color: var(--text-2);
	text-align: left;
	text-decoration: none;
	cursor: pointer;
	font-family: inherit;
	font-size: inherit;
	transition: background .15s, border-color .15s, transform .15s;
	width: 100%;
}
.capture-support__option:hover {
	background: rgba(14, 165, 233, .08);
	border-color: var(--primary);
	color: var(--text-2);
	transform: translateY(-1px);
}
.capture-support__icon {
	flex-shrink: 0;
	width: 44px; height: 44px;
	border-radius: 12px;
	background: rgba(14, 165, 233, .15);
	color: #7dd3fc;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: background .15s, color .15s;
}
.capture-support__option:hover .capture-support__icon {
	background: rgba(14, 165, 233, .25);
	color: var(--primary-2);
}
.capture-support__icon svg { width: 22px; height: 22px; }
.capture-support__body {
	flex: 1;
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 4px;
}
.capture-support__title {
	font-size: 15px;
	font-weight: 600;
	color: #fff;
}
.capture-support__desc {
	font-size: 13px;
	color: var(--text-3);
	line-height: 1.5;
}
.capture-support__arrow {
	flex-shrink: 0;
	color: var(--text-4);
	font-size: 18px;
	transition: color .15s, transform .15s;
}
.capture-support__option:hover .capture-support__arrow {
	color: var(--primary-2);
	transform: translateX(2px);
}
@media (max-width: 540px) {
	.capture-support { padding: 16px; }
	.capture-support__option { padding: 14px; gap: 12px; }
	.capture-support__icon { width: 40px; height: 40px; }
	.capture-support__title { font-size: 14px; }
	.capture-support__desc { font-size: 12px; }
}

/* Support modal — form view (Forminator embed) */
.capture-support-form-view {
	padding: 16px 24px 24px;
}
.capture-support-form-back {
	background: none;
	border: 0;
	padding: 6px 8px;
	margin: 0 0 12px -8px;
	font: inherit;
	font-size: 13px;
	color: var(--text-3);
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	border-radius: 8px;
	transition: background .15s, color .15s;
}
.capture-support-form-back:hover {
	background: rgba(30, 41, 59, .5);
	color: #fff;
}
/* Tame Forminator's default styling so it sits comfortably in our dark
   modal without us having to fork their CSS. The form's own labels +
   inputs render; we just rein in the wrapper paddings. */
.capture-support-form-host { color: var(--text-2); }
.capture-support-form-host .forminator-ui,
.capture-support-form-host .forminator-design--material,
.capture-support-form-host .forminator-design--default,
.capture-support-form-host .forminator-design--flat {
	max-width: 100%;
}
.capture-support-form-host input[type="text"],
.capture-support-form-host input[type="email"],
.capture-support-form-host input[type="tel"],
.capture-support-form-host input[type="url"],
.capture-support-form-host textarea,
.capture-support-form-host select {
	/* var(--bg) is darker than the modal panel (var(--surface)), giving
	   inputs a clear "well" against the panel they sit in. */
	background: var(--bg) !important;
	color: #fff !important;
	border: 1px solid var(--border-2) !important;
	border-radius: 12px !important;
	padding: 12px 14px !important;
	font-family: inherit !important;
	font-size: 14px !important;
	box-shadow: none !important;
	width: 100% !important;
	box-sizing: border-box !important;
}
.capture-support-form-host textarea {
	min-height: 120px !important;
	line-height: 1.5 !important;
	resize: vertical !important;
}
.capture-support-form-host input::placeholder,
.capture-support-form-host textarea::placeholder {
	color: var(--text-4) !important;
}
.capture-support-form-host input:focus,
.capture-support-form-host textarea:focus,
.capture-support-form-host select:focus {
	border-color: var(--primary) !important;
	outline: none !important;
	box-shadow: 0 0 0 3px rgba(14, 165, 233, .15) !important;
}
.capture-support-form-host label {
	color: var(--text-3) !important;
}
/* Submit button — mirrors .capture-btn--primary so it reads as the
   same button family as the rest of the site, with WCAG AA contrast. */
.capture-support-form-host button[type="submit"],
.capture-support-form-host .forminator-button-submit {
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	gap: 8px !important;
	background: #1d4ed8 !important;
	color: #fff !important;
	border: 1px solid transparent !important;
	border-radius: var(--radius-sm) !important;
	padding: 12px 24px !important;
	font-family: inherit !important;
	font-size: 14px !important;
	font-weight: 600 !important;
	line-height: 1 !important;
	cursor: pointer !important;
	transition: background .15s, box-shadow .15s !important;
	box-shadow:
		0 10px 15px -3px rgba(59, 130, 246, .25),
		0 4px 6px -4px rgba(59, 130, 246, .25) !important;
}
.capture-support-form-host button[type="submit"]:hover,
.capture-support-form-host .forminator-button-submit:hover {
	background: #1e40af !important;
	box-shadow:
		0 10px 15px -3px rgba(59, 130, 246, .35),
		0 4px 6px -4px rgba(59, 130, 246, .35) !important;
}

/* ── Help page ─────────────────────────────────────────────────── */
.cap-help {
	max-width: 1200px;
	margin: 0 auto;
	padding: 56px 24px 80px;
	color: var(--text);
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
.cap-help__grid {
	display: grid;
	grid-template-columns: minmax(0, 280px) minmax(0, 1fr);
	gap: 64px;
	align-items: start;
}
html { scroll-behavior: smooth; }
.cap-help__sidebar {
	position: sticky;
	top: 88px;
	z-index: 1;
}
.cap-help__title {
	font-size: 38px;
	font-weight: 700;
	letter-spacing: -0.02em;
	color: #fff;
	margin: 0 0 12px;
	line-height: 1.1;
}
.cap-help__intro {
	font-size: 14px;
	line-height: 1.55;
	color: var(--text-3);
	margin: 0 0 24px;
}
.cap-help__nav {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}
.cap-help__nav .cap-help__nav-item {
	display: inline-flex;
	align-items: center;
	padding: 8px 16px;
	border-radius: 999px;
	border: 1px solid rgba(148, 163, 184, .25);
	background: rgba(30, 41, 59, .4);
	color: var(--text-2);
	font-size: 13px;
	font-weight: 500;
	text-decoration: none;
	transition: background .15s, color .15s, border-color .15s, box-shadow .15s;
	white-space: nowrap;
}
.cap-help__nav .cap-help__nav-item:hover {
	background: rgba(30, 41, 59, .8);
	border-color: var(--text-3);
	color: #fff;
}
.cap-help__nav .cap-help__nav-item.is-active {
	background: var(--primary);
	border-color: var(--primary);
	color: #fff;
	box-shadow: 0 4px 12px -2px rgba(14, 165, 233, .35);
}
.cap-help__main {
	min-width: 0;
	max-width: 100%;
	color: var(--text-2);
}
.cap-help__main,
.cap-help__main * {
	box-sizing: border-box;
}
.cap-help__main p,
.cap-help__main li,
.cap-help__main summary {
	overflow-wrap: anywhere;
	word-break: break-word;
}
.cap-help__main h2 {
	display: none; /* the existing "FAQ" h2 inside the content is redundant */
}
.cap-help__main h3 {
	font-size: 13px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: .05em;
	color: var(--primary-2);
	margin: 32px 0 16px;
	padding-top: 8px;
	scroll-margin-top: 96px; /* anchor offset for sticky header */
}
.cap-help__main h3:first-child { margin-top: 0; }
.cap-help__main details {
	border-top: 1px solid var(--border);
	padding: 0;
	margin: 0;
	background: transparent;
}
.cap-help__main details:last-of-type { border-bottom: 1px solid var(--border); }
.cap-help__main summary {
	list-style: none;
	cursor: pointer;
	padding: 20px 0;
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 16px;
	color: #fff;
	font-size: 16px;
	font-weight: 500;
	line-height: 1.4;
	transition: color .15s;
}
.cap-help__main summary::-webkit-details-marker { display: none; }
.cap-help__main summary::marker { font-size: 0; content: ""; }
.cap-help__main summary:hover { color: var(--primary-2); }
.cap-help__main summary::after {
	content: "+";
	flex-shrink: 0;
	width: 24px;
	height: 24px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-size: 22px;
	font-weight: 300;
	line-height: 1;
	color: var(--text-3);
	transition: transform .2s, color .15s;
}
.cap-help__main details[open] summary::after {
	content: "−";
	color: var(--primary-2);
}
.cap-help__main details > *:not(summary) {
	padding-bottom: 24px;
	font-size: 14px;
	line-height: 1.65;
	color: var(--text-2);
}
.cap-help__main details p { margin: 0 0 12px; }
.cap-help__main details p:last-child { margin-bottom: 0; }
.cap-help__main details a { color: var(--primary-2); }
.cap-help__main details a:hover { color: var(--primary); }
.cap-help__main details ul,
.cap-help__main details ol {
	/* Lock all four margin / padding sides explicitly so neither the
	   browser UA default (margin: 1em 0; padding-left: 40px) nor
	   WordPress's .wp-block-list defaults can sneak past us and push
	   the list visually wider than its container. */
	margin: 0 0 12px 0 !important;
	padding: 0 0 0 1.5em !important;
	list-style-position: outside;
	box-sizing: border-box;
	width: auto;
	max-width: 100%;
}
.cap-help__main details li {
	margin: 0 0 6px 0;
	padding: 0;
	max-width: 100%;
	box-sizing: border-box;
}
.cap-help__main details li:last-child { margin-bottom: 0; }
.cap-help__main details img,
.cap-help__main details figure img {
	display: block;
	max-width: 100%;
	width: auto;
	height: auto;
	border-radius: 8px;
	margin: 12px 0;
	border: 1px solid var(--border);
}
.cap-help__main details figure {
	margin: 12px 0;
	max-width: 100%;
}

/* Support card */
.cap-help__support {
	margin-top: 56px;
	padding: 28px;
	background: rgba(14, 165, 233, .08);
	border: 1px solid rgba(14, 165, 233, .3);
	border-radius: 16px;
	display: flex;
	align-items: center;
	gap: 20px;
	flex-wrap: wrap;
}
.cap-help__support-icon {
	flex-shrink: 0;
	width: 48px;
	height: 48px;
	border-radius: 12px;
	background: rgba(14, 165, 233, .2);
	color: #7dd3fc;
	display: flex;
	align-items: center;
	justify-content: center;
}
.cap-help__support-icon svg { width: 22px; height: 22px; }
.cap-help__support-body { flex: 1; min-width: 200px; }
.cap-help__support-body h3 {
	margin: 0 0 4px;
	font-size: 16px;
	font-weight: 600;
	color: #fff;
}
.cap-help__support-body p {
	margin: 0;
	font-size: 14px;
	color: var(--text-3);
}
.cap-help__support-body a { color: var(--primary-2); }
.cap-help__support .capture-btn { flex-shrink: 0; }

/* Mobile */
@media (max-width: 900px) {
	.cap-help { padding: 32px 20px 60px; }
	.cap-help__grid {
		grid-template-columns: 1fr;
		gap: 24px;
	}
	.cap-help__sidebar {
		position: static;
		top: auto;
	}
	.cap-help__title { font-size: 28px; }
	.cap-help__intro { margin-bottom: 16px; }
	.cap-help__nav {
		/* Wrap pills to next line on small screens — was previously a
		   horizontal scroll but the off-screen pills were getting cut
		   off without any scroll affordance. Wrapping reads better. */
		flex-wrap: wrap;
		gap: 8px;
	}
	.cap-help__support {
		margin-top: 40px;
		padding: 20px;
		flex-direction: column;
		align-items: flex-start;
		text-align: left;
	}
	.cap-help__support .capture-btn { width: 100%; justify-content: center; }
}

/* ── Äriregister autocomplete on the business modal ─────────────── */
/* Host = the .capture-field that contains the company-name input.
   Marked with this class by JS so we can position:absolute the dropdown
   relative to it. Inline-positioned (NOT portaled) — the dropdown lives
   inside the form flow, which makes it bulletproof against any
   getBoundingClientRect / scroll / stacking-context weirdness. */
.capture-arireg-host { position: relative; }
.capture-arireg__hint {
	margin-top: 6px;
	font-size: 12px;
	color: rgba(255, 255, 255, 0.65);
	line-height: 1.45;
}
.capture-arireg__dropdown {
	position: absolute;
	top: 100%;
	left: 0;
	right: 0;
	margin-top: 4px;
	max-height: 280px;
	overflow-y: auto;
	background: rgba(15, 28, 58, 0.98);
	border: 1px solid rgba(255, 255, 255, 0.18);
	border-radius: 12px;
	box-shadow: 0 16px 32px -16px rgba(0, 0, 0, .5);
	z-index: 50;
}
.capture-arireg__item {
	padding: 8px 12px;
	cursor: pointer;
	border-bottom: 1px solid rgba(255, 255, 255, .08);
	transition: background .12s;
}
.capture-arireg__item:last-child { border-bottom: 0; }
.capture-arireg__item:hover,
.capture-arireg__item.is-highlight {
	background: rgba(59, 130, 246, .18);
}
.capture-arireg__name {
	display: block;
	color: #fff;
	font-size: 13px;
	font-weight: 500;
	line-height: 1.3;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}
.capture-arireg__meta {
	display: flex;
	gap: 8px;
	margin-top: 2px;
	color: rgba(255, 255, 255, .55);
	font-size: 11px;
	line-height: 1.3;
}
.capture-arireg__code {
	flex-shrink: 0;
	font-variant-numeric: tabular-nums;
	color: rgba(255, 255, 255, .75);
}
.capture-arireg__addr {
	flex: 1;
	min-width: 0;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}
.capture-arireg__empty {
	padding: 14px;
	color: var(--text-3);
	font-size: 13px;
	text-align: center;
}
/* Subtle visual cue that a field was auto-filled from the registry —
   pale-blue left border, fades out the first time the user edits it
   (we strip the class on input/change in JS). */
.capture-arireg-filled {
	box-shadow: inset 3px 0 0 var(--accent-soft);
}
