.aipa-widget, .aipa-widget * { box-sizing: border-box; }
.aipa-trigger {
	position: fixed; right: 28px; bottom: 28px; z-index: 99990;
	width: 130px;
	height: 62px;
	border: 0;
	border-radius: 31px;
	background: #111827;
	color: #fff;
	font: 700 18px/1 sans-serif;
	box-shadow: 0 10px 30px rgba(0,0,0,.22);
	cursor: pointer;
	transition: transform .2s ease, box-shadow .2s ease;
}
.aipa-trigger:hover,
.aipa-trigger:focus-visible {
	transform: translateY(-5px);
	box-shadow: 0 14px 34px rgba(0,0,0,.28);
	background: #222837;
}
.aipa-backdrop { position: fixed; inset: 0; z-index: 99991; background: rgba(15,23,42,.34); }
.aipa-panel {
	position: fixed; right: 28px; bottom: 104px; z-index: 99992;
	width: min(430px, calc(100vw - 32px)); max-height: calc(100vh - 132px); overflow-y: auto;
	background: #fff; color: #111827; border-radius: 18px; padding: 28px;
	box-shadow: 0 24px 70px rgba(0,0,0,.28); font-family: inherit;
}
.aipa-panel[hidden], .aipa-backdrop[hidden] { display: none !important; }
.aipa-panel h2 { margin: 0 32px 8px 0; font-size: 25px; line-height: 1.2; }
.aipa-panel p { margin: 0 0 22px; color: #4b5563; line-height: 1.55; }
.aipa-close { position: absolute; top: 13px; right: 14px; width: 38px; height: 38px; border: 0; background: transparent; color: #374151; font-size: 30px; cursor: pointer; }
.aipa-field { margin-bottom: 14px; }
.aipa-field label { display: block; margin-bottom: 6px; font-weight: 600; font-size: 14px; }
.aipa-field input { width: 100%; height: 44px; border: 1px solid #d1d5db; border-radius: 9px; padding: 0 12px; font: inherit; background: #fff; color: #111827; }
.aipa-field input:focus {
	outline: none;
	border-color: #111827;
	box-shadow: none;
	background: #e7e143;
}
.aipa-honeypot { position: absolute !important; left: -10000px !important; width: 1px !important; height: 1px !important; overflow: hidden !important; }
.aipa-privacy { display: flex; align-items: flex-start; gap: 9px; margin: 17px 0; font-size: 13px; line-height: 1.45; color: #4b5563; }
.aipa-privacy input { margin-top: 3px; flex: 0 0 auto; }
.aipa-message { margin: 0 0 14px; border-radius: 8px; padding: 10px 12px; background: #fef2f2; color: #991b1b; font-size: 14px; }
.aipa-submit,
.aipa-contact {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 48px;
	border: 0;
	padding: 0 18px;
	background: #e7e143;
	color: #000 !important;
	font: 700 15px/1.2 inherit;
	text-decoration: none !important;
	cursor: pointer;
}
.aipa-submit { width: 100%; }
.aipa-submit:disabled { opacity: .7; cursor: wait; }
.aipa-spinner { display: none; width: 17px; height: 17px; margin-left: 10px; border: 2px solid rgba(255,255,255,.4); border-top-color: #fff; border-radius: 50%; animation: aipa-spin .7s linear infinite; }
.aipa-submit.is-loading .aipa-spinner { display: inline-block; }
.aipa-success { text-align: center; padding: 22px 0 8px; }
.aipa-success[hidden], #aipa-form-view[hidden] { display: none !important; }
@keyframes aipa-spin { to { transform: rotate(360deg); } }
@media (max-width: 600px) {
	.aipa-trigger { right: 18px; bottom: 18px; }
	.aipa-panel { right: 0; bottom: 0; width: 100%; max-height: 92vh; border-radius: 18px 18px 0 0; padding: 24px 20px; }
	.aipa-backdrop { background: rgba(15,23,42,.48); }
}
.aipa-crawl-summary { margin: -8px 0 22px; padding: 10px 12px; border-radius: 8px; background: #f3f4f6; color: #374151; font-size: 13px; }

.aipa-analysis { text-align: left; }
.aipa-analysis h2 { margin: 0 0 12px; }
.aipa-analysis h3 { margin: 20px 0 6px; font-size: 1rem; }
.aipa-analysis p { margin: 0 0 10px; line-height: 1.55; }
.aipa-analysis ul,
.aipa-analysis ol { margin: 8px 0 14px 20px; padding: 0; }
.aipa-analysis li { margin-bottom: 8px; line-height: 1.45; }
.aipa-analysis-score { font-size: 1.4rem; }
.aipa-analysis-company { margin-bottom: 18px !important; }
#aipa-analysis-result { max-height: min(68vh, 700px); overflow-y: auto; padding-right: 8px; }
.aipa-status-view { padding: 24px 0; text-align: center; }

.aipa-loader {
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 8px;
	margin: 20px 0 20px;
}

.aipa-loader span {
	width: 12px;
	height: 12px;
	background: #d1d5db;
	animation: aipa-loader 1s infinite ease-in-out;
}

.aipa-loader span:nth-child(1) { animation-delay: 0s; }
.aipa-loader span:nth-child(2) { animation-delay: .12s; }
.aipa-loader span:nth-child(3) { animation-delay: .24s; }
.aipa-loader span:nth-child(4) { animation-delay: .36s; }
.aipa-loader span:nth-child(5) { animation-delay: .48s; }

@keyframes aipa-loader {
	0%,
	100% {
		background: #d1d5db;
		transform: scale(1);
		opacity: .35;
	}
	50% {
		background: #e7e143;
		transform: scale(1.15);
		opacity: 1;
	}
}
