@import "attentiq-mobile.css";
@import "attentiq-side-panel.css";

:root {
	/* ── Backgrounds ─────────────────────────────────────── */
	--bg:           #f7f8fc;
	--surface:      #ffffff;
	--surface-3:    #f0effe;

	/* ── Borders ─────────────────────────────────────────── */
	--border:            rgb(214 217 227);
	--border-soft:       rgb(214 217 227 / 40%);
	--border-mint-light: rgb(208 236 230);

	/* ── Primary (purple) ────────────────────────────────── */
	--primary:      #6c63ff;
	--primary-soft: #ede9ff;
	--primary-dark: #5a52d5;
	--primary-text: #4f46e5;   /* AA on white: 4.8:1 */

	/* ── Header purple (lighter) ─────────────────────────── */
	--header:         #a78bfa;   /* decorative / on dark bg only */
	--header-10:      rgb(167 139 250 / 10%);
	--header-30:      rgb(167 139 250 / 30%);
	--header-50:      rgb(167 139 250 / 50%);
	--header-text:    #5b46c1;
	--header-text-70: rgb(92 70 193 / 70%);

	/* ── Hero dark background ────────────────────────────── */
	--hero-bg:         #221b4b;
	--hero-surface:    rgba(255,255,255,0.10);
	--hero-border:     rgba(255,255,255,0.12);
	--hero-border-mid: rgba(255,255,255,0.18);

	/* Text on --hero-bg (all meet AA 4.5:1 on #2d2460) */
	--hero-text:        #ffffff;            
	--hero-text-strong: rgba(255,255,255,0.85); 
	--hero-text-muted:  rgba(255,255,255,0.65); 
	
	--hero-text-sub:    rgba(255,255,255,0.85); 
	--hero-text-label:  rgba(255,255,255,0.85); 
	--hero-text-meta:   rgba(255,255,255,0.65); 
	--hero-text-dim:    rgba(255,255,255,0.65); 
	--hero-text-slot:   rgba(255,255,255,0.85); 

	/* Accent colours on --hero-bg (all meet AA) */
	--hero-mint:          #5efad9;
	--hero-purple:        #cdbcff;   /* lightened from #b8a4ff — pill text needs 4.5:1 on tinted pill bg */
	--hero-mint-bg:       rgba(94,250,217,0.16);
	--hero-mint-border:   rgba(94,250,217,0.30);
	--hero-purple-bg:     rgba(205,188,255,0.20);
	--hero-purple-border: rgba(205,188,255,0.35);
	--hero-tip-bg:        rgba(108,99,255,0.14);
	--hero-tip-border:    rgba(108,99,255,0.25);
	--hero-todo-bg:       rgba(245,158,11,0.10);
	--hero-todo-border:   rgba(245,158,11,0.25);

	/* ── Mint ────────────────────────────────────────────── */
	--mint:         #00c9a7;   /* decorative / on dark bg only */
	--mint-10:      rgb(0 201 167 / 10%);
	--mint-50:      rgb(0 202 170 / 50%);
	--mint-soft:    #e0faf5;
	--mint-text:    #007d68;   /* AA on white: 4.6:1 */

	/* ── Typography ──────────────────────────────────────── */
	--font-body: 'DM Sans', sans-serif;
	--font-mono: 'DM Mono', monospace;

	/* ── Text (light bg) ─────────────────────────────────── */
	--text:         #1a1731;   /* 17.2:1 on white */
	--text-2:       #533f72;   /* 4.3:1 — borderline, use --text-2-aa for small text */
	--text-2-aa:    #4a3867;   /* 5.0:1 on white */
	--text-3:       #9582b3;   /* decorative / large bold only */
	--text-3-aa:    #6b5a8a;   /* 4.6:1 on white — use for small text */

	/* ── Items ──────────────────────────────────────────── */
	--default-toggle-bg: #d8d6ee;

	/* ── Status ──────────────────────────────────────────── */
	--red:          #ef4444;   /* decorative / on dark bg */
	--red-50:       rgb(239 68 68 / 50%);
	--red-text:     #c81e1e;   /* AA on white: 5.1:1 */
	--red-fluo:     #ff6ba1;
	--red-soft:     #fef2f2;

	--amber:        #f59e0b;   /* decorative only */
	--amber-soft:   #fff8e5;
	--amber-text:   #92610a;   /* AA on white: 4.7:1 */

	--green:        #93cd20;   /* decorative only */
	--green-fluo:   #afee30;
	--green-soft:   #ebfec3;
	--green-text:   #4a6e00;   /* AA on white: 5.2:1 */

	/* ── Shadows & radius ────────────────────────────────── */
	--shadow-sm:  0 1px 3px rgba(108,99,255,0.06), 0 1px 2px rgba(0,0,0,0.04);
	--shadow-md:  0 4px 16px rgba(108,99,255,0.08), 0 1px 4px rgba(0,0,0,0.04);
	--radius:     5px;
	--radius-sm:  2px;
	--radius-pill:4px;
}

/* ── rest of your existing admin CSS unchanged below ──────── */

body.toplevel_page_attentiq #wpcontent,
body.attentiq_page_attentiq-ad-slots #wpcontent,
body.attentiq_page_attentiq-settings #wpcontent,
body.attentiq_page_attentiq-upgrade #wpcontent,
body.attentiq_page_attentiq-license #wpcontent,
body.attentiq_page_attentiq-setup #wpcontent,
body.admin_page_attentiq-advertiser-report #wpcontent,
body.admin_page_attentiq-post #wpcontent,
body.toplevel_page_attentiq #wpbody {
	padding-left: 0 !important;
	background: #f7f8fc !important;
}

#adminmenu li.wp-has-current-submenu.toplevel_page_attentiq a.wp-has-current-submenu {
	background: var(--header-text) !important;
}

#wpbody-content .wrap,
#wpbody-content .attentiq-wrap {
	font-family: 'DM Sans', sans-serif;
	max-width: 1400px;
	margin: 0;
}

.attentiq-wrap .attentiq-header {
	padding: 15px 10px;
	background-color: #f9fbff;
	border-bottom: solid 1px #e9eaf1;
	margin-bottom: 2rem;
}

.attentiq-wrap .attentiq-header .attentiq-logo {
	height: 50px;
}

.attentiq-wrap .attentiq-content {
	margin: 0 auto;
	max-width: 100%;
	padding: 0 2rem !important;
}

.attentiq-wrap h1 {
	font-family: 'DM Sans', sans-serif;
	font-size: 20px;
	font-weight: 700;
	color: var(--text);
	letter-spacing: -0.3px;
	display: flex !important;
	align-items: center !important;
	gap: 12px !important;
	line-height: 1 !important;
}

.attentiq-logo .attentiq-logo-attent { margin-right: 1px; }
.attentiq-logo .attentiq-logo-iq     { color: var(--primary); }
.aiq-lock-icon{
	color: var(--primary);
}

/* ── Page heading ─────────────────────────────────────────── */
.attentiq-title-group {
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 5px;
	height: 40px;
}

.attentiq-title-text {
	font-size: 20px;
	font-weight: 700;
	color: var(--text);
	font-family: 'DM Sans', sans-serif;
	letter-spacing: -0.3px;
	line-height: 1;
}

.attentiq-tagline {
	font-size: 13px;
	font-weight: 400;
	color: var(--text-2-aa);
	font-family: 'DM Sans', sans-serif;
	letter-spacing: 0.1px;
	line-height: 1;
	margin: 0;
}

/* ── Upgrade banner ───────────────────────────────────────── */
.attentiq-upgrade-banner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	background: linear-gradient(135deg, #6c47ff 0%, #a78bfa 100%);
	color: #fff;
	padding: 14px 20px;
	gap: 16px;
}

.attentiq-upgrade-banner-text {
	font-size: 14px;
	line-height: 1.5;
	text-align: center;
	width: 100%;
}

.attentiq-upgrade-banner-text .attentiq-upgrade-btn {
	white-space: nowrap;
	font-weight: 600;
	font-size: 13px;
	text-decoration: underline;
	transition: opacity 0.15s;
	color: #fff;
}

.attentiq-upgrade-banner-text .attentiq-upgrade-btn:hover {
	text-decoration: none;
}

/* ── Buttons ──────────────────────────────────────────────── */
.attentiq_grey_button {
	border: 1px solid var(--border) !important;
	border-radius: var(--radius-sm) !important;
	background: #fff !important;
	color: var(--text) !important;
	font-size: 12px !important;
	font-weight: 600 !important;
	padding: 4px 10px !important;
	margin-left: 6px !important;
	transition: all 0.15s !important;
	box-shadow: none !important;
	text-shadow: none !important;
}

.attentiq_grey_button:hover {
	border-color: var(--primary) !important;
	color: var(--primary-text) !important;
}

/* ── Admin menu upgrade link ──────────────────────────────── */
#adminmenu a[href='admin.php?page=attentiq-upgrade'],
#adminmenu a[href='https://attent-iq.com/upgrade'] {
	background: transparent !important;
	color: #a78bfa !important;
	border-radius: 2px !important;
	margin: 4px 8px !important;
	padding: 6px 12px !important;
	font-weight: 600 !important;
	font-size: 12px !important;
	text-align: center !important;
	display: block !important;
	box-shadow: 0 0 0 1px #8d70ff !important;
}

#adminmenu a[href='admin.php?page=attentiq-upgrade']:hover,
#adminmenu a[href='admin.php?page=attentiq-upgrade'].current,
#adminmenu a[href='https://attent-iq.com/upgrade']:hover,
#adminmenu a[href='https://attent-iq.com/upgrade'].current {
	box-shadow: 0 0 0 2px #a78bfa !important;
	color: #fff !important;
}

/* ── Tooltips ─────────────────────────────────────────────── */
.attentiq-tooltip {
	position: relative;
	cursor: help;
	font-size: 12px;
	color: var(--text-3-aa);
	margin-left: 3px;
}

.attentiq-tooltip::after {
	content: attr(data-tip);
	position: absolute;
	top: 130%;
	left: 50%;
	transform: translateX(-50%);
	background: #1e1e1e;
	color: #fff;
	padding: 7px 10px;
	border-radius: 5px;
	font-size: 12px;
	font-weight: normal;
	white-space: normal;
	width: 220px;
	line-height: 1.5;
	z-index: 999999;
	opacity: 0;
	pointer-events: none;
	transition: opacity 0.2s ease;
}

.attentiq-tooltip:hover::after { opacity: 1; }
.attentiq-tooltip::after       { left: 50%; transform: translateX(-50%); }
.attentiq-tooltip-right::after { left: auto; right: 0; transform: none; }
.attentiq-tooltip-left::after  { left: 0; right: auto; transform: none; }

.attentiq-tooltip-js {
	position: relative;
	display: inline-flex;
	align-items: center;
	cursor: help;
	font-size: 12px;
	color: var(--text-3-aa);
	margin-left: 3px;
}

#attentiq-tooltip {
	display: none;
	position: fixed;
	background: #1e1e1e;
	color: #fff;
	padding: 7px 10px;
	border-radius: 5px;
	font-size: 12px;
	line-height: 1.5;
	width: 220px;
	z-index: 999999;
	pointer-events: none;
}

/* ── Breadcrumbs ──────────────────────────────────────────── */
.aiq-breadcrumb {
	display: flex;
	align-items: center;
	gap: 6px;
	font-size: 12px;
	font-family: var(--font-body);
}

.aiq-breadcrumb a {
	display: flex;
	align-items: center;
	gap: 5px;
	color: var(--primary-text);
	text-decoration: none;
	font-weight: 500;
}

.aiq-breadcrumb a:hover         { text-decoration: underline; }
.aiq-breadcrumb-sep             { color: var(--text-3-aa); }
.aiq-breadcrumb-current {
	color: var(--text);
	font-weight: 600;
	max-width: 300px;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

/* ── Grids ────────────────────────────────────────────────── */
.attentiq-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 16px;
	align-items: start;
}

.attentiq-grid.triple {
	grid-template-columns: 1fr 1fr 1fr;
	margin: 0 auto;
}

.attentiq-grid .attentiq-grid-column {
	display: flex;
	flex-direction: column;
	gap: 16px;
	min-width: 0;
}

/* ── Responsive ───────────────────────────────────────────── */
@media screen and (max-width: 1024px) {
	.attentiq-grid,
	.attentiq-grid.triple { grid-template-columns: 1fr; }
}

@media (max-width: 782px) {
	.attentiq-wrap .attentiq-header .attentiq-logo {
		white-space: nowrap;
		overflow: hidden;
		text-overflow: ellipsis;
		max-width: 300px;
	}
}

/* ── Premium gate (advertiser report fallback) ────────────── */
.aiq-gate-wrap {
	max-width: 480px;
	text-align: center;
	padding: 40px 24px;
}

.aiq-gate-icon {
	font-size: 48px;
	margin-bottom: 16px;
}

.aiq-gate-title {
	font-size: 22px;
	font-weight: 700;
	color: var(--text);
	margin-bottom: 8px;
}

.aiq-gate-desc {
	font-size: 14px;
	color: var(--text-3-aa);
	line-height: 1.6;
	margin-bottom: 28px;
}

.aiq-gate-btn {
	display: inline-block;
	background: var(--primary);
	color: #fff;
	padding: 12px 28px;
	border-radius: 8px;
	font-weight: 700;
	font-size: 14px;
	text-decoration: none;
}

.aiq-gate-btn:hover {
	background: var(--primary-dark);
	color: #fff;
}

.aiq-gate-back {
	display: block;
	margin-top: 16px;
	font-size: 12px;
	color: var(--text-3-aa);
	text-decoration: none;
}

.aiq-gate-back:hover { color: var(--primary); }
/* ── Scan All progress bar ──────────────────────────────────────────────── */
.aiq-scan-progress {
	margin-top: 6px;
	height: 4px;
	background: var(--border-soft);
	border-radius: 2px;
	overflow: hidden;
	width: 160px;
}
.aiq-scan-progress-bar {
	height: 100%;
	width: 0%;
	background: var(--primary);
	border-radius: 2px;
	transition: width 0.3s ease;
}
