/* WM Offer Analysis — icon + modal styling. */

/* Higher-specificity selectors so the theme's generic button/link
   hover rules (which set color:#fff on a lot of CTAs) don't bleed in.
   color: #1a0dab is repeated on every interactive state and on the
   inner label + svg, since the theme also restyles SVG fill on hover. */
button.wmoa-analyse-btn,
.wmoa-analyse-btn {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	background: transparent;
	border: 1px solid #c7d2fe;
	color: #1a0dab !important;
	font-size: 12px;
	line-height: 1;
	padding: 4px 8px;
	border-radius: 999px;
	cursor: pointer;
	transition: background 0.12s, color 0.12s, border-color 0.12s;
	font-family: inherit;
	font-weight: 500;
	text-decoration: none;
}
.wmoa-analyse-btn:hover,
.wmoa-analyse-btn:focus,
.wmoa-analyse-btn:focus-visible,
.wmoa-analyse-btn:active {
	background: #eef2ff !important;
	border-color: #1a0dab !important;
	color: #1a0dab !important;
	outline: none;
	text-decoration: none;
}
.wmoa-analyse-btn svg {
	display: block;
	stroke: currentColor;
	color: #1a0dab;
}
.wmoa-analyse-btn:hover svg,
.wmoa-analyse-btn:focus svg {
	color: #1a0dab;
	stroke: #1a0dab;
}
.wmoa-analyse-btn__label {
	white-space: nowrap;
	color: #1a0dab !important;
}

@media (max-width: 480px) {
	.wmoa-analyse-btn__label { display: none; }
	.wmoa-analyse-btn { padding: 4px; }
}

/* Overlay + modal */
.wmoa-overlay {
	position: fixed;
	inset: 0;
	background: rgba(15, 23, 42, 0.55);
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
	overflow-y: auto;
}
.wmoa-overlay[hidden] { display: none; }
body.wmoa-modal-open { overflow: hidden; }

.wmoa-modal {
	background: #fff;
	width: 100%;
	max-width: 720px;
	max-height: calc(100vh - 32px);
	border-radius: 12px;
	box-shadow: 0 20px 60px rgba(15, 23, 42, 0.3);
	display: flex;
	flex-direction: column;
	overflow: hidden;
	font-family: inherit;
	color: #1f2937;
}

.wmoa-modal__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 14px 20px;
	border-bottom: 1px solid #e5e7eb;
	background: #f9fafb;
}
.wmoa-modal__head h2 {
	margin: 0;
	font-size: 17px;
	line-height: 1.3;
	font-weight: 600;
	color: #111827;
}
.wmoa-modal__close {
	background: transparent;
	border: 0;
	font-size: 24px;
	line-height: 1;
	color: #6b7280;
	cursor: pointer;
	padding: 4px 8px;
}
.wmoa-modal__close:hover { color: #111827; }

.wmoa-modal__body {
	padding: 20px;
	overflow-y: auto;
	flex: 1;
}

.wmoa-modal__foot {
	padding: 10px 20px;
	border-top: 1px solid #e5e7eb;
	background: #f9fafb;
	color: #6b7280;
	font-size: 12px;
}
.wmoa-modal__compliance {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 6px;
}
.wmoa-modal__age {
	display: inline-block;
	background: #ef4444;
	color: #fff;
	border-radius: 999px;
	font-weight: 700;
	font-size: 11px;
	padding: 2px 8px;
	line-height: 1;
	letter-spacing: 0.02em;
}
.wmoa-modal__rg {
	display: inline-flex;
	align-items: center;
}
.wmoa-modal__rg img {
	max-height: 22px;
	width: auto;
	height: auto;
	display: block;
}
.wmoa-modal__rg-msg {
	color: #4b5563;
	font-size: 11.5px;
	line-height: 1.4;
}
.wmoa-modal__rg-msg a {
	color: #1a0dab;
	text-decoration: underline;
}
.wmoa-modal__disclaimer {
	display: block;
	color: #9ca3af;
	font-size: 11px;
	font-style: italic;
}

/* States */
.wmoa-state { font-size: 14px; line-height: 1.55; }
.wmoa-state--loading {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 12px;
	padding: 32px 0;
	color: #6b7280;
}

.wmoa-spinner {
	width: 32px;
	height: 32px;
	border: 3px solid #e5e7eb;
	border-top-color: #1a0dab;
	border-radius: 50%;
	animation: wmoa-spin 0.8s linear infinite;
}
@keyframes wmoa-spin {
	to { transform: rotate(360deg); }
}

/* Result sections */
.wmoa-section {
	border-left: 4px solid #e5e7eb;
	background: #f9fafb;
	border-radius: 6px;
	padding: 12px 14px;
	margin-bottom: 12px;
}
.wmoa-section h3 {
	margin: 0 0 6px;
	font-size: 14px;
	font-weight: 600;
	color: #1f2937;
}
.wmoa-section ul {
	margin: 0;
	padding: 0;
	list-style: none;
}
.wmoa-section li {
	margin: 0;
	padding: 4px 0;
	font-size: 14px;
	line-height: 1.55;
	color: #374151;
}
.wmoa-section li + li {
	border-top: 1px dashed #e5e7eb;
}
.wmoa-section .wmoa-empty {
	color: #9ca3af;
	font-style: italic;
}

.wmoa-section--watch { border-left-color: #f59e0b; background: #fffbeb; }
.wmoa-section--watch h3 { color: #92400e; }

.wmoa-section--pos { border-left-color: #10b981; background: #ecfdf5; }
.wmoa-section--pos h3 { color: #065f46; }

.wmoa-section--con { border-left-color: #ef4444; background: #fef2f2; }
.wmoa-section--con h3 { color: #991b1b; }

.wmoa-result-meta {
	margin-top: 14px;
	padding-top: 10px;
	border-top: 1px solid #e5e7eb;
	font-size: 12px;
	color: #6b7280;
}
.wmoa-result-meta a { color: #1a0dab; }

/* Challenge / rate / error states */
.wmoa-state--challenge { text-align: center; padding: 16px 0; }
.wmoa-turnstile { margin-top: 12px; display: flex; justify-content: center; }

.wmoa-state--rate {
	background: #fef2f2;
	border-left: 4px solid #ef4444;
	padding: 14px 16px;
	border-radius: 6px;
	color: #991b1b;
}

.wmoa-state--error {
	background: #fef2f2;
	border-left: 4px solid #f59e0b;
	padding: 14px 16px;
	border-radius: 6px;
	color: #7c2d12;
}
.wmoa-error-message { margin: 0 0 8px; }
.wmoa-retry-btn {
	background: #1a0dab;
	color: #fff;
	border: 0;
	padding: 6px 14px;
	border-radius: 4px;
	cursor: pointer;
	font-size: 13px;
}
.wmoa-retry-btn:hover { background: #14098c; }
