/* TFFC WMS — marker overlay + (?) helper. Loaded only on WMS admin surfaces. */

.wms-help-toggle{
	display:inline-flex;align-items:center;justify-content:center;
	width:22px;height:22px;margin-left:.4em;padding:0;
	border:1px solid #2271b1;border-radius:50%;
	background:#fff;color:#2271b1;font-weight:700;font-size:13px;line-height:1;
	cursor:pointer;vertical-align:middle;
}
.wms-help-toggle:hover{background:#2271b1;color:#fff}
body.wms-annotating .wms-help-toggle{background:#d63638;border-color:#d63638;color:#fff}

/* Badges — hidden until annotate mode is on. */
.wms-badge{
	display:none;
	margin-left:6px;padding:1px 5px;
	font:600 11px/1.4 ui-monospace,SFMono-Regular,Menlo,monospace;
	color:#1d2327;background:#f0e68c;border:1px solid #c9b458;border-radius:4px;
	cursor:pointer;vertical-align:middle;user-select:all;white-space:nowrap;
}
.wms-badge[data-wms-type="function"]{background:#d5e8ff;border-color:#8ab4e8}
.wms-badge[data-wms-type="code"]{background:#e6d9ff;border-color:#b79ce8}
.wms-badge[data-wms-type="screen"]{background:#ffd9d9;border-color:#e88a8a}
.wms-badge[data-wms-type="value"]{background:#d9f2df;border-color:#8ad0a0}
.wms-badge:hover{outline:2px solid #d63638}
body.wms-annotating .wms-badge{display:inline-block}

/* The annotate panel. THEME-PROOF: this overlay also loads on the front-end CBX shell (a shortcode on a themed WP
 * page), where the theme bleeds into any element we don't explicitly colour — and the panel's Send/Close use the
 * wp-admin `.button` classes, which the front end doesn't style. So every panel control sets its OWN colours (a few
 * !important to beat theme specificity), mirroring the shell's host-theme reset. Without this the popup is invisible. */
.wms-panel, .wms-panel *{
	box-sizing:border-box;
	font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;
	letter-spacing:normal;text-transform:none;text-shadow:none;
}
.wms-panel{
	display:none;position:fixed;right:20px;bottom:20px;z-index:99999;
	width:360px;max-width:calc(100vw - 40px);
	background:#fff !important;color:#1d2327 !important;border:1px solid #c3c4c7;border-radius:8px;
	box-shadow:0 6px 24px rgba(0,0,0,.18);padding:14px 16px;line-height:1.4;
}
body.wms-annotating .wms-panel{display:block}
.wms-panel h3{margin:0 0 .5em;font-size:14px;font-weight:700;color:#1d2327 !important}
.wms-panel p.desc{margin:.2em 0 .6em;color:#646970 !important;font-size:12px}
.wms-panel textarea{
	width:100%;min-height:96px;font-size:13px;padding:8px;border-radius:6px;
	color:#1d2327 !important;-webkit-text-fill-color:#1d2327;
	background:#fff !important;border:1px solid #c3c4c7 !important;
}
.wms-panel textarea::placeholder{color:#8c8f94;-webkit-text-fill-color:#8c8f94;opacity:1}
.wms-panel .wms-actions{display:flex;gap:8px;align-items:center;margin-top:.6em}
/* Send/Close carry wp-admin `.button`/`.button-primary` classes → style them here so they survive off wp-admin. */
.wms-panel .wms-actions button{
	font:600 13px/1 -apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;
	cursor:pointer;border-radius:6px;padding:7px 14px;height:auto;min-height:0;
	border:1px solid #c3c4c7 !important;background:#f6f7f7 !important;color:#1d2327 !important;
	text-shadow:none;box-shadow:none;
}
.wms-panel .wms-actions button.button-primary{background:#2271b1 !important;border-color:#2271b1 !important;color:#fff !important}
.wms-panel .wms-actions button:hover{filter:brightness(.97)}
.wms-panel .wms-msg{font-size:12px;margin-left:auto}
.wms-panel .wms-msg.ok{color:#008a20 !important}
.wms-panel .wms-msg.err{color:#d63638 !important}
