/**
 * AI Marketing Expert — WP Dashboard Widget Styles
 *
 * @package WPSpace\AiMarketingExpert
 */

/* ── Base ───────────────────────────────────────────── */

.aime-dw {
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
	line-height: 1.5;
}

.aime-dw * {
	box-sizing: border-box;
}

/* ── Section ────────────────────────────────────────── */

.aime-dw__section {
	padding: 16px 0;
	border-bottom: 1px solid #f0f0f1;
}

.aime-dw__section:first-child {
	padding-top: 0;
}

.aime-dw__section:last-of-type {
	border-bottom: none;
	padding-bottom: 0;
}

.aime-dw__section-header {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 12px;
}

.aime-dw__icon {
	font-size: 18px;
	line-height: 1;
	flex-shrink: 0;
}

.aime-dw__title {
	font-size: 13px;
	font-weight: 600;
	color: #1d2327;
}

/* ── Live badge ─────────────────────────────────────── */

.aime-dw__live-badge {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	margin-left: auto;
	padding: 2px 8px;
	font-size: 11px;
	font-weight: 600;
	color: #2E7D32;
	background: rgba(46, 125, 50, 0.08);
	border: 1px solid rgba(46, 125, 50, 0.2);
	border-radius: 12px;
	line-height: 1.4;
}

.aime-dw__live-dot {
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: #22c55e;
	animation: aime-dw-pulse 2s ease-in-out infinite;
}

@keyframes aime-dw-pulse {
	0%, 100% { opacity: 1; }
	50% { opacity: 0.4; }
}

/* ── Stat cards (3-column row) ──────────────────────── */

.aime-dw__cards {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 8px;
	margin-bottom: 12px;
}

.aime-dw__card {
	display: flex;
	flex-direction: column;
	padding: 10px 12px;
	background: #f6f7f7;
	border-radius: 6px;
	text-align: center;
}

.aime-dw__card-value {
	font-size: 22px;
	font-weight: 700;
	color: #1d2327;
	line-height: 1.2;
}

.aime-dw__card-value--small {
	font-size: 16px;
}

/* ── Section color accents ──────────────────────────── */

.aime-dw__section--chatbot .aime-dw__card {
	background: rgba(46, 125, 50, 0.06);
}
.aime-dw__section--chatbot .aime-dw__card-value {
	color: #2E7D32;
}

.aime-dw__section--automation .aime-dw__card {
	background: rgba(27, 94, 32, 0.06);
}
.aime-dw__section--automation .aime-dw__card-value {
	color: #1B5E20;
}

.aime-dw__section--email .aime-dw__card {
	background: rgba(21, 101, 192, 0.06);
}
.aime-dw__section--email .aime-dw__card-value {
	color: #1565C0;
}

.aime-dw__card-limit {
	font-size: 13px;
	font-weight: 400;
	color: #996800;
}

.aime-dw__card-unit {
	font-size: 13px;
	font-weight: 400;
	color: #646970;
}

.aime-dw__card-label {
	font-size: 11px;
	font-weight: 500;
	color: #646970;
	margin-top: 2px;
}

.aime-dw__section--seo .aime-dw__compact-stat strong {
	color: #475569;
}

.aime-dw__section--content .aime-dw__compact-stat strong {
	color: #B45309;
}

.aime-dw__section--social .aime-dw__compact-stat strong {
	color: #D85929;
}

/* ── Activity feed (chatbot) ────────────────────────── */

.aime-dw__feed {
	margin-bottom: 12px;
}

.aime-dw__feed-item {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 6px 0;
	border-bottom: 1px solid #f0f0f1;
	font-size: 12px;
	color: #50575e;
}

.aime-dw__feed-item:last-child {
	border-bottom: none;
}

.aime-dw__feed-item--attention {
	background: #fcf0f1;
	margin: 0 -8px;
	padding: 6px 8px;
	border-radius: 4px;
}

.aime-dw__feed-dot {
	width: 6px;
	height: 6px;
	border-radius: 50%;
	flex-shrink: 0;
}

.aime-dw__feed-dot--green {
	background: #22c55e;
}

.aime-dw__feed-dot--orange {
	background: #f59e0b;
}

.aime-dw__feed-name {
	font-weight: 600;
	color: #1d2327;
	flex-shrink: 0;
}

.aime-dw__feed-page {
	color: #996800;
	flex-shrink: 0;
	max-width: 120px;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.aime-dw__feed-meta {
	margin-left: auto;
	color: #646970;
	flex-shrink: 0;
}

.aime-dw__feed-time {
	color: #996800;
	flex-shrink: 0;
	font-size: 11px;
}

/* ── Section footer link ────────────────────────────── */

.aime-dw__section-footer {
	margin-top: 4px;
}

.aime-dw__link {
	font-size: 12px;
	font-weight: 500;
	color: #2271b1;
	text-decoration: none;
	display: inline-flex;
	align-items: center;
	gap: 4px;
}

.aime-dw__link:hover {
	color: #135e96;
	text-decoration: underline;
}

.aime-dw__link--inline {
	margin-left: auto;
}

/* ── Compact rows (SEO, Content, Social) ────────────── */

.aime-dw__section--compact .aime-dw__section-header {
	margin-bottom: 6px;
}

.aime-dw__compact-stats {
	display: flex;
	gap: 16px;
	flex-wrap: wrap;
}

.aime-dw__compact-stat {
	font-size: 12px;
	color: #646970;
}

.aime-dw__compact-stat strong {
	font-weight: 700;
	color: #1d2327;
	margin-right: 3px;
}

/* ── Widget footer ──────────────────────────────────── */

.aime-dw__footer {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-top: 12px;
	padding-top: 10px;
	border-top: 1px solid #f0f0f1;
}

.aime-dw__updated {
	font-size: 11px;
	color: #996800;
}

.aime-dw__refresh {
	background: none;
	border: none;
	cursor: pointer;
	padding: 4px;
	color: #646970;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: color 0.15s ease;
}

.aime-dw__refresh:hover {
	color: #2271b1;
}

.aime-dw__refresh .dashicons {
	font-size: 18px;
	width: 18px;
	height: 18px;
	line-height: 18px;
}

.aime-dw__refresh--spin .dashicons {
	animation: aime-dw-spin 0.8s linear infinite;
}

@keyframes aime-dw-spin {
	from { transform: rotate(0deg); }
	to { transform: rotate(360deg); }
}


