/* ==============================================================
   Provider analytics / "Indsigt"-fane
   ============================================================== */

/* Undgå én vandret række (global .stowly-section-header bruger flex +
   space-between mellem børn — her skal titel + intro + note stable). */
.stowly-analytics > .stowly-section-header {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	justify-content: flex-start;
	gap: 4px;
	margin-bottom: 20px;
}

.stowly-analytics > .stowly-section-header h2 {
	margin: 0 0 2px;
}

.stowly-analytics > .stowly-section-header > p:not(.stowly-analytics__scope) {
	margin: 0;
	max-width: 52rem;
	font-size: 15px;
	line-height: 1.45;
	color: var(--stowly-color-ink-soft, #717171);
}

.stowly-analytics > .stowly-section-header .stowly-analytics__scope {
	margin: 12px 0 0;
	padding: 12px 14px;
	width: 100%;
	max-width: none;
	box-sizing: border-box;
	font-size: 13px;
	line-height: 1.5;
	color: var(--stowly-color-ink-soft, #717171);
	background: var(--stowly-color-surface-soft, #f9faf9);
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md, 14px);
}

.stowly-analytics__kpis {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
	gap: 14px;
	margin: 16px 0 24px;
}

.stowly-analytics__kpi {
	padding: 18px 20px;
	background: #fff;
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md, 14px);
	display: flex;
	flex-direction: column;
	gap: 4px;
	position: relative;
	overflow: hidden;
}

.stowly-analytics__kpi::before {
	content: "";
	position: absolute;
	inset: 0 auto 0 0;
	width: 3px;
	background: linear-gradient(180deg, var(--stowly-color-primary), rgba(var(--stowly-color-primary-rgb), 0.35));
	opacity: 0.85;
}

.stowly-analytics__kpi-label {
	font-size: 12px;
	font-weight: 500;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	color: var(--stowly-color-ink-soft, #717171);
}

.stowly-analytics__kpi-value {
	font-size: 28px;
	font-weight: 700;
	color: var(--stowly-color-ink);
	line-height: 1.1;
}

.stowly-analytics__kpi-trend {
	font-size: 12px;
	color: var(--stowly-color-ink-soft, #717171);
	display: flex;
	align-items: baseline;
	gap: 6px;
	flex-wrap: wrap;
}

.stowly-analytics__kpi-trend.is-up   { color: #118043; }
.stowly-analytics__kpi-trend.is-down { color: #b53a3a; }

.stowly-analytics__kpi-bench {
	color: var(--stowly-color-ink-soft, #717171);
	font-weight: 400;
}

.stowly-analytics__subhead {
	margin: 24px 0 10px;
	font-size: 16px;
}

/* Analytics-tabellen arver al chrome (wrapper-border, radius, thead-
   baggrund, række-borders, hover, link-styling) fra `.stowly-bookings-
   table-wrap` + `.stowly-bookings-table` i global.css — så den
   visuelle stil er 100% ens med bookings-tabellen. Her beholder vi
   kun de analytics-specifikke afvigelser: højrejustering af tal-
   kolonner. */
.stowly-analytics__table th:nth-child(n+2),
.stowly-analytics__table td:nth-child(n+2) {
	text-align: right;
	font-variant-numeric: tabular-nums;
}

.stowly-analytics__footnote {
	margin-top: 14px;
	font-size: 12px;
	color: var(--stowly-color-ink-soft, #717171);
	line-height: 1.45;
}

.stowly-analytics__footnote--secondary {
	margin-top: 8px;
}

/* ==============================================================
   Økonomi / payouts
   ============================================================== */
.stowly-finance__balance {
	display: grid;
	grid-template-columns: 1.4fr 1fr 1fr 1fr;
	gap: 14px;
	margin: 16px 0 28px;
}

@media (max-width: 960px) {
	.stowly-finance__balance { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
	.stowly-finance__balance { grid-template-columns: 1fr; }
}

.stowly-finance__kpi {
	padding: 20px 22px;
	background: #fff;
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md, 14px);
	display: flex;
	flex-direction: column;
	gap: 6px;
	position: relative;
	overflow: hidden;
}

.stowly-finance__kpi--primary {
	background: linear-gradient(135deg, #0f766e 0%, #065f46 100%);
	color: #fff;
	border-color: transparent;
	box-shadow: 0 8px 24px -12px rgba(6, 95, 70, 0.4);
}

.stowly-finance__kpi--primary::before {
	content: "";
	position: absolute;
	inset: -40%;
	background: radial-gradient(circle at 20% 10%, rgba(255, 255, 255, 0.18), transparent 55%);
	pointer-events: none;
}

.stowly-finance__kpi-label {
	font-size: 12px;
	font-weight: 500;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	color: var(--stowly-color-ink-soft, #717171);
	position: relative;
}

.stowly-finance__kpi--primary .stowly-finance__kpi-label {
	color: rgba(255, 255, 255, 0.85);
}

.stowly-finance__kpi-value {
	font-size: 30px;
	font-weight: 700;
	line-height: 1.1;
	color: var(--stowly-color-ink);
	position: relative;
}

.stowly-finance__kpi--primary .stowly-finance__kpi-value {
	color: #fff;
	font-size: 34px;
}

.stowly-finance__hint {
	font-size: 12px;
	color: var(--stowly-color-ink-soft, #717171);
	position: relative;
}

.stowly-finance__kpi--primary .stowly-finance__hint {
	color: rgba(255, 255, 255, 0.8);
}

.stowly-finance__payout-form {
	margin-top: 10px;
	position: relative;
}

.stowly-finance__payout-form .stowly-btn {
	width: 100%;
	justify-content: center;
	background: #fff;
	color: #065f46;
	border: 0;
	padding: 12px 18px;
	font-weight: 600;
	font-size: 15px;
	border-radius: 999px;
	transition: transform 150ms ease, box-shadow 150ms ease, background 150ms ease;
	display: inline-flex;
	align-items: center;
	gap: 8px;
}

.stowly-finance__payout-form .stowly-btn:hover:not(:disabled) {
	transform: translateY(-1px);
	box-shadow: 0 6px 16px -6px rgba(0, 0, 0, 0.3);
}

.stowly-finance__payout-form .stowly-btn:disabled {
	background: rgba(255, 255, 255, 0.35);
	color: rgba(255, 255, 255, 0.7);
	cursor: not-allowed;
}

/* Hver underside-sektion (Pr. måned, Historik, Bankoplysninger...)
   får sit eget kort, så Økonomi-tabben bliver til en lodret stak af
   klart afgrænsede blokke i stedet for en lang løs liste. */
.stowly-finance__section {
	margin-top: 28px;
	padding: 22px 24px;
	background: #fff;
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md, 14px);
	box-shadow: var(--stowly-shadow-xs, 0 1px 2px rgba(0,0,0,0.03));
}

@media (max-width: 560px) {
	.stowly-finance__section {
		padding: 18px 16px;
	}
}

.stowly-finance__section-header {
	margin-bottom: 16px;
}

.stowly-finance__subhead {
	margin: 0 0 4px;
	font-size: 17px;
	font-weight: 600;
	letter-spacing: -0.005em;
	color: var(--stowly-color-ink);
}

.stowly-finance__note {
	margin: 0;
	font-size: 13px;
	line-height: 1.5;
	color: var(--stowly-color-ink-soft, #717171);
	max-width: 640px;
}

.stowly-finance__bank-form {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 14px 16px;
	margin: 0;
}

.stowly-finance__bank-form .stowly-field--wide {
	grid-column: 1 / -1;
}

.stowly-finance__bank-form label {
	display: block;
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.02em;
	text-transform: uppercase;
	margin-bottom: 6px;
	color: var(--stowly-color-ink-soft);
}

.stowly-finance__bank-form input[type="text"] {
	width: 100%;
	padding: 12px 14px;
	background: var(--stowly-color-surface);
	border: 1px solid var(--stowly-color-line-strong, #d9d9d6);
	border-radius: var(--stowly-radius-sm, 10px);
	font-size: 15px;
	font-family: inherit;
	transition: border-color 150ms ease, box-shadow 150ms ease;
}

.stowly-finance__bank-form input[type="text"]:focus {
	outline: 0;
	border-color: var(--stowly-color-ink);
	box-shadow: 0 0 0 2px rgba(34, 34, 34, 0.08);
}

.stowly-finance__bank-actions {
	display: flex;
	justify-content: flex-end;
	margin-top: 4px;
}

.stowly-finance__bank-actions .stowly-btn {
	padding: 12px 22px;
	border-radius: var(--stowly-radius-pill, 999px);
}

@media (max-width: 560px) {
	.stowly-finance__bank-form {
		grid-template-columns: 1fr;
	}

	.stowly-finance__bank-actions .stowly-btn {
		width: 100%;
	}
}

/* Tom-state kort til Historik når der ikke er nogen udbetalinger endnu.
   Samme visuelle sprog som resten af dashboardets empty-states. */
.stowly-finance__empty-card {
	display: flex;
	align-items: center;
	gap: 14px;
	padding: 18px 20px;
	background: var(--stowly-color-surface-soft, #faf9f6);
	border: 1px dashed var(--stowly-color-line);
	border-radius: var(--stowly-radius-md, 14px);
}

.stowly-finance__empty-card p {
	margin: 0;
	font-size: 14px;
	color: var(--stowly-color-ink-soft, #717171);
	line-height: 1.5;
}

.stowly-finance__empty-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 42px;
	height: 42px;
	border-radius: 12px;
	background: #fff;
	color: var(--stowly-color-ink-soft);
	border: 1px solid var(--stowly-color-line);
	flex-shrink: 0;
}

.stowly-finance__table-wrap {
	overflow-x: auto;
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md);
	background: var(--stowly-color-surface);
}

/* Når tabellen sidder inde i et .stowly-finance__section-kort har
   sektionen allerede sin egen ydre ramme — vi lader tabellen bruge
   den i stedet for at tegne dobbelt border. */
.stowly-finance__section > .stowly-finance__table-wrap {
	border: 0;
	border-top: 1px solid var(--stowly-color-line);
	border-radius: 0;
	margin: 0 -24px -22px;
	background: transparent;
}

@media (max-width: 560px) {
	.stowly-finance__section > .stowly-finance__table-wrap {
		margin: 0 -16px -18px;
	}
}

.stowly-finance__section > .stowly-finance__table-wrap .stowly-finance__table th:first-child,
.stowly-finance__section > .stowly-finance__table-wrap .stowly-finance__table td:first-child {
	padding-left: 24px;
}

.stowly-finance__section > .stowly-finance__table-wrap .stowly-finance__table th:last-child,
.stowly-finance__section > .stowly-finance__table-wrap .stowly-finance__table td:last-child {
	padding-right: 24px;
}

@media (max-width: 560px) {
	.stowly-finance__section > .stowly-finance__table-wrap .stowly-finance__table th:first-child,
	.stowly-finance__section > .stowly-finance__table-wrap .stowly-finance__table td:first-child {
		padding-left: 16px;
	}

	.stowly-finance__section > .stowly-finance__table-wrap .stowly-finance__table th:last-child,
	.stowly-finance__section > .stowly-finance__table-wrap .stowly-finance__table td:last-child {
		padding-right: 16px;
	}
}

.stowly-finance__table {
	width: 100%;
	border-collapse: collapse;
	border-spacing: 0;
	font-size: 14px;
	background: transparent;
}

.stowly-finance__table th,
.stowly-finance__table td {
	padding: 14px 16px;
	text-align: left;
	border-bottom: 1px solid var(--stowly-color-line);
	vertical-align: middle;
	white-space: nowrap;
}

.stowly-finance__table th {
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.02em;
	text-transform: uppercase;
	color: var(--stowly-color-ink-soft);
	background: var(--stowly-color-surface-soft);
}

.stowly-finance__table td {
	color: var(--stowly-color-ink);
	font-variant-numeric: tabular-nums;
}

.stowly-finance__table tbody tr { transition: background 120ms ease; }
.stowly-finance__table tbody tr:hover td { background: var(--stowly-color-surface-soft); }
.stowly-finance__table tbody tr:last-child td { border-bottom: 0; }

/* "Download bilag"-link i udbetalingshistorikken. */
.stowly-bilag-link {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-size: 13px;
	font-weight: 600;
	color: var(--stowly-color-ink);
	text-decoration: underline;
	text-underline-offset: 2px;
	white-space: nowrap;
}
.stowly-bilag-link:hover,
.stowly-bilag-link:focus-visible {
	color: var(--stowly-color-brand, #1f1d1a);
	text-decoration-thickness: 2px;
}

/* Månedlig udbetalings-oversigt: fremhæv det man rent faktisk kan trække
   ud nu, så udbyderen med ét blik ser "hvad kan jeg få ud i dag?". */
.stowly-finance__table--months td:first-child strong {
	color: var(--stowly-color-ink);
	font-weight: 600;
}

.stowly-finance__amount-available {
	color: #118043;
	font-weight: 700;
}

.stowly-finance__release-cell { text-align: right; }

.stowly-finance__dash {
	color: var(--stowly-color-ink-soft);
}

/* Generiske pills til dashboard-tabeller. Bruges i "Frigives"-kolonnen
   og kan genbruges andre steder uden at rode med status-specifikke
   klasser. */
.stowly-pill {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	padding: 3px 10px;
	border-radius: 999px;
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.01em;
	white-space: nowrap;
	line-height: 1.4;
}

.stowly-pill--success {
	background: #e3f8ec;
	color: #118043;
}

.stowly-pill--muted {
	background: var(--stowly-color-surface-soft);
	color: var(--stowly-color-ink-soft);
}

.stowly-finance__empty {
	padding: 16px;
	color: var(--stowly-color-ink-soft, #717171);
	font-size: 14px;
}

/* Payout status pills (bruges både i dashboard og admin-listen) */
.stowly-payout-status {
	display: inline-block;
	padding: 2px 10px;
	border-radius: 999px;
	font-size: 12px;
	font-weight: 500;
	background: #f3f3f3;
	color: #555;
}

.stowly-payout-status--requested { background: #fff6e1; color: #7a4500; }
.stowly-payout-status--processing { background: #dbeafe; color: #1e3a8a; }
.stowly-payout-status--paid { background: #e3f8ec; color: #118043; }
.stowly-payout-status--failed { background: #fee2e2; color: #991b1b; }
.stowly-payout-status--cancelled { background: #f3f3f3; color: #555; }

/* ==============================================================
   Stripe wallet — økonomi-fanen (Connect + saldo + withdraw)
   Matcher dashboardets kort/KPI-sprog; indigo-accent for Stripe.
   ============================================================== */
.stowly-finance--wallet {
	display: flex;
	flex-direction: column;
	gap: 20px;
}

.stowly-finance--wallet__title {
	margin: 0;
	font-size: 22px;
	font-weight: 700;
	letter-spacing: -0.02em;
	line-height: 1.25;
	color: var(--stowly-color-ink);
}

.stowly-wallet-sheet {
	background: #fff;
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md, 14px);
	padding: 22px 24px 24px;
	box-shadow: 0 1px 0 rgba(0, 0, 0, 0.03);
}

.stowly-wallet-connect {
	font-size: 15px;
	line-height: 1.55;
	color: var(--stowly-color-ink);
}

.stowly-wallet-connect > p {
	margin: 0 0 10px;
}

.stowly-wallet-connect > p:last-of-type {
	margin-bottom: 0;
}

.stowly-wallet-connect code {
	display: inline-block;
	margin-top: 4px;
	padding: 4px 10px;
	font-size: 12px;
	font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
	background: var(--stowly-color-surface-soft, #f6f6f5);
	border-radius: 8px;
	border: 1px solid var(--stowly-color-line);
	word-break: break-all;
}

.stowly-wallet-connect .stowly-btn {
	margin-top: 4px;
}

.stowly-wallet-connect .stowly-finance__note {
	margin-top: 14px;
	margin-bottom: 0;
}

.stowly-wallet-connect .stowly-finance__note a {
	font-weight: 600;
	color: var(--stowly-color-primary);
	text-decoration: underline;
	text-underline-offset: 2px;
}

.stowly-wallet-connect .stowly-finance__note a:hover {
	color: var(--stowly-color-primary-hover);
}

/* Badges i Connect-blokken (globale .stowly-badge findes ikke altid) */
.stowly-wallet-connect .stowly-badge {
	display: inline-flex;
	align-items: center;
	padding: 4px 12px;
	border-radius: 999px;
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.02em;
	margin-left: 6px;
	vertical-align: middle;
}

.stowly-wallet-connect .stowly-badge--success {
	background: #e3f8ec;
	color: #118043;
}

.stowly-wallet-connect .stowly-badge--warning {
	background: #fff7ed;
	color: #c2410c;
}

.stowly-wallet-connect .stowly-badge--muted {
	background: var(--stowly-color-surface-soft, #f6f6f5);
	color: var(--stowly-color-ink-soft, #717171);
}

.stowly-wallet__inline-form {
	display: inline-block;
	margin-top: 12px;
}

.stowly-wallet__notice {
	padding: 16px 18px;
	border-radius: var(--stowly-radius-md, 12px);
	margin-bottom: 20px;
	border: 1px solid transparent;
}

.stowly-wallet__notice strong {
	display: block;
	font-size: 15px;
	margin-bottom: 6px;
	letter-spacing: -0.01em;
}

.stowly-wallet__notice p {
	margin: 0;
	font-size: 14px;
	line-height: 1.55;
	color: var(--stowly-color-ink);
}

.stowly-wallet__notice--warning {
	background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
	border-color: #fcd34d;
	color: #78350f;
}

.stowly-wallet__notice--warning .stowly-btn {
	margin-top: 12px;
}

.stowly-wallet__notice--muted {
	background: var(--stowly-color-surface-soft, #f6f6f5);
	border-color: var(--stowly-color-line);
	color: var(--stowly-color-ink);
}

.stowly-wallet__notice--muted a {
	font-weight: 600;
	color: var(--stowly-color-primary);
	margin-left: 4px;
}

.stowly-wallet__notice--muted a:hover {
	color: var(--stowly-color-primary-hover);
}

.stowly-wallet__dashboard-link {
	margin: 0 0 18px;
}

.stowly-wallet__dashboard-link a {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-weight: 600;
	font-size: 14px;
	color: var(--stowly-color-primary);
	text-decoration: none;
	padding: 8px 14px;
	border-radius: 999px;
	border: 1px solid rgba(var(--stowly-color-primary-rgb), 0.35);
	background: rgba(var(--stowly-color-primary-rgb), 0.06);
	transition: background 150ms ease, border-color 150ms ease, transform 150ms ease;
}

.stowly-wallet__dashboard-link a:hover {
	background: rgba(var(--stowly-color-primary-rgb), 0.12);
	border-color: rgba(var(--stowly-color-primary-rgb), 0.55);
	transform: translateY(-1px);
}

.stowly-wallet__balances {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 14px;
	margin: 0 0 22px;
}

@media (max-width: 920px) {
	.stowly-wallet__balances {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 520px) {
	.stowly-wallet__balances {
		grid-template-columns: 1fr;
	}
}

.stowly-wallet__kpi {
	padding: 18px 20px;
	background: #fff;
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md, 14px);
	display: flex;
	flex-direction: column;
	gap: 6px;
	position: relative;
	overflow: hidden;
}

.stowly-wallet__kpi--primary {
	background: #fff;
	border-color: var(--stowly-color-line);
	box-shadow: none;
	border-left: 3px solid var(--stowly-color-primary);
}

.stowly-wallet__kpi--primary::before {
	display: none;
}

.stowly-wallet__label {
	font-size: 11px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	color: var(--stowly-color-ink-soft, #717171);
	position: relative;
}

.stowly-wallet__kpi--primary .stowly-wallet__label {
	color: var(--stowly-color-ink-soft, #717171);
}

.stowly-wallet__value {
	font-size: 28px;
	font-weight: 700;
	line-height: 1.1;
	color: var(--stowly-color-ink);
	font-variant-numeric: tabular-nums;
	position: relative;
}

.stowly-wallet__kpi--primary .stowly-wallet__value {
	color: var(--stowly-color-ink);
	font-size: 28px;
}

.stowly-wallet__balance-hints {
	margin: -8px 0 18px;
	padding: 12px 14px;
	font-size: 13px;
	line-height: 1.45;
	color: var(--stowly-color-ink-soft, #717171);
	background: var(--stowly-color-surface-soft, #f9faf9);
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md, 14px);
}

.stowly-wallet__balance-hints-line {
	margin: 0;
}

.stowly-wallet__balance-hints-line + .stowly-wallet__balance-hints-line {
	margin-top: 8px;
}

.stowly-wallet__balance-hints-line--test {
	font-size: 12px;
	font-style: italic;
}

.stowly-wallet__form {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto;
	gap: 12px 14px;
	align-items: end;
	padding: 18px 20px;
	margin-bottom: 22px;
	background: var(--stowly-color-surface-soft, #f9faf9);
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md, 14px);
}

@media (max-width: 560px) {
	.stowly-wallet__form {
		grid-template-columns: 1fr;
		align-items: stretch;
	}

	.stowly-wallet__form .stowly-btn {
		width: 100%;
		justify-content: center;
	}
}

.stowly-wallet__form label {
	grid-column: 1 / -1;
	font-size: 12px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	color: var(--stowly-color-ink-soft, #717171);
	margin: 0;
}

.stowly-wallet__form input[type="number"] {
	width: 100%;
	min-width: 0;
	padding: 12px 14px;
	font-size: 16px;
	font-weight: 600;
	font-variant-numeric: tabular-nums;
	border: 1px solid var(--stowly-color-line);
	border-radius: 10px;
	background: #fff;
	color: var(--stowly-color-ink);
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.stowly-wallet__form input[type="number"]:focus {
	outline: none;
	border-color: var(--stowly-color-primary);
	box-shadow: 0 0 0 3px rgba(var(--stowly-color-primary-rgb), 0.18);
}

.stowly-wallet__form input[type="number"]:disabled {
	opacity: 0.55;
	cursor: not-allowed;
	background: #f3f3f3;
}

.stowly-wallet__form .stowly-btn--primary {
	padding: 12px 22px;
	font-weight: 600;
	border-radius: 999px;
	white-space: nowrap;
}

.stowly-wallet__hint {
	grid-column: 1 / -1;
	margin: -4px 0 0;
	font-size: 12px;
	color: var(--stowly-color-ink-soft, #717171);
}

.stowly-wallet__feedback {
	grid-column: 1 / -1;
	min-height: 1.25em;
	font-size: 13px;
	font-weight: 500;
}

.stowly-wallet__feedback--success {
	color: #118043;
}

.stowly-wallet__feedback--error {
	color: #b91c1c;
}

.stowly-wallet__transactions-title {
	margin: 0 0 12px;
	font-size: 13px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	color: var(--stowly-color-ink-soft, #717171);
}

.stowly-wallet__table {
	width: 100%;
	border-collapse: collapse;
	font-size: 14px;
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md, 12px);
	overflow: hidden;
	background: #fff;
}

.stowly-wallet__table th,
.stowly-wallet__table td {
	padding: 12px 14px;
	text-align: left;
	border-bottom: 1px solid var(--stowly-color-line);
	vertical-align: middle;
}

.stowly-wallet__table th {
	font-size: 11px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	color: var(--stowly-color-ink-soft, #717171);
	background: var(--stowly-color-surface-soft, #f6f6f5);
}

.stowly-wallet__table td {
	font-variant-numeric: tabular-nums;
	color: var(--stowly-color-ink);
}

.stowly-wallet__table tbody tr:last-child td {
	border-bottom: 0;
}

.stowly-wallet__table tbody tr:hover td {
	background: var(--stowly-color-surface-soft, #fafafa);
}

.stowly-wallet__section {
	margin-top: 28px;
}

.stowly-wallet__section-header {
	margin-bottom: 12px;
}

.stowly-wallet__section-note {
	margin: 4px 0 0;
	font-size: 13px;
	color: var(--stowly-color-ink-soft, #717171);
	line-height: 1.45;
}

.stowly-wallet__empty {
	margin: 0;
	padding: 16px 18px;
	font-size: 14px;
	color: var(--stowly-color-ink-soft, #717171);
	background: var(--stowly-color-surface-soft, #f6f6f5);
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md, 12px);
}

.stowly-wallet__table-wrap {
	overflow-x: auto;
}

/* ==============================================================
   Entity-type selector (privat/virksomhed)
   — Bruges både på signup-forms og i Oplysninger-fanen. Et sæt
     side-om-side kort hvor den valgte får en farvet ramme.
   ============================================================== */
.stowly-entity-type__hint {
	margin: 0 0 12px;
	font-size: 13px;
	color: var(--stowly-color-ink-soft);
}

/* Kort notits om DAC7-bundfradraget under entity-type-valget i
   provider-signup. Visuelt en lille "good news"-box, ikke en
   advarsel — grøn tone matcher bundfradrag-boksen i Økonomi-tabben. */
.stowly-entity-type__bundfradrag {
	margin: 14px 0 0;
	padding: 10px 14px;
	border-left: 3px solid #1d6a3b;
	background: #f3faf4;
	border-radius: 6px;
	font-size: 13px;
	color: #1f1d1a;
	line-height: 1.5;
}
.stowly-entity-type__bundfradrag strong {
	color: #1d6a3b;
}

.stowly-entity-type__options {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 12px;
	max-width: 640px;
}

@media (max-width: 560px) {
	.stowly-entity-type__options { grid-template-columns: 1fr; }
}

.stowly-entity-type__option {
	position: relative;
	display: block;
	cursor: pointer;
	margin: 0;
}

.stowly-entity-type__option input[type="radio"] {
	position: absolute;
	opacity: 0;
	inset: 0;
	width: 100%;
	height: 100%;
	cursor: pointer;
	margin: 0;
}

.stowly-entity-type__card {
	display: block;
	padding: 14px 16px;
	border: 2px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md, 14px);
	background: #fff;
	transition: border-color 150ms ease, background 150ms ease, transform 150ms ease, box-shadow 150ms ease;
}

.stowly-entity-type__card strong {
	display: block;
	font-size: 14px;
	margin-bottom: 2px;
	color: var(--stowly-color-ink);
	font-weight: 600;
}

.stowly-entity-type__card small {
	display: block;
	font-size: 12px;
	color: var(--stowly-color-ink-soft);
	line-height: 1.4;
}

.stowly-entity-type__option input[type="radio"]:checked + .stowly-entity-type__card {
	border-color: var(--stowly-color-ink);
	background: var(--stowly-color-surface-soft);
	box-shadow: 0 1px 0 rgba(0,0,0,0.04);
}

.stowly-entity-type__option input[type="radio"]:focus-visible + .stowly-entity-type__card {
	outline: 2px solid rgba(0,0,0,0.25);
	outline-offset: 2px;
}

.stowly-entity-type__option:hover .stowly-entity-type__card {
	transform: translateY(-1px);
}

/* Signup-forms (fieldset direkte i formen, uden .stowly-profile-form
   som container). Nulstil fieldset-default og giv lidt luft. */
.stowly-entity-type--signup {
	border: 0;
	padding: 0;
	margin: 0 0 18px;
}

.stowly-entity-type--signup legend {
	padding: 0;
	margin-bottom: 6px;
	font-size: 15px;
	font-weight: 600;
	color: var(--stowly-color-ink);
}

/* ==============================================================
   Skatteoplysninger (DAC7) — rendered i Økonomi-tabben
   ============================================================== */
.stowly-tax {
	margin-top: 28px;
	padding: 22px 24px;
	background: #fff;
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md, 14px);
	box-shadow: var(--stowly-shadow-xs, 0 1px 2px rgba(0,0,0,0.03));
}

/* Live privat/virksomhed-skift: skjul de felter der ikke hører til den
   valgte entity-type. `[hidden]` alene rækker ikke, fordi grid-labels
   og bundfradrag-boksen har en eksplicit `display` (flex) der vinder
   over UA-stylesheetets `[hidden]{display:none}` — derfor !important. */
.stowly-tax [data-entity][hidden] {
	display: none !important;
}

@media (max-width: 560px) {
	.stowly-tax {
		padding: 18px 16px;
	}
}

.stowly-tax .stowly-section-header {
	align-items: flex-start;
	margin-bottom: 16px;
}

.stowly-tax .stowly-section-header h3 {
	margin: 0 0 4px;
	font-size: 17px;
	font-weight: 600;
	letter-spacing: -0.005em;
}

.stowly-section-header__sub {
	margin: 0;
	font-size: 13px;
	color: var(--stowly-color-ink-soft);
	max-width: 640px;
	line-height: 1.5;
}

.stowly-tax__entity-pill {
	flex-shrink: 0;
}

/* Informations-kort der vises når udbyderen endnu ikke har valgt
   entity-type. Erstatter det gamle switcher-UI. */
.stowly-tax__missing-type {
	display: flex;
	gap: 14px;
	align-items: flex-start;
	padding: 16px 18px;
	max-width: 640px;
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md, 14px);
	background: var(--stowly-color-surface-soft, #faf9f6);
}

.stowly-tax__missing-type .stowly-btn {
	padding: 10px 18px;
	border-radius: var(--stowly-radius-pill, 999px);
}

.stowly-tax__missing-type-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	border-radius: 10px;
	background: #fff6e1;
	color: #7a4500;
	flex-shrink: 0;
}

.stowly-tax__missing-type-body strong {
	display: block;
	font-size: 15px;
	color: var(--stowly-color-ink);
	margin-bottom: 4px;
}

.stowly-tax__missing-type-body p {
	margin: 0 0 12px;
	font-size: 13px;
	color: var(--stowly-color-ink-soft);
	line-height: 1.5;
}

/* Info-boks der forklarer DAC7-bundfradraget til private udbydere.
   Grøn tone for at signalere "skattefri fordel", ikke advarsel. */
.stowly-tax__bundfradrag-box {
	display: flex;
	gap: 14px;
	align-items: flex-start;
	padding: 14px 16px;
	margin: 0 0 20px;
	max-width: 640px;
	border: 1px solid #cfe9d6;
	border-radius: var(--stowly-radius-md, 14px);
	background: #f3faf4;
}

.stowly-tax__bundfradrag-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	border-radius: 8px;
	background: #dcf0de;
	color: #1d6a3b;
	flex-shrink: 0;
}

.stowly-tax__bundfradrag-body strong {
	display: block;
	font-size: 14px;
	color: var(--stowly-color-ink);
	margin-bottom: 4px;
}

.stowly-tax__bundfradrag-body p {
	margin: 0;
	font-size: 13px;
	color: var(--stowly-color-ink-soft);
	line-height: 1.5;
}

.stowly-tax__bundfradrag-body a {
	color: #1d6a3b;
	text-decoration: underline;
	text-underline-offset: 2px;
}

/* Moms-registreret-toggle for CVR-udbydere. Visuelt en pæn
   checkbox-række med titel + forklarende hjælpetekst, så det ikke
   blot ligner "endnu et felt". */
.stowly-tax__vat-toggle {
	display: flex;
	gap: 12px;
	align-items: flex-start;
	padding: 12px 14px;
	margin-top: 4px;
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md, 14px);
	background: var(--stowly-color-surface-soft, #faf9f6);
	cursor: pointer;
}

.stowly-tax__vat-toggle > input[type="checkbox"] {
	margin-top: 3px;
	flex-shrink: 0;
}

.stowly-tax__vat-toggle > span {
	display: block;
	min-width: 0;
}

.stowly-tax__vat-toggle > span strong {
	display: block;
	font-size: 14px;
	margin-bottom: 4px;
	color: var(--stowly-color-ink);
}

.stowly-tax__vat-toggle > span small {
	display: block;
	font-size: 12.5px;
	color: var(--stowly-color-ink-soft);
	line-height: 1.5;
}

/* Tax-formen skal visuelt matche bank-formen: ingen indre kort-ramme
   (sektionskortet ovenfor er allerede et kort), uppercase labels, og
   en mørk pill-knap yderst til højre. Vi overrider derfor den arv
   der kommer fra .stowly-profile-form. */
.stowly-tax__form.stowly-profile-form {
	padding: 0;
	border: 0;
	background: transparent;
	max-width: none;
	gap: 16px;
}

.stowly-tax__form .stowly-profile-form__grid {
	gap: 14px 16px;
}

.stowly-tax__form .stowly-profile-form__grid label {
	gap: 6px;
}

.stowly-tax__form .stowly-profile-form__grid label > span {
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.02em;
	text-transform: uppercase;
	color: var(--stowly-color-ink-soft);
}

/* CPR-pillen skal beholde sin egen casing inde i label-spanen. */
.stowly-tax__form .stowly-profile-form__grid label > span .stowly-tax__cpr-mask {
	text-transform: none;
	letter-spacing: 0;
	font-weight: 500;
}

.stowly-tax__form .stowly-profile-form__grid input {
	padding: 12px 14px;
	border: 1px solid var(--stowly-color-line-strong, #d9d9d6);
	border-radius: var(--stowly-radius-sm, 10px);
	font-size: 15px;
	background: var(--stowly-color-surface);
	transition: border-color 150ms ease, box-shadow 150ms ease;
}

.stowly-tax__form .stowly-profile-form__grid input:focus {
	outline: 0;
	border-color: var(--stowly-color-ink);
	box-shadow: 0 0 0 2px rgba(34, 34, 34, 0.08);
}

.stowly-tax__form .stowly-profile-form__hint {
	font-size: 12px;
	margin: 4px 0 0;
}

.stowly-tax__form .stowly-profile-form__actions {
	justify-content: flex-end;
	padding-top: 0;
	margin-top: 4px;
}

.stowly-tax__form .stowly-profile-form__actions .stowly-btn {
	padding: 12px 22px;
	border-radius: var(--stowly-radius-pill, 999px);
}

@media (max-width: 560px) {
	.stowly-tax__form .stowly-profile-form__actions .stowly-btn {
		width: 100%;
	}
}

.stowly-tax__cpr-label {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	flex-wrap: wrap;
}

.stowly-tax__cpr-mask {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	padding: 2px 8px;
	border-radius: 999px;
	background: #e3f8ec;
	color: #118043;
	font-size: 11px;
	font-weight: 500;
	font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

.stowly-tax__cpr-mask svg { width: 12px; height: 12px; }

.stowly-tax__secure-hint {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	color: var(--stowly-color-ink-soft);
}


/* ---------- New listing form (create / edit) ---------- */
.stowly-listing-form {
	display: flex;
	flex-direction: column;
	gap: 20px;
	/* Trin-nummerering på sektionsheaders — skjulte sektioner (display:none
	   via [hidden]) tæller ikke med, så rækkefølgen passer altid. */
	counter-reset: stowly-form-section;
}

.stowly-listing-form__section {
	background: var(--stowly-color-surface);
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md);
	padding: 22px 24px;
	counter-increment: stowly-form-section;
}

/* Kopi-noten er en infoboks, ikke et trin — den skal ikke nummereres. */
.stowly-listing-form__section--copies-note {
	counter-increment: none;
}

.stowly-listing-form__section-header {
	display: grid;
	grid-template-columns: auto 1fr;
	column-gap: 12px;
	row-gap: 2px;
	align-items: center;
	margin-bottom: 18px;
	padding-bottom: 14px;
	border-bottom: 1px solid var(--stowly-color-line);
}
.stowly-listing-form__section-header::before {
	content: counter(stowly-form-section);
	grid-row: 1 / span 2;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 30px;
	height: 30px;
	border-radius: 999px;
	background: rgba(var(--stowly-color-primary-rgb), 0.08);
	box-shadow: inset 0 0 0 1px rgba(var(--stowly-color-primary-rgb), 0.22);
	color: var(--stowly-color-primary);
	font-size: 13px;
	font-weight: 700;
	font-variant-numeric: tabular-nums;
}
.stowly-listing-form__section--copies-note .stowly-listing-form__section-header::before {
	content: none;
}
.stowly-listing-form__section-header h3 {
	margin: 0;
	font-size: 17px;
	font-weight: 700;
	letter-spacing: -0.01em;
	color: var(--stowly-color-ink);
}
.stowly-listing-form__section-header p {
	grid-column: 2;
	margin: 0;
	color: var(--stowly-color-ink-soft);
	font-size: 13px;
	line-height: 1.5;
	max-width: 70ch;
}

/* "Min Plads tager X %"-notice øverst i pris-sektionen, så udbyderen ikke
   bliver overrasket over udbetalingen. Diskret info-card der spejler
   .stowly-field__readonly-stilen, ikke en alarm. */
.stowly-listing-form__fee-notice {
	display: flex;
	gap: 12px;
	align-items: flex-start;
	padding: 14px 16px;
	margin: 0 0 18px;
	background: rgba(var(--stowly-color-primary-rgb), 0.06);
	border: 1px solid rgba(var(--stowly-color-primary-rgb), 0.18);
	border-radius: var(--stowly-radius-md);
	color: var(--stowly-color-ink);
}
.stowly-listing-form__fee-notice-icon {
	flex: 0 0 auto;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	border-radius: 999px;
	background: var(--stowly-color-primary);
	color: #fff;
}
.stowly-listing-form__fee-notice-icon svg {
	width: 16px;
	height: 16px;
}
.stowly-listing-form__fee-notice-body {
	display: flex;
	flex-direction: column;
	gap: 4px;
	font-size: 13px;
	line-height: 1.5;
}
.stowly-listing-form__fee-notice-body strong {
	font-size: 14px;
	font-weight: 700;
	color: var(--stowly-color-ink);
}
.stowly-listing-form__fee-notice-body span {
	color: var(--stowly-color-ink-soft);
}
.stowly-listing-form__fee-notice-example {
	margin-top: 4px;
	padding-top: 8px;
	border-top: 1px dashed rgba(var(--stowly-color-primary-rgb), 0.24);
	color: var(--stowly-color-ink) !important;
}
.stowly-listing-form__fee-notice-example strong {
	color: var(--stowly-color-primary);
	font-size: 13px;
}

.stowly-listing-form__grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 16px;
}
.stowly-listing-form__grid--three {
	grid-template-columns: repeat(3, 1fr);
}

/* Native `[hidden]` loses til `display:flex` fra `.stowly-field` — tving
   skjul så depositum-/afhentningsfelter rent faktisk forsvinder. */
.stowly-field[hidden] {
	display: none !important;
}

.stowly-field {
	display: flex;
	flex-direction: column;
	gap: 6px;
	min-width: 0;
}
.stowly-field--full {
	grid-column: 1 / -1;
}
.stowly-field > span {
	font-size: 13px;
	font-weight: 500;
	color: var(--stowly-color-ink);
	text-transform: none;
	letter-spacing: normal;
}
/* Rød markering er kun til den påkrævede asterisk i feltlabels —
   toggle-hints (em i .stowly-field__toggle-label) skal forblive grå. */
.stowly-field > span:not(.stowly-field__toggle-label) em {
	color: #e61e4d;
	font-style: normal;
	margin-left: 2px;
}
.stowly-field input,
.stowly-field select,
.stowly-field textarea {
	min-height: 44px;
}

/* Native <select> i udbyder- og kontofaner + annonceformular */
.stowly-provider-dashboard .stowly-tab-panel select,
.stowly-account .stowly-tab-panel select,
.stowly-listing-form select {
	width: 100%;
	max-width: 100%;
	padding: 10px 40px 10px 14px;
	font-size: 14px;
	line-height: 1.4;
	font-family: inherit;
	color: var(--stowly-color-ink);
	background-color: var(--stowly-color-surface);
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 14 14' fill='none'%3E%3Cpath d='M3.5 5.25L7 8.75l3.5-3.5' stroke='%2364748b' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 12px center;
	background-size: 14px 14px;
	border: 1px solid var(--stowly-color-line);
	border-radius: 10px;
	appearance: none;
	-webkit-appearance: none;
	-moz-appearance: none;
	cursor: pointer;
	transition: border-color 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}
.stowly-provider-dashboard .stowly-tab-panel select:hover,
.stowly-account .stowly-tab-panel select:hover,
.stowly-listing-form select:hover {
	border-color: var(--stowly-color-ink-soft, #94a3b8);
}
.stowly-provider-dashboard .stowly-tab-panel select:focus,
.stowly-account .stowly-tab-panel select:focus,
.stowly-listing-form select:focus {
	outline: none;
	border-color: var(--stowly-color-ink);
	box-shadow: 0 0 0 3px rgba(15, 23, 42, 0.08);
}
.stowly-provider-dashboard .stowly-tab-panel select:disabled,
.stowly-account .stowly-tab-panel select:disabled,
.stowly-listing-form select:disabled {
	opacity: 0.55;
	cursor: not-allowed;
}

.stowly-field--toggle {
	grid-column: 1 / -1;
	flex-direction: row !important;
	align-items: flex-start;
	gap: 12px;
	padding: 14px 16px;
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md);
	background: var(--stowly-color-surface-soft);
}

.stowly-field--toggle input[type="checkbox"] {
	margin-top: 2px;
	width: 18px;
	height: 18px;
	min-height: 0;
	flex: 0 0 auto;
	accent-color: var(--stowly-color-ink);
}

.stowly-field__toggle-label {
	display: flex;
	flex-direction: column;
	gap: 2px;
	min-width: 0;
}

.stowly-field__toggle-label strong {
	font-size: 14px;
	font-weight: 600;
	color: var(--stowly-color-ink);
}

.stowly-field__toggle-label em {
	font-style: normal;
	font-size: 12px;
	color: var(--stowly-color-ink-soft);
}

.stowly-field__hint {
	font-size: 12px;
	color: var(--stowly-color-ink-soft);
	font-style: normal;
	margin-top: 2px;
}

.stowly-field__warn {
	margin: 0;
	padding: 10px 12px;
	border-radius: var(--stowly-radius-sm);
	background: #fff8e6;
	border: 1px solid #e8c96e;
	color: #5c4300;
	font-size: 13px;
	line-height: 1.45;
}

.stowly-listing-form__dimensions {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.stowly-listing-form__dimensions-sqm {
	max-width: 280px;
}

.stowly-listing-form__dimensions-calc {
	margin: 0;
}

.stowly-listing-form__min-period-custom {
	margin-top: 8px;
}

/* DAWA-adresseforslag (udbyder → annonce → Placering) */
.stowly-field__address-wrap {
	position: relative;
	display: block;
	width: 100%;
}

.stowly-address-suggest {
	position: absolute;
	left: 0;
	right: 0;
	top: calc(100% + 4px);
	z-index: 40;
	margin: 0;
	padding: 6px 0;
	list-style: none;
	max-height: 260px;
	overflow-y: auto;
	background: var(--stowly-color-surface);
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md, 14px);
	box-shadow: var(--stowly-shadow-md, 0 8px 24px rgba(0, 0, 0, 0.08));
}

.stowly-address-suggest__item {
	padding: 10px 14px;
	font-size: 14px;
	line-height: 1.35;
	cursor: pointer;
	color: var(--stowly-color-ink);
}

.stowly-address-suggest__item:hover,
.stowly-address-suggest__item:focus {
	background: var(--stowly-color-surface-soft, #f7f7f5);
	outline: none;
}

/* Flatpickr på "Ledig fra dato" i annonce-formularen — samme static-
   layout som i "Markér udlejet"-dialogen så kalenderen ikke flyver væk. */
.stowly-listing-form .flatpickr-wrapper {
	position: relative;
	display: block;
	width: 100%;
}

.stowly-listing-form .flatpickr-calendar.static {
	top: calc(100% + 6px);
	left: 0;
	right: auto;
	z-index: 35;
}

.stowly-listing-form .flatpickr-wrapper .flatpickr-input[readonly] {
	width: 100%;
	box-sizing: border-box;
}

/* Read-only visning af platformspolitikker i udbyder-formularen.
   Bruges fx til den samlede annulleringspolitik der ikke længere kan
   konfigureres per listing — udbyderen skal stadig kunne se hvad der
   gælder, men uden dropdown-picker. */
.stowly-field--readonly {
	display: block;
}
.stowly-field--readonly .stowly-field__label {
	display: block;
	font-size: 13px;
	font-weight: 600;
	color: var(--stowly-color-ink);
	margin-bottom: 6px;
}
.stowly-field__static {
	padding: 14px 16px;
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md, 14px);
	background: var(--stowly-color-surface-soft, #faf9f6);
}
.stowly-field__static strong {
	display: block;
	font-size: 14px;
	margin-bottom: 8px;
	color: var(--stowly-color-ink);
}
.stowly-field__static ul {
	margin: 0 0 8px;
	padding-left: 18px;
	font-size: 13px;
	color: var(--stowly-color-ink);
	line-height: 1.55;
}
.stowly-field__static ul li + li {
	margin-top: 2px;
}
.stowly-field__static .stowly-field__hint {
	display: block;
	margin-top: 6px;
}

/* ---------- Access mode picker ---------- *
 * Structured "Adgang" replaces the legacy free-text access_hours
 * field. Renders as a 4-up grid of card-style radio pills; the two
 * conditional time blocks (weekday / weekend) are toggled by
 * js/global.js based on the selected mode.
 */
.stowly-access-modes {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 10px;
	margin: 0 0 16px;
	padding: 0;
	border: 0;
}

.stowly-access-mode {
	position: relative;
	display: block;
	cursor: pointer;
}

.stowly-access-mode input[type="radio"] {
	position: absolute;
	opacity: 0;
	pointer-events: none;
	width: 0;
	height: 0;
}

.stowly-access-mode__inner {
	display: flex;
	flex-direction: column;
	gap: 4px;
	height: 100%;
	padding: 12px 14px;
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md);
	background: var(--stowly-color-surface);
	transition: border-color 150ms ease, background 150ms ease, box-shadow 150ms ease, transform 150ms ease;
}

.stowly-access-mode:hover .stowly-access-mode__inner {
	border-color: var(--stowly-color-ink);
	transform: translateY(-1px);
}

.stowly-access-mode input[type="radio"]:checked + .stowly-access-mode__inner {
	border-color: var(--stowly-color-ink);
	background: var(--stowly-color-surface-soft);
	box-shadow: inset 0 0 0 1px var(--stowly-color-ink);
}

.stowly-access-mode input[type="radio"]:focus-visible + .stowly-access-mode__inner {
	box-shadow: 0 0 0 3px rgba(27, 27, 27, 0.15);
}

.stowly-access-mode__label {
	font-size: 14px;
	font-weight: 600;
	color: var(--stowly-color-ink);
}

.stowly-access-mode__hint {
	font-size: 12px;
	font-style: normal;
	color: var(--stowly-color-ink-soft);
	line-height: 1.35;
}

/* Conditional time blocks — shown/hidden by JS via the [hidden] attr. */
/* ----------------------------------------------------------
   Access-times card (Hverdage / Weekend) — provider dashboard
   ----------------------------------------------------------
   Two fields ("Åbner" and "Lukker") presented as a single pill
   of a card with a little clock icon on the title, custom time
   inputs (hidden UA spinners, nicer focus ring, tabular numbers)
   and a subtle arrow separator between open and close to
   visually suggest a range. */

.stowly-access-times {
	margin: 0 0 14px;
	padding: 16px 18px 18px;
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-lg, 14px);
	background: var(--stowly-color-surface);
	box-shadow: 0 1px 2px rgba(17, 17, 17, 0.03);
	transition: border-color 160ms ease, box-shadow 160ms ease;
}

.stowly-access-times:hover {
	border-color: var(--stowly-color-line-strong, #dcdcdc);
}

.stowly-access-times:focus-within {
	border-color: var(--stowly-color-ink);
	box-shadow: 0 0 0 3px rgba(17, 17, 17, 0.06);
}

.stowly-access-times[hidden] {
	display: none;
}

.stowly-access-times__title {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin: 0 0 12px;
	font-size: 13px;
	font-weight: 600;
	color: var(--stowly-color-ink);
	text-transform: none;
	letter-spacing: normal;
}

/* Little clock glyph tucked in front of the title. Pure CSS so we
   don't have to touch the provider-dashboard.php markup. */
.stowly-access-times__title::before {
	content: "";
	width: 22px;
	height: 22px;
	border-radius: 999px;
	background: var(--stowly-color-surface-soft, #f7f7f7);
	flex: none;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23222' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpolyline points='12 6 12 12 16 14'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: center;
	background-size: 14px 14px;
}

.stowly-access-times .stowly-listing-form__grid--tight {
	gap: 14px;
}

/* Labels above the inputs — smaller, softer, uppercase-light so
   they read as captions rather than field titles. */
.stowly-access-times .stowly-field > span {
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--stowly-color-ink-soft);
}

/* ---------------------------------------------------------------
 * Custom time picker
 * ---------------------------------------------------------------
 * The native <input type="time"> dropdown is inconsistent and ugly
 * across browsers, so we swap it out for a bespoke popover (see
 * `.stowly-timepop` below and the JS in global.js). The <input>
 * itself stays in the DOM as the form value holder — we just
 * suppress the browser UI and paint a clock icon on top of it.
 * The field is marked `readonly` in PHP so the native virtual
 * keyboard / picker never fights with our custom popover.
 * --------------------------------------------------------------- */

.stowly-timefield {
	position: relative;
}

.stowly-timefield input[type="time"],
.stowly-access-times .stowly-field input[type="time"] {
	appearance: none;
	-webkit-appearance: none;
	-moz-appearance: none;
	width: 100%;
	min-height: 48px;
	padding: 10px 40px 10px 14px; /* reserve room for the clock glyph */
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md, 12px);
	background: var(--stowly-color-surface);
	color: var(--stowly-color-ink);
	font: inherit;
	font-size: 15px;
	font-weight: 600;
	font-variant-numeric: tabular-nums;
	letter-spacing: 0.02em;
	line-height: 1;
	cursor: pointer;
	caret-color: transparent;
	transition: border-color 140ms ease, box-shadow 140ms ease,
		background 140ms ease;
}

.stowly-timefield input[type="time"]:hover,
.stowly-access-times .stowly-field input[type="time"]:hover {
	border-color: var(--stowly-color-line-strong);
}

.stowly-timefield input[type="time"]:focus,
.stowly-timefield input[type="time"]:focus-visible,
.stowly-timefield input[type="time"].is-active,
.stowly-access-times .stowly-field input[type="time"]:focus,
.stowly-access-times .stowly-field input[type="time"]:focus-visible,
.stowly-access-times .stowly-field input[type="time"].is-active {
	outline: none;
	border-color: var(--stowly-color-ink);
	box-shadow: 0 0 0 3px rgba(17, 17, 17, 0.08);
}

/* Hide every native affordance — the calendar indicator, the inner
   spinners, any prefix text — so the input reads as a plain pill
   that we layer our own clock icon on top of. */
.stowly-timefield input[type="time"]::-webkit-calendar-picker-indicator,
.stowly-access-times .stowly-field input[type="time"]::-webkit-calendar-picker-indicator {
	display: none;
	-webkit-appearance: none;
	appearance: none;
}

.stowly-timefield input[type="time"]::-webkit-inner-spin-button,
.stowly-timefield input[type="time"]::-webkit-outer-spin-button,
.stowly-access-times .stowly-field input[type="time"]::-webkit-inner-spin-button,
.stowly-access-times .stowly-field input[type="time"]::-webkit-outer-spin-button {
	appearance: none;
	-webkit-appearance: none;
	margin: 0;
}

/* Our own clock glyph — positioned absolutely over the right edge
   of the input and made click-through so the input still captures
   the tap and our JS can open the popover. */
.stowly-timefield::after {
	content: "";
	position: absolute;
	top: 50%;
	right: 12px;
	width: 18px;
	height: 18px;
	transform: translateY(calc(-50% + 10px)); /* label above pushes vertical center down */
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%23444' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpolyline points='12 6 12 12 16 14'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: center;
	background-size: 18px 18px;
	opacity: 0.55;
	pointer-events: none;
	transition: opacity 140ms ease;
}

.stowly-timefield:hover::after,
.stowly-timefield:focus-within::after {
	opacity: 0.9;
}

/* ---------------------------------------------------------------
 * Custom time popover (JS-driven)
 * ---------------------------------------------------------------
 * Rendered once and anchored under the active time input. Two
 * scroll columns (hours / minutes) with a snap-highlight in the
 * middle, plus a quick-preset row and a footer with Ryd/Færdig
 * actions. The popover lives in <body> so it can escape any
 * overflow-hidden ancestors.
 * --------------------------------------------------------------- */

.stowly-timepop {
	position: absolute;
	z-index: 9000;
	display: none;
	width: 280px;
	max-width: calc(100vw - 24px);
	padding: 14px 14px 12px;
	background: var(--stowly-color-surface);
	border: 1px solid var(--stowly-color-line);
	border-radius: 16px;
	box-shadow: 0 24px 48px rgba(17, 17, 17, 0.18),
		0 4px 12px rgba(17, 17, 17, 0.08);
	color: var(--stowly-color-ink);
	opacity: 0;
	transform: translateY(-4px) scale(0.98);
	transform-origin: top center;
	transition: opacity 140ms ease, transform 140ms ease;
	pointer-events: none;
}

.stowly-timepop.is-open {
	display: block;
	opacity: 1;
	transform: translateY(0) scale(1);
	pointer-events: auto;
}

/* Two-column scroll body */
.stowly-timepop__body {
	position: relative;
	display: grid;
	grid-template-columns: 1fr auto 1fr;
	gap: 6px;
	align-items: stretch;
	padding: 4px 0;
}

/* Horizontal rails at the top + bottom of the middle row so the
   "current selection" position is always visible. Uses a fixed
   row height (see __col) to keep the math simple. */
.stowly-timepop__body::before,
.stowly-timepop__body::after {
	content: "";
	position: absolute;
	left: 4px;
	right: 4px;
	height: 1px;
	background: var(--stowly-color-line);
	pointer-events: none;
}

.stowly-timepop__body::before {
	top: calc(50% - 18px);
}

.stowly-timepop__body::after {
	top: calc(50% + 18px);
}

.stowly-timepop__col {
	position: relative;
	height: 180px; /* 5 rows × 36px */
	overflow-y: auto;
	scroll-snap-type: y mandatory;
	scrollbar-width: none;
	padding: 72px 0; /* leaves 2 rows of headroom so the first/last
	                   item can sit centered in the highlight row */
}

.stowly-timepop__col::-webkit-scrollbar {
	display: none;
}

/* Soft top/bottom fade so out-of-focus rows look less busy than
   the centered, selectable one. */
.stowly-timepop__col {
	mask-image: linear-gradient(
		180deg,
		transparent 0%,
		#000 25%,
		#000 75%,
		transparent 100%
	);
	-webkit-mask-image: linear-gradient(
		180deg,
		transparent 0%,
		#000 25%,
		#000 75%,
		transparent 100%
	);
}

.stowly-timepop__opt {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 36px;
	padding: 0;
	border: 0;
	background: transparent;
	color: var(--stowly-color-ink-soft);
	font-size: 15px;
	font-weight: 600;
	font-variant-numeric: tabular-nums;
	letter-spacing: 0.04em;
	cursor: pointer;
	scroll-snap-align: center;
	border-radius: 10px;
	transition: background 120ms ease, color 120ms ease,
		transform 120ms ease;
	-webkit-tap-highlight-color: transparent;
	outline: none;
	/* Some browsers + the global button reset can leak a blue focus /
	   active background into these rows. Lock every interactive
	   pseudo-state to the neutral grey we want. */
	user-select: none;
	-webkit-user-select: none;
}

.stowly-timepop__opt:hover,
.stowly-timepop__opt:focus,
.stowly-timepop__opt:focus-visible {
	background: var(--stowly-color-surface-soft, #f7f7f7);
	color: var(--stowly-color-ink);
	outline: none;
	box-shadow: none;
}

.stowly-timepop__opt:active {
	background: var(--stowly-color-surface-soft, #f7f7f7);
	color: var(--stowly-color-ink);
	outline: none;
	box-shadow: none;
}

.stowly-timepop__opt.is-active {
	color: var(--stowly-color-ink);
	font-size: 17px;
	font-weight: 800;
	transform: scale(1.04);
	background: transparent;
}

/* Middle separator — a simple colon that sits between the two
   scroll columns and doesn't move. */
.stowly-timepop__sep {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 12px;
	color: var(--stowly-color-ink);
	font-size: 20px;
	font-weight: 800;
	letter-spacing: 0.04em;
}

/* Footer actions */
.stowly-timepop__foot {
	display: flex;
	justify-content: space-between;
	gap: 8px;
	margin: 8px 0 0;
	padding: 10px 0 0;
	border-top: 1px solid var(--stowly-color-line);
}

.stowly-timepop__btn {
	flex: 1 1 auto;
	padding: 9px 14px;
	border-radius: 999px;
	border: 1px solid transparent;
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 0.01em;
	cursor: pointer;
	transition: background 140ms ease, color 140ms ease,
		border-color 140ms ease, transform 140ms ease;
	-webkit-tap-highlight-color: transparent;
}

.stowly-timepop__btn--ghost {
	background: transparent;
	color: var(--stowly-color-ink-soft);
	border-color: var(--stowly-color-line);
}

.stowly-timepop__btn--ghost:hover,
.stowly-timepop__btn--ghost:focus-visible {
	color: var(--stowly-color-ink);
	background: var(--stowly-color-surface-soft, #f7f7f7);
	border-color: var(--stowly-color-line-strong);
	outline: none;
}

.stowly-timepop__btn--primary {
	background: var(--stowly-color-ink);
	color: #fff;
	border-color: var(--stowly-color-ink);
}

.stowly-timepop__btn--primary:hover,
.stowly-timepop__btn--primary:focus-visible {
	background: #000;
	border-color: #000;
	transform: translateY(-1px);
	outline: none;
}

.stowly-listing-form__grid--tight {
	gap: 12px;
}

@media (max-width: 560px) {
	.stowly-access-times {
		padding: 14px 14px 16px;
	}

	/* Stack labels on top of each other on narrow screens. */
	.stowly-access-times .stowly-listing-form__grid--tight {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 700px) {
	.stowly-access-modes {
		grid-template-columns: repeat(2, 1fr);
	}
}

.stowly-field__affix {
	position: relative;
	display: flex;
	align-items: center;
}
.stowly-field__affix input {
	padding-right: 48px !important;
}
.stowly-field__suffix {
	position: absolute;
	right: 14px;
	color: var(--stowly-color-ink-soft);
	font-size: 14px;
	font-weight: 500;
	pointer-events: none;
}

/* Image uploader drop-zone */
.stowly-uploader {
	position: relative;
	display: flex;
	align-items: center;
	gap: 16px;
	padding: 18px;
	border: 1px dashed var(--stowly-color-line-strong);
	border-radius: var(--stowly-radius-md);
	background: var(--stowly-color-surface-soft);
	cursor: pointer;
	transition: border-color 150ms ease, background 150ms ease;
	overflow: hidden;
}
.stowly-uploader:hover {
	border-color: var(--stowly-color-ink);
	background: var(--stowly-color-surface);
}
.stowly-uploader__body {
	display: flex;
	flex-direction: column;
	gap: 2px;
	flex: 1;
	color: var(--stowly-color-ink-soft);
}
.stowly-uploader__body strong {
	color: var(--stowly-color-ink);
	font-size: 14px;
	font-weight: 600;
}
.stowly-uploader__body span {
	font-size: 12px;
}
.stowly-uploader__preview {
	flex-shrink: 0;
	width: 72px;
	height: 72px;
	border-radius: var(--stowly-radius-sm);
	background-size: cover;
	background-position: center;
	border: 1px solid var(--stowly-color-line);
}
.stowly-uploader input[type="file"] {
	position: absolute;
	inset: 0;
	opacity: 0;
	cursor: pointer;
	width: 100%;
	height: 100%;
}
.stowly-uploader.has-file {
	border-style: solid;
	border-color: var(--stowly-color-ink);
	background: var(--stowly-color-surface);
}

/* Current main image preview card (sits above the uploader so users
   can see what's uploaded today and remove it if needed). Kept outside
   the uploader <label> so the "Fjern" control doesn't trigger the
   hidden file input. */
.stowly-main-image {
	gap: 10px;
}
.stowly-main-image__current {
	display: flex;
	align-items: center;
	gap: 14px;
	padding: 12px;
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md);
	background: var(--stowly-color-surface);
	margin-bottom: 8px;
}
.stowly-main-image__preview {
	flex-shrink: 0;
	width: 96px;
	height: 72px;
	object-fit: cover;
	border-radius: var(--stowly-radius-sm);
	border: 1px solid var(--stowly-color-line);
	background: var(--stowly-color-surface-soft);
}
.stowly-main-image__info {
	flex: 1;
	display: flex;
	flex-direction: column;
	gap: 2px;
	min-width: 0;
}
.stowly-main-image__info strong {
	font-size: 14px;
	font-weight: 600;
	color: var(--stowly-color-ink);
}
.stowly-main-image__info span {
	font-size: 12px;
	color: var(--stowly-color-ink-soft);
	line-height: 1.4;
}
.stowly-main-image__remove {
	flex-shrink: 0;
	cursor: pointer;
	margin: 0;
}
.stowly-main-image__remove input[type="checkbox"] {
	position: absolute;
	opacity: 0;
	pointer-events: none;
}
.stowly-main-image__remove-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 8px 12px;
	border: 1px solid var(--stowly-color-line);
	border-radius: 999px;
	background: var(--stowly-color-surface);
	color: var(--stowly-color-ink-soft);
	font-size: 13px;
	font-weight: 500;
	line-height: 1;
	transition: background 150ms ease, color 150ms ease, border-color 150ms ease;
}
.stowly-main-image__remove:hover .stowly-main-image__remove-btn,
.stowly-main-image__remove:focus-within .stowly-main-image__remove-btn {
	background: #fdecec;
	border-color: #e5b3b3;
	color: #b32d2e;
}
.stowly-main-image__current.is-pending-remove {
	opacity: 0.5;
	border-style: dashed;
}
.stowly-main-image__current.is-pending-remove .stowly-main-image__preview {
	filter: grayscale(1);
}
.stowly-main-image__pending {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin: 0 0 8px;
	padding: 8px 12px;
	border-radius: var(--stowly-radius-sm);
	background: #fdecec;
	color: #b32d2e;
	font-size: 13px;
}

/* The default `display: inline-flex` above beats the user-agent
   `[hidden] { display: none }` rule because it's specified on the
   class. Put the attribute selector back in charge so the banner
   stays hidden until JS flips `pending.hidden = false` after the
   provider actually clicks "Fjern hovedbillede". */
.stowly-main-image__pending[hidden] {
	display: none;
}
.stowly-main-image__undo {
	border: 0;
	background: transparent;
	padding: 0;
	margin-left: 4px;
	color: inherit;
	text-decoration: underline;
	text-underline-offset: 3px;
	font: inherit;
	cursor: pointer;
}
.stowly-main-image__undo:hover,
.stowly-main-image__undo:focus-visible {
	color: #8a1f1f;
}

@media (max-width: 540px) {
	.stowly-main-image__current {
		flex-wrap: wrap;
	}
	.stowly-main-image__info {
		flex-basis: calc(100% - 110px);
	}
	.stowly-main-image__remove {
		flex-basis: 100%;
	}
	.stowly-main-image__remove-btn {
		width: 100%;
		justify-content: center;
	}
}

/* Gallery uploader (multi-image) */
.stowly-gallery-uploader {
	display: flex;
	flex-direction: column;
	gap: 12px;
}
.stowly-gallery-uploader__grid {
	list-style: none;
	padding: 0;
	margin: 0;
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
	gap: 10px;
}
.stowly-gallery-uploader__item {
	position: relative;
	aspect-ratio: 4 / 3;
	border-radius: var(--stowly-radius-sm);
	overflow: hidden;
	border: 1px solid var(--stowly-color-line);
	background: var(--stowly-color-surface-soft);
	transition: transform 150ms ease, opacity 150ms ease;
}
.stowly-gallery-uploader__item.is-dragging {
	opacity: 0.55;
	z-index: 4;
	box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
}
.stowly-gallery-uploader__item--pending {
	border-style: dashed;
}
.stowly-gallery-uploader__handle {
	position: absolute;
	left: 6px;
	top: 6px;
	z-index: 3;
	width: 30px;
	height: 30px;
	padding: 0;
	margin: 0;
	border: 0;
	border-radius: 8px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	cursor: grab;
	background: rgba(255, 255, 255, 0.95);
	color: var(--stowly-color-ink);
	box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
}
.stowly-gallery-uploader__handle:active {
	cursor: grabbing;
}
.stowly-gallery-uploader__handle:focus-visible {
	outline: 2px solid var(--stowly-color-accent, #e91e8c);
	outline-offset: 2px;
}
.stowly-gallery-uploader__cover-badge {
	position: absolute;
	left: 6px;
	bottom: 6px;
	z-index: 3;
	font-size: 11px;
	font-weight: 600;
	line-height: 1;
	padding: 4px 9px;
	border-radius: 999px;
	background: rgba(0, 0, 0, 0.55);
	color: #fff;
	pointer-events: none;
}
.stowly-gallery-uploader__pending-remove {
	position: absolute;
	top: 6px;
	right: 6px;
	z-index: 3;
	width: 28px;
	height: 28px;
	padding: 0;
	margin: 0;
	border: 0;
	border-radius: 50%;
	font-size: 18px;
	line-height: 1;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background: rgba(255, 255, 255, 0.95);
	color: #b32d2e;
	box-shadow: 0 1px 4px rgba(0, 0, 0, 0.15);
}
.stowly-gallery-uploader__pending-remove:hover,
.stowly-gallery-uploader__pending-remove:focus-visible {
	background: #fdecec;
}
.stowly-gallery-uploader__item img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}
.stowly-gallery-uploader__remove {
	position: absolute;
	top: 6px;
	right: 6px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
}
.stowly-gallery-uploader__remove input[type="checkbox"] {
	position: absolute;
	opacity: 0;
	pointer-events: none;
}
.stowly-gallery-uploader__remove-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 26px;
	height: 26px;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.95);
	color: var(--stowly-color-ink);
	box-shadow: 0 1px 4px rgba(0, 0, 0, 0.18);
	transition: background 150ms ease, transform 150ms ease;
}
.stowly-gallery-uploader__remove:hover .stowly-gallery-uploader__remove-icon {
	background: #fff;
	transform: scale(1.05);
}
.stowly-gallery-uploader__remove input[type="checkbox"]:checked ~ .stowly-gallery-uploader__remove-icon {
	background: #d14343;
	color: #fff;
}
.stowly-gallery-uploader__item:has(input[type="checkbox"]:checked) {
	opacity: 0.4;
	outline: 2px dashed #d14343;
	outline-offset: -2px;
}
.stowly-uploader--gallery {
	justify-content: center;
	text-align: left;
}

/* Categories */
.stowly-listing-form__category + .stowly-listing-form__category {
	margin-top: 16px;
}
.stowly-listing-form__category-label {
	display: block;
	font-size: 13px;
	font-weight: 500;
	color: var(--stowly-color-ink);
	margin-bottom: 10px;
}
.stowly-listing-form__fee-notice--error {
	border-color: rgba(230, 30, 77, 0.45);
	background: rgba(230, 30, 77, 0.06);
}
.stowly-listing-form__fee-notice--error .stowly-listing-form__fee-notice-body strong {
	color: #e61e4d;
}

/* Sticky action bar */
.stowly-listing-form__actions {
	display: flex;
	justify-content: flex-end;
	gap: 10px;
	padding: 16px 0 0;
	border-top: 1px solid var(--stowly-color-line);
	margin-top: 4px;
}
.stowly-listing-form__actions .stowly-btn {
	padding: 12px 24px;
}

@media (max-width: 720px) {
	.stowly-listing-form__grid,
	.stowly-listing-form__grid--three {
		grid-template-columns: 1fr;
	}
	.stowly-listing-form__section {
		padding: 18px;
	}
	.stowly-listing-form__actions {
		flex-direction: column-reverse;
	}
	.stowly-listing-form__actions .stowly-btn {
		width: 100%;
	}
}

/* ==========================================================================
   External rental (Markér udlejet) — listings-tabellen
   --------------------------------------------------------------------------
   Lille inline-pille på annoncer som i øjeblikket er markeret som
   udlejet et andet sted. Samme visuelle sprog som verified-badge
   (soft-pink baggrund + primary tekst) så det straks aflæses som et
   "obs — denne rækkes status har ændret sig".
   ========================================================================== */

.stowly-external-rental-badge {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	margin-left: 8px;
	padding: 2px 8px 2px 6px;
	background: var(--stowly-color-primary-soft, #e6f2f1);
	border: 1px solid rgba(var(--stowly-color-primary-rgb), 0.24);
	border-radius: var(--stowly-radius-pill, 999px);
	color: var(--stowly-color-primary);
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.02em;
	white-space: nowrap;
	vertical-align: 1px;
}
.stowly-external-rental-badge svg {
	width: 11px;
	height: 11px;
}

/* Tving rækkens action-kolonne til at layoute knapperne side-om-side
   i stedet for at stakle dem lodret — kolonnen er bred nok til 2–3
   små knapper på desktop. */
.stowly-bookings-table__actions-row {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	/* Hold "Markér udlejet" + "Rediger" på samme linje — den
	   indeholdende <td> har i forvejen white-space: nowrap, så
	   vi tvinger også flex-containeren til ikke at bryde om. */
	flex-wrap: nowrap;
	justify-content: flex-end;
}
.stowly-bookings-table__actions-row form {
	margin: 0;
}

/* Release-formularen er en bare-bones POST-form; vi vil ikke have
   standard form-margin eller baggrund der skaber støj i rækken. */
.stowly-external-rental-release-form {
	display: inline;
}

/* ==========================================================================
   Listing duplicates — master/kopi-badges + "opdatér kopier?" banner
   --------------------------------------------------------------------------
   Providere kan oprette flere identiske enheder af samme annonce. Vi
   markerer hver række i "Dine annoncer"-tabellen med enten en
   master-chip (tæller kopier) eller en kopi-chip (henviser til
   master). Banneret øverst vises lige efter en redigering af en
   master og tilbyder at pushe ændringerne ud til alle kopier.
   ========================================================================== */

.stowly-listing-copy-badge {
	display: inline-flex;
	align-items: center;
	margin-left: 8px;
	padding: 2px 9px;
	border-radius: var(--stowly-radius-pill, 999px);
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.02em;
	white-space: nowrap;
	vertical-align: 1px;
	line-height: 1.3;
}

.stowly-listing-copy-badge--master {
	background: rgba(15, 23, 42, 0.06);
	color: var(--stowly-color-ink, #111);
	border: 1px solid rgba(15, 23, 42, 0.12);
}

.stowly-listing-copy-badge--child {
	background: var(--stowly-color-surface-soft, #f4f4f0);
	color: var(--stowly-color-ink-soft, #555);
	border: 1px solid var(--stowly-color-line, #e9e6e4);
}

/* Banner: bevidst to-linjet (body + actions) så knapperne ikke
   kolliderer med en lang forklarende tekst på mindre skærme. Bruger
   den eksisterende .stowly-alert som base, og lægger bare grid-layout
   ovenpå for at sprede indhold + knapper pænt. */
.stowly-alert.stowly-sync-banner {
	display: grid;
	grid-template-columns: 1fr;
	gap: 16px;
	align-items: start;
}

@media (min-width: 720px) {
	.stowly-alert.stowly-sync-banner {
		grid-template-columns: minmax(0, 1fr) auto;
		align-items: center;
	}
}

.stowly-sync-banner__body {
	min-width: 0;
	display: grid;
	gap: 4px;
}

.stowly-sync-banner__title {
	display: block;
	font-size: 15px;
	font-weight: 700;
	color: var(--stowly-color-ink, #111);
}

.stowly-sync-banner__text {
	margin: 0;
	font-size: 14px;
	line-height: 1.45;
	color: var(--stowly-color-ink, #111);
}

.stowly-sync-banner__note {
	margin: 2px 0 0;
	font-size: 12px;
	line-height: 1.45;
	color: var(--stowly-color-ink-soft, #555);
}

.stowly-sync-banner__actions {
	display: inline-flex;
	flex-wrap: wrap;
	gap: 8px;
	margin: 0;
}

.stowly-sync-banner__actions .stowly-btn {
	flex: 0 0 auto;
}

/* "Opret ny"-sektion i create-formularen — lidt løftet frem så det
   står tydeligt at man er ved at kopiere, ikke en almindelig
   input-række. */
.stowly-listing-form__section--copies {
	background: linear-gradient(180deg, rgba(var(--stowly-color-primary-rgb), 0.05) 0%, rgba(var(--stowly-color-primary-rgb), 0.02) 100%);
	border: 1px solid rgba(var(--stowly-color-primary-rgb), 0.15);
	border-radius: var(--stowly-radius-md, 14px);
	padding: 20px 20px 16px;
}

/* Kopi-noten har intet trin-nummer — headeren falder tilbage til
   almindelig blok-layout så h3 og tekst stables. */
.stowly-listing-form__section--copies-note .stowly-listing-form__section-header {
	display: block;
	margin-bottom: 0;
	padding-bottom: 0;
	border-bottom: 0;
}

.stowly-listing-form__section--copies-note .stowly-listing-form__section-header p {
	margin-top: 4px;
}

.stowly-listing-form__section--copies .stowly-field input[type="number"] {
	max-width: 140px;
}

/* ==========================================================================
   Trash / restore — soft-delete af annoncer
   --------------------------------------------------------------------------
   En annonce kan flyttes til "Slettede annoncer" (WordPress-trash) så
   udbyderen kan gendanne den. Knappen i action-rækken får en let
   rød accent så det visuelt står klart at det er en destruktiv
   handling, uden at skrige for meget sammenlignet med "Rediger".
   ========================================================================== */

.stowly-listing-trash-form {
	display: inline;
	margin: 0;
}

.stowly-bookings-table__actions-row--trashed {
	display: inline-flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
}

.stowly-btn--ghost.stowly-btn--danger {
	color: #b42318;
	border-color: rgba(180, 35, 24, 0.25);
	background: transparent;
}

.stowly-btn--ghost.stowly-btn--danger:hover,
.stowly-btn--ghost.stowly-btn--danger:focus-visible {
	color: #fff;
	background: #b42318;
	border-color: #b42318;
}

/* "Slettede annoncer" collapsed section. Dæmpet baggrund + minder
   visuelt om en arkiv-skuffe — så det ikke konkurrerer med den
   aktive annonceliste ovenfor. */
.stowly-trashed-listings {
	margin-top: 24px;
	padding: 0;
	border: 1px solid var(--stowly-color-line, #e9e6e4);
	border-radius: var(--stowly-radius-md, 14px);
	background: var(--stowly-color-surface-soft, #f7f6f4);
	overflow: hidden;
}

.stowly-trashed-listings__summary {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 10px;
	padding: 14px 18px;
	cursor: pointer;
	list-style: none;
	color: var(--stowly-color-ink, #111);
	transition: background-color 0.15s ease;
}

.stowly-trashed-listings__summary::-webkit-details-marker {
	display: none;
}

.stowly-trashed-listings__summary::after {
	content: "";
	width: 10px;
	height: 10px;
	margin-left: auto;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg) translate(-2px, -2px);
	opacity: 0.6;
	transition: transform 0.2s ease;
}

.stowly-trashed-listings[open] .stowly-trashed-listings__summary::after {
	transform: rotate(-135deg) translate(-2px, -2px);
}

.stowly-trashed-listings__summary:hover,
.stowly-trashed-listings__summary:focus-visible {
	background: rgba(15, 23, 42, 0.035);
	outline: none;
}

.stowly-trashed-listings__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	color: var(--stowly-color-ink-soft, #555);
}

.stowly-trashed-listings__label {
	font-size: 14px;
	font-weight: 700;
}

.stowly-trashed-listings__hint {
	font-size: 12px;
	color: var(--stowly-color-ink-soft, #555);
	font-weight: 400;
}

.stowly-trashed-listings .stowly-bookings-table-wrap {
	margin: 0;
	border-top: 1px solid var(--stowly-color-line, #e9e6e4);
	background: var(--stowly-color-surface);
}

.stowly-bookings-table--trashed tbody td {
	color: var(--stowly-color-ink-soft, #555);
}

.stowly-bookings-table--trashed tbody td strong {
	color: var(--stowly-color-ink, #111);
}

/* ==========================================================================
   Min Plads dialog — generic modal base + external-rental variant
   --------------------------------------------------------------------------
   Brug native <dialog> til focus-trap + backdrop gratis. Vi styler
   selve ::backdrop blødt så det matcher brandet i stedet for den
   rå sort/gennemsigtig default.
   ========================================================================== */



/* ==========================================================
 * Pending-approval banner
 * Sætter en varm amber-baggrund, et pulserende ur-ikon og
 * stak-layout med titel + forklaring, så udbyderen tydeligt
 * forstår at kontoen afventer godkendelse — ikke bare "en
 * neutral info-boks man kan scrolle forbi".
 * ========================================================== */

.stowly-pending-banner {
	position: relative;
	display: flex;
	align-items: flex-start;
	gap: 14px;
	padding: 16px 20px 16px 18px;
	margin: 0 0 20px;
	border-radius: 14px;
	overflow: hidden;
	background:
		linear-gradient( 135deg, #fff6e1 0%, #fde4c4 100% );
	color: #7a4500;
	border: 1px solid rgba( 194, 119, 15, 0.25 );
	box-shadow:
		0 1px 0 rgba( 17, 17, 17, 0.02 ),
		0 10px 24px rgba( 201, 119, 15, 0.12 );
	isolation: isolate;
}

/* Den friske post-signup variant er grøn/mintet for at signalere
   "du er igennem — velkommen". Den venter-variant er amber. */
.stowly-pending-banner--fresh {
	background:
		linear-gradient( 135deg, #e8f7ec 0%, #cfeedd 100% );
	color: #0a5f3e;
	border-color: rgba( 10, 143, 92, 0.28 );
	box-shadow:
		0 1px 0 rgba( 17, 17, 17, 0.02 ),
		0 10px 24px rgba( 10, 143, 92, 0.12 );
}

.stowly-pending-banner__icon {
	flex: 0 0 auto;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	border-radius: 50%;
	background: rgba( 255, 255, 255, 0.7 );
	color: #c2770f;
	box-shadow: inset 0 0 0 1px rgba( 194, 119, 15, 0.18 );
}

.stowly-pending-banner--fresh .stowly-pending-banner__icon {
	color: #0a8f5c;
	box-shadow: inset 0 0 0 1px rgba( 10, 143, 92, 0.22 );
}

.stowly-pending-banner__icon svg {
	display: block;
}

.stowly-pending-banner__body {
	flex: 1 1 auto;
	min-width: 0;
}

.stowly-pending-banner__title {
	margin: 0 0 4px;
	font-size: 15px;
	font-weight: 700;
	letter-spacing: -0.01em;
	line-height: 1.25;
}

.stowly-pending-banner__text {
	margin: 0;
	font-size: 13.5px;
	line-height: 1.5;
	color: inherit;
	opacity: 0.9;
}

/* Let pulsing dot i højre hjørne så bannerne "lever" og fanger
   øjet. Reduceret hvis brugeren har prefers-reduced-motion. */
.stowly-pending-banner__pulse {
	position: absolute;
	top: 14px;
	right: 16px;
	width: 10px;
	height: 10px;
	border-radius: 50%;
	background: #c2770f;
	box-shadow: 0 0 0 0 rgba( 194, 119, 15, 0.6 );
	animation: stowly-pending-pulse 1.8s ease-out infinite;
}

.stowly-pending-banner--fresh .stowly-pending-banner__pulse {
	background: #0a8f5c;
	box-shadow: 0 0 0 0 rgba( 10, 143, 92, 0.55 );
	animation-name: stowly-pending-pulse-green;
}

@keyframes stowly-pending-pulse {
	0%   { box-shadow: 0 0 0 0 rgba( 194, 119, 15, 0.55 ); }
	70%  { box-shadow: 0 0 0 10px rgba( 194, 119, 15, 0 ); }
	100% { box-shadow: 0 0 0 0 rgba( 194, 119, 15, 0 ); }
}

@keyframes stowly-pending-pulse-green {
	0%   { box-shadow: 0 0 0 0 rgba( 10, 143, 92, 0.55 ); }
	70%  { box-shadow: 0 0 0 10px rgba( 10, 143, 92, 0 ); }
	100% { box-shadow: 0 0 0 0 rgba( 10, 143, 92, 0 ); }
}

@media (prefers-reduced-motion: reduce) {
	.stowly-pending-banner__pulse {
		animation: none;
	}
}

@media (max-width: 560px) {
	.stowly-pending-banner {
		padding: 14px 16px;
		gap: 12px;
	}
	.stowly-pending-banner__icon {
		width: 34px;
		height: 34px;
	}
	.stowly-pending-banner__icon svg {
		width: 18px;
		height: 18px;
	}
	.stowly-pending-banner__pulse {
		top: 12px;
		right: 12px;
	}
	.stowly-pending-banner__title {
		font-size: 14px;
	}
	.stowly-pending-banner__text {
		font-size: 13px;
	}
}

/* ============================================================
   Sticky "Hvad kan jeg gøre nu?" CTA for unapproved providers.
   Lever som en lille bar i bunden af viewportet på mobil, så en
   ny udbyder altid har en tydelig næste handling at klikke på
   (= udfyld profil) selv hvis de scroller forbi pending-banneret.
   På desktop står den som en almindelig boks under dashboardet.
   ============================================================ */
.stowly-pending-cta {
	position: sticky;
	bottom: 12px;
	margin: 16px auto 0;
	z-index: 30;
	pointer-events: none;
}
.stowly-pending-cta__inner {
	pointer-events: auto;
	display: flex;
	align-items: center;
	gap: 14px;
	padding: 12px 16px;
	background: linear-gradient(135deg, #fff7e0 0%, var(--stowly-color-primary-soft) 100%);
	border: 1px solid #f1c98a;
	border-radius: var(--stowly-radius-md);
	box-shadow: 0 12px 28px rgba(184, 110, 0, 0.18), 0 2px 6px rgba(15, 23, 42, 0.05);
	max-width: 720px;
	margin: 0 auto;
}
.stowly-pending-cta__body {
	display: flex;
	flex-direction: column;
	gap: 2px;
	flex: 1 1 auto;
	min-width: 0;
}
.stowly-pending-cta__body strong {
	font-size: 14px;
	color: var(--stowly-color-ink);
	font-weight: 700;
}
.stowly-pending-cta__body span {
	font-size: 13px;
	color: var(--stowly-color-ink-soft);
	line-height: 1.35;
}
.stowly-pending-cta .stowly-btn {
	flex-shrink: 0;
}

@media (max-width: 720px) {
	.stowly-pending-cta {
		position: fixed;
		left: 12px;
		right: 12px;
		bottom: 12px;
		margin: 0;
	}
	.stowly-pending-cta__inner {
		padding: 10px 14px;
		gap: 10px;
	}
	.stowly-pending-cta__body strong {
		font-size: 13px;
	}
	.stowly-pending-cta__body span {
		font-size: 12px;
	}
	/* Skub bunden af dashboardet op så CTA'en ikke skjuler indholdet
	 * når man scroller helt ned. */
	body:has(.stowly-pending-cta) .stowly-account {
		padding-bottom: 96px;
	}
}

/* ============================================================
   Inline cancel-booking form (customer + provider dashboards)
   Uses <details>/<summary> so the form can live inside a table
   cell without opening a modal. Summary is styled as a button.
   ============================================================ */
.stowly-cancel-inline {
	display: block;
}

.stowly-cancel-inline > summary {
	list-style: none;
	cursor: pointer;
}

.stowly-cancel-inline > summary::-webkit-details-marker {
	display: none;
}

.stowly-cancel-inline[open] > summary {
	margin-bottom: 10px;
}

.stowly-cancel-inline__form {
	display: flex;
	flex-direction: column;
	gap: 10px;
	padding: 14px;
	background: var(--stowly-color-surface-soft, #faf9f6);
	border: 1px solid var(--stowly-color-line, #e5e7eb);
	border-radius: 12px;
	min-width: 260px;
}

.stowly-cancel-inline__preview {
	margin: 0;
	padding: 10px 12px;
	border-radius: 10px;
	background: #fff;
	border: 1px solid var(--stowly-color-line, #e5e7eb);
	font-size: 13px;
	color: var(--stowly-color-ink);
	line-height: 1.5;
}

.stowly-cancel-inline__note {
	display: flex;
	flex-direction: column;
	gap: 4px;
	font-size: 13px;
}

.stowly-cancel-inline__note > span {
	font-weight: 600;
	color: var(--stowly-color-ink);
}

.stowly-cancel-inline__note textarea {
	padding: 9px 11px;
	border: 1px solid var(--stowly-color-line, #e5e7eb);
	border-radius: 10px;
	background: #fff;
	font: inherit;
	font-size: 13px;
	line-height: 1.5;
	resize: vertical;
	min-height: 56px;
}

.stowly-extend-inline__date input[type="date"] {
	width: 100%;
	max-width: 220px;
	padding: 8px 10px;
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-md);
	font-family: inherit;
	font-size: 14px;
}

.stowly-extend-inline__current {
	margin: 0 0 10px;
	font-size: 13px;
	color: var(--stowly-color-ink-soft);
}

.stowly-cancel-inline__note textarea:focus {
	outline: 0;
	border-color: var(--stowly-color-primary);
	box-shadow: 0 0 0 3px color-mix(in srgb, var(--stowly-color-primary) 15%, transparent);
}

/* Saved searches styles live in dashboards-core.css (loaded on min-konto). */

/* ============================================================
   Payment status pills in the bookings table.
   ============================================================ */
.stowly-pay-pill {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 4px 10px;
	border-radius: 999px;
	font-size: 12.5px;
	font-weight: 600;
	line-height: 1;
	white-space: nowrap;
}

.stowly-pay-pill--paid {
	background: #e6f6ef;
	color: #1f8a70;
}

.stowly-pay-pill--pending {
	background: #fff4ec;
	color: #7a3e00;
}

.stowly-pay-pill--urgent {
	background: #ffe4e4;
	color: #b31212;
	animation: stowlyPulse 2.2s ease-in-out infinite;
}

.stowly-pay-pill--expired {
	background: #f1f1f1;
	color: #666;
}

.stowly-pay-deadline {
	display: inline-block;
	margin-top: 4px;
	color: var(--stowly-color-ink-soft, #64748b);
	font-size: 11.5px;
}

@keyframes stowlyPulse {
	0%, 100% { transform: scale(1); }
	50% { transform: scale(1.04); }
}

/* ============================================================
   Customer bookings — card list (erstatter tabellen på /min-konto/)
   ============================================================ */
.stowly-booking-cards {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 14px;
}

.stowly-booking-card {
	margin: 0;
}

.stowly-booking-card__inner {
	border: 1px solid var(--stowly-color-line);
	border-radius: var(--stowly-radius-lg, 16px);
	background: var(--stowly-color-surface, #fff);
	box-shadow: var(--stowly-shadow-xs, 0 1px 2px rgba(0, 0, 0, 0.04));
	transition: border-color 160ms ease, box-shadow 160ms ease;
}

.stowly-booking-card__inner:hover {
	border-color: var(--stowly-color-line-strong, #ddd);
	box-shadow: var(--stowly-shadow-sm, 0 2px 8px rgba(0, 0, 0, 0.06));
}

.stowly-booking-card__body {
	display: flex;
	align-items: flex-start;
	gap: 18px;
	padding: 18px;
}

/* Depot-thumbnail */
.stowly-booking-card__media {
	flex: 0 0 auto;
	width: 92px;
	height: 92px;
	border-radius: var(--stowly-radius-md, 12px);
	overflow: hidden;
	background: var(--stowly-color-surface-muted, #f2f2f2);
	display: flex;
	align-items: center;
	justify-content: center;
	text-decoration: none;
}

.stowly-booking-card__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.stowly-booking-card__media-fallback {
	color: var(--stowly-color-ink-muted, #9a9a9a);
	display: inline-flex;
}

.stowly-booking-card__content {
	flex: 1 1 auto;
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 14px;
}

.stowly-booking-card__top {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 12px 16px;
}

.stowly-booking-card__intro {
	min-width: 0;
	flex: 1 1 auto;
}

.stowly-booking-card__title {
	margin: 0;
	font-family: var(--stowly-font-heading);
	font-size: 1.0625rem;
	font-weight: 700;
	letter-spacing: -0.02em;
	line-height: 1.3;
	color: var(--stowly-color-ink);
}

.stowly-booking-card__title a {
	color: inherit;
	text-decoration: none;
}

.stowly-booking-card__title a:hover,
.stowly-booking-card__title a:focus-visible {
	color: var(--stowly-color-primary);
}

.stowly-booking-card__location {
	margin: 4px 0 0;
	font-size: 13px;
	line-height: 1.45;
	color: var(--stowly-color-ink-soft);
}

.stowly-booking-card__tel {
	color: var(--stowly-color-primary);
	font-weight: 600;
	text-decoration: none;
}

.stowly-booking-card__tel:hover,
.stowly-booking-card__tel:focus-visible {
	text-decoration: underline;
}

.stowly-booking-card__badges {
	display: flex;
	flex-wrap: wrap;
	justify-content: flex-end;
	align-items: center;
	gap: 6px;
	flex: 0 0 auto;
	max-width: min(100%, 220px);
}

.stowly-booking-card__status-note {
	display: block;
	width: 100%;
	margin-top: 2px;
	font-size: 12px;
	line-height: 1.35;
	color: var(--stowly-color-ink-soft);
	text-align: right;
}

/* Periode / beløb / kontakt — kompakt fakta-stribe */
.stowly-booking-card__facts {
	display: flex;
	flex-wrap: wrap;
	gap: 8px 28px;
	margin: 0;
	padding: 12px 0 0;
	border-top: 1px solid var(--stowly-color-line);
}

.stowly-booking-card__fact {
	margin: 0;
	min-width: 0;
}

.stowly-booking-card__facts dt {
	margin: 0 0 3px;
	font-size: 10.5px;
	font-weight: 700;
	letter-spacing: 0.07em;
	text-transform: uppercase;
	color: var(--stowly-color-ink-muted);
}

.stowly-booking-card__facts dd {
	margin: 0;
	font-size: 14.5px;
	font-weight: 600;
	line-height: 1.35;
	color: var(--stowly-color-ink);
	font-variant-numeric: tabular-nums;
}

.stowly-booking-card__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: flex-start;
	gap: 8px;
	margin: 0;
	padding: 0;
	position: relative;
}

.stowly-booking-card__actions > .stowly-btn,
.stowly-booking-card__actions > .stowly-inline-form,
.stowly-booking-card__actions > details {
	flex: 0 0 auto;
}

.stowly-booking-card__actions .stowly-inline-form {
	margin: 0;
	display: inline-flex;
}

.stowly-booking-card__actions .stowly-cancel-inline,
.stowly-booking-card__actions .stowly-extend-inline {
	display: inline-flex;
	position: relative;
}

.stowly-booking-card__actions details[open] .stowly-cancel-inline__form,
.stowly-booking-card__actions details[open] .stowly-extend-inline__form {
	position: absolute;
	left: 0;
	bottom: calc(100% + 8px);
	z-index: 40;
	margin: 0;
	min-width: 280px;
	max-width: min(360px, calc(100vw - 40px));
	box-shadow: var(--stowly-shadow-lg, 0 12px 30px rgba(0, 0, 0, 0.12));
}

/* Support / "Rapportér problem" — stille footer, ingen tung boks */
.stowly-booking-card__support {
	border-top: 1px solid var(--stowly-color-line);
}

.stowly-booking-card__support .stowly-dispute-widget {
	margin: 0;
	border: 0;
	border-radius: 0;
	background: transparent;
	box-shadow: none;
}

.stowly-booking-card__support .stowly-dispute-widget__head {
	padding: 14px 18px 0;
}

.stowly-booking-card__support .stowly-dispute-widget__head h3 {
	font-size: 13.5px;
	font-weight: 600;
	gap: 8px;
}

.stowly-booking-card__support .stowly-dispute-widget__head h3 .stowly-icon {
	width: 16px;
	height: 16px;
}

.stowly-booking-card__support .stowly-dispute-widget__head > p,
.stowly-booking-card__support .stowly-dispute-widget__head .stowly-dispute-widget__policy {
	display: none;
}

.stowly-booking-card__support .stowly-dispute-widget__toggle {
	margin: 10px 18px 16px;
}

.stowly-booking-card__support .stowly-dispute-widget__toggle summary {
	padding: 7px 14px;
	font-size: 12.5px;
}

.stowly-booking-card__support .stowly-dispute-widget__case {
	margin: 12px 18px 16px;
}

@media (max-width: 640px) {
	.stowly-booking-card__body {
		flex-direction: column;
		gap: 14px;
		padding: 16px;
	}

	.stowly-booking-card__media {
		width: 100%;
		height: 150px;
	}

	.stowly-booking-card__top {
		flex-direction: column;
		align-items: stretch;
	}

	.stowly-booking-card__badges {
		justify-content: flex-start;
		max-width: none;
	}

	.stowly-booking-card__status-note {
		text-align: left;
	}

	.stowly-booking-card__actions details[open] .stowly-cancel-inline__form,
	.stowly-booking-card__actions details[open] .stowly-extend-inline__form {
		position: static;
		margin-top: 8px;
		width: 100%;
		max-width: none;
	}
}

/* Legacy table styles — provider + ældre markup */
.stowly-bookings-table--customer {
	width: 100%;
	table-layout: auto;
}

.stowly-booking-listing-contact {
	display: flex;
	flex-direction: column;
	gap: 4px;
	margin-top: 8px;
	font-size: 13px;
	line-height: 1.45;
	color: var(--stowly-color-ink-soft, #5c5c5c);
	max-width: min(36ch, 100%);
}

.stowly-booking-listing-contact__addr {
	white-space: pre-wrap;
}

.stowly-booking-listing-contact__tel {
	color: var(--stowly-color-primary);
	font-weight: 600;
	text-decoration: none;
}

.stowly-booking-listing-contact__tel:hover,
.stowly-booking-listing-contact__tel:focus-visible {
	text-decoration: underline;
}

.stowly-bookings-table-wrap:has(.stowly-bookings-table--customer) {
	overflow-x: auto;
	overflow-y: visible;
}

/* Fald tilbage til almindelig scroll hvis viewport bliver så smalt
   at selv den komprimerede tabel ikke kan være der (mobil). */
@media (max-width: 720px) {
	.stowly-bookings-table-wrap:has(.stowly-bookings-table--customer) {
		overflow-x: auto;
	}
}

.stowly-bookings-table--customer th,
.stowly-bookings-table--customer td {
	padding: 12px 12px;
}

.stowly-bookings-table--customer .stowly-bookings-table__period {
	white-space: nowrap;
	font-variant-numeric: tabular-nums;
	line-height: 1.35;
}
.stowly-bookings-table--customer .stowly-bookings-table__period .stowly-booking-period__date {
	display: block;
}

.stowly-bookings-table--customer .stowly-bookings-table__amount {
	white-space: nowrap;
	font-variant-numeric: tabular-nums;
}

.stowly-bookings-table--customer .stowly-bookings-table__status-cell {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 6px;
	min-width: 120px;
	max-width: none;
}

.stowly-bookings-table--customer .stowly-bookings-table__status-cell .stowly-pay-deadline {
	display: block;
	margin-top: 0;
	line-height: 1.35;
	font-size: 12px;
	color: var(--stowly-color-ink-soft, #64748b);
}

.stowly-bookings-table--customer .stowly-bookings-table__actions-col {
	width: 1%;
	white-space: nowrap;
}

/* Handling-cellen sidder yderst til højre i booking-rækken og
   indeholder alle action-knapper inline på samme linje som resten
   af booking-infoen. Knapperne wrapper naturligt hvis rækken bliver
   for smal (fx når både "Betal nu", "Besked", "Annuller" osv. er
   aktive samtidig). */
.stowly-bookings-table--customer .stowly-bookings-table__actions-td {
	vertical-align: middle;
	text-align: right;
	white-space: normal;
	width: auto;
	min-width: 0;
	overflow: visible;
}

.stowly-bookings-table--customer .stowly-bookings-table__actions-td .stowly-actions-stack {
	display: flex;
	flex-direction: row;
	flex-wrap: wrap;
	justify-content: flex-end;
	align-items: center;
	gap: 6px;
	min-width: 0;
	max-width: 100%;
}

.stowly-bookings-table--customer .stowly-bookings-table__actions-td .stowly-actions-stack > *,
.stowly-bookings-table--customer .stowly-bookings-table__actions-td .stowly-actions-stack .stowly-inline-form {
	flex: 0 0 auto;
}

.stowly-bookings-table--customer .stowly-bookings-table__actions-td .stowly-actions-stack > .stowly-btn,
.stowly-bookings-table--customer .stowly-bookings-table__actions-td .stowly-actions-stack .stowly-inline-form > .stowly-btn,
.stowly-bookings-table--customer .stowly-bookings-table__actions-td .stowly-actions-stack details > summary.stowly-btn {
	width: auto;
	min-height: 34px;
	padding: 0 12px;
	font-size: 12.5px;
	line-height: 1;
	white-space: nowrap;
}

/* <details> er block som standard — det skubber "Forlæng" på egen linje. */
.stowly-bookings-table--customer .stowly-bookings-table__actions-td .stowly-actions-stack .stowly-cancel-inline,
.stowly-bookings-table--customer .stowly-bookings-table__actions-td .stowly-actions-stack .stowly-extend-inline {
	display: inline-flex;
	flex: 0 0 auto;
	position: relative;
	vertical-align: middle;
}

.stowly-bookings-table--customer .stowly-bookings-table__actions-td .stowly-actions-stack details[open] .stowly-cancel-inline__form,
.stowly-bookings-table--customer .stowly-bookings-table__actions-td .stowly-actions-stack details[open] .stowly-extend-inline__form {
	position: absolute;
	right: 0;
	top: calc(100% + 6px);
	z-index: 40;
	margin: 0;
	box-shadow: 0 12px 32px rgba(15, 15, 15, 0.12);
}

.stowly-bookings-table--customer .stowly-bookings-table__actions-td .stowly-actions-stack .stowly-inline-form {
	display: inline-flex;
	margin: 0;
}

.stowly-bookings-table--customer tbody td {
	vertical-align: middle;
}

/* Mobil: behold knapper på samme rækde (wrap til næste linje ved behov)
   i stedet for lodret stak — ellers bliver rækkerne unødigt høje og
   overlapper ikke brugerens ønske om én linje (Besked + Kvittering). */
@media (max-width: 720px) {
	.stowly-bookings-table--customer .stowly-bookings-table__actions-td {
		white-space: normal;
	}
	.stowly-bookings-table--customer .stowly-bookings-table__actions-td .stowly-actions-stack {
		flex-direction: row;
		flex-wrap: wrap;
		align-items: center;
		justify-content: flex-end;
		gap: 8px;
	}
	.stowly-bookings-table--customer .stowly-bookings-table__actions-td .stowly-actions-stack > .stowly-btn,
	.stowly-bookings-table--customer .stowly-bookings-table__actions-td .stowly-actions-stack .stowly-inline-form > .stowly-btn {
		width: auto;
		justify-content: center;
	}
	.stowly-bookings-table--customer .stowly-bookings-table__actions-td .stowly-actions-stack .stowly-inline-form {
		display: inline-flex;
		margin: 0;
	}
}

/* ============================================================
   Eksterne annoncer — udbydere foldet sammen (admin-fane)
   ============================================================ */
.stowly-external-listings__providers {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.stowly-external-listings__provider {
	border: 1px solid var(--stowly-color-line, #e9e6e4);
	border-radius: 12px;
	background: var(--stowly-color-surface, #fff);
	overflow: hidden;
}

.stowly-external-listings__provider-summary {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	padding: 14px 18px;
	cursor: pointer;
	list-style: none;
	font-weight: 600;
	color: var(--stowly-color-ink, #1a1a1a);
	user-select: none;
}

.stowly-external-listings__provider-summary::-webkit-details-marker {
	display: none;
}

.stowly-external-listings__provider-summary::after {
	content: "";
	width: 9px;
	height: 9px;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg);
	margin-left: auto;
	transition: transform 0.18s ease;
	flex: 0 0 auto;
	opacity: 0.55;
}

.stowly-external-listings__provider[open] .stowly-external-listings__provider-summary::after {
	transform: rotate(-135deg);
}

.stowly-external-listings__provider-summary:hover {
	background: var(--stowly-color-surface-muted, #f6f4f2);
}

.stowly-external-listings__provider-name {
	font-size: 1.02rem;
}

.stowly-external-listings__provider-count {
	margin-left: auto;
	font-size: 0.85rem;
	font-weight: 500;
	color: var(--stowly-color-ink-soft, #6b6660);
	white-space: nowrap;
}

.stowly-external-listings__provider .stowly-bookings-table-wrap {
	margin: 0;
	border: 0;
	border-top: 1px solid var(--stowly-color-line, #e9e6e4);
	border-radius: 0;
}

