/* ==========================================================================
   Haulity LMS — Admin Design System
   All module CSS files import these variables; no module defines its own
   colors, radius, shadow, or base components.
   Version: 1.0.0
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. CSS Custom Properties (design tokens)
   -------------------------------------------------------------------------- */
:root {
	/* Brand */
	--hledu-primary: #2563eb;
	--hledu-primary-hover: #1d4ed8;
	--hledu-primary-light: #eff6ff;
	--hledu-secondary: #7c3aed;
	--hledu-secondary-light: #f5f3ff;

	/* Semantic */
	--hledu-success: #16a34a;
	--hledu-success-light: #f0fdf4;
	--hledu-warning: #d97706;
	--hledu-warning-light: #fffbeb;
	--hledu-danger: #dc2626;
	--hledu-danger-light: #fef2f2;
	--hledu-info: #0891b2;
	--hledu-info-light: #ecfeff;

	/* Neutral */
	--hledu-text: #1f2937;
	--hledu-text-muted: #6b7280;
	--hledu-text-light: #9ca3af;
	--hledu-bg: #f9fafb;
	--hledu-bg-card: #ffffff;
	--hledu-border: #e5e7eb;
	--hledu-border-light: #f3f4f6;

	/* Shape */
	--hledu-radius-sm: 4px;
	--hledu-radius: 8px;
	--hledu-radius-lg: 12px;
	--hledu-radius-xl: 16px;
	--hledu-radius-full: 9999px;

	/* Elevation */
	--hledu-shadow-xs: 0 1px 2px 0 rgb(0 0 0 / 0.04);
	--hledu-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.08), 0 1px 2px -1px rgb(0 0 0 / 0.08);
	--hledu-shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.08), 0 2px 4px -2px rgb(0 0 0 / 0.08);
	--hledu-shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.08), 0 4px 6px -4px rgb(0 0 0 / 0.08);

	/* Motion */
	--hledu-transition: 150ms ease;
	--hledu-transition-slow: 300ms ease;

	/* Typography */
	--hledu-font: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI Variable Display", "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji";

	/* Bento/Glass — surfaces */
	--hledu-surface: #ffffff;
	--hledu-surface-glass: rgb(255 255 255 / 0.6);
	--hledu-blur: 16px;

	/* Bento/Glass — gradient + glow */
	--hledu-gradient-primary: linear-gradient(135deg, #2563eb, #7c3aed, #2563eb);
	--hledu-glow-primary: 0 0 0 3px rgb(37 99 235 / 0.18), 0 0 18px rgb(37 99 235 / 0.22);

	/* Bento/Glass — elevation */
	--hledu-shadow-glass: 0 8px 32px rgb(15 23 42 / 0.10);
}

/* --------------------------------------------------------------------------
   1b. Dark theme — same variable names, new values. Components never need
   a dark-mode-specific class; only these tokens change.
   -------------------------------------------------------------------------- */
[data-hledu-theme="dark"] {
	--hledu-primary: #3b82f6;
	--hledu-primary-hover: #60a5fa;
	--hledu-primary-light: rgb(59 130 246 / 0.16);
	--hledu-secondary: #a78bfa;
	--hledu-secondary-light: rgb(167 139 250 / 0.16);

	--hledu-success: #22c55e;
	--hledu-success-light: rgb(34 197 94 / 0.16);
	--hledu-warning: #f59e0b;
	--hledu-warning-light: rgb(245 158 11 / 0.16);
	--hledu-danger: #f87171;
	--hledu-danger-light: rgb(248 113 113 / 0.16);
	--hledu-info: #22d3ee;
	--hledu-info-light: rgb(34 211 238 / 0.16);

	--hledu-text: #e5e7eb;
	--hledu-text-muted: #9ca3af;
	--hledu-text-light: #6b7280;
	--hledu-bg: #0f1420;
	--hledu-bg-card: #171d2e;
	--hledu-border: #2a3348;
	--hledu-border-light: #212840;

	--hledu-shadow-xs: 0 1px 2px 0 rgb(0 0 0 / 0.35);
	--hledu-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.45), 0 1px 2px -1px rgb(0 0 0 / 0.45);
	--hledu-shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.45), 0 2px 4px -2px rgb(0 0 0 / 0.45);
	--hledu-shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.5), 0 4px 6px -4px rgb(0 0 0 / 0.5);

	--hledu-surface: #171d2e;
	--hledu-surface-glass: rgb(30 38 58 / 0.55);
	--hledu-gradient-primary: linear-gradient(135deg, #3b82f6, #a78bfa, #3b82f6);
	--hledu-glow-primary: 0 0 0 3px rgb(59 130 246 / 0.28), 0 0 18px rgb(59 130 246 / 0.3);
	--hledu-shadow-glass: 0 8px 32px rgb(0 0 0 / 0.45);
}

/* When the user has never chosen a theme, follow the OS preference. */
@media (prefers-color-scheme: dark) {
	:root:not([data-hledu-theme="light"]):not([data-hledu-theme="dark"]) {
		--hledu-primary: #3b82f6;
		--hledu-primary-hover: #60a5fa;
		--hledu-primary-light: rgb(59 130 246 / 0.16);
		--hledu-secondary: #a78bfa;
		--hledu-secondary-light: rgb(167 139 250 / 0.16);
		--hledu-success: #22c55e;
		--hledu-success-light: rgb(34 197 94 / 0.16);
		--hledu-warning: #f59e0b;
		--hledu-warning-light: rgb(245 158 11 / 0.16);
		--hledu-danger: #f87171;
		--hledu-danger-light: rgb(248 113 113 / 0.16);
		--hledu-info: #22d3ee;
		--hledu-info-light: rgb(34 211 238 / 0.16);
		--hledu-text: #e5e7eb;
		--hledu-text-muted: #9ca3af;
		--hledu-text-light: #6b7280;
		--hledu-bg: #0f1420;
		--hledu-bg-card: #171d2e;
		--hledu-border: #2a3348;
		--hledu-border-light: #212840;
		--hledu-shadow-xs: 0 1px 2px 0 rgb(0 0 0 / 0.35);
		--hledu-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.45), 0 1px 2px -1px rgb(0 0 0 / 0.45);
		--hledu-shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.45), 0 2px 4px -2px rgb(0 0 0 / 0.45);
		--hledu-shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.5), 0 4px 6px -4px rgb(0 0 0 / 0.5);
		--hledu-surface: #171d2e;
		--hledu-surface-glass: rgb(30 38 58 / 0.55);
		--hledu-gradient-primary: linear-gradient(135deg, #3b82f6, #a78bfa, #3b82f6);
		--hledu-glow-primary: 0 0 0 3px rgb(59 130 246 / 0.28), 0 0 18px rgb(59 130 246 / 0.3);
		--hledu-shadow-glass: 0 8px 32px rgb(0 0 0 / 0.45);
	}
}

/* Smooth theme switch: colors transition instead of snapping, except when
   the user prefers reduced motion. */
html {
	transition: background-color var(--hledu-transition-slow), color var(--hledu-transition-slow);
}

/* --------------------------------------------------------------------------
   2. Base / reset (scoped to .hledu-wrap)
   -------------------------------------------------------------------------- */
.hledu-wrap {
	font-family: var(--hledu-font);
	color: var(--hledu-text);
	max-width: 1400px;
}

.hledu-wrap *,
.hledu-wrap *::before,
.hledu-wrap *::after {
	box-sizing: border-box;
}

/* --------------------------------------------------------------------------
   3. Page header
   -------------------------------------------------------------------------- */
.hledu-page-header {
	display: flex;
	align-items: center;
	gap: 12px;
	margin: 16px 0 24px;
	padding-bottom: 16px;
	border-bottom: 2px solid var(--hledu-border);
}

.hledu-page-header h1 {
	margin: 0;
	font-size: 22px;
	font-weight: 700;
	color: var(--hledu-text);
	line-height: 1.3;
}

.hledu-page-header__title-group {
	display: flex;
	flex-direction: column;
	gap: 4px;
}

.hledu-page-header__title-row {
	display: flex;
	align-items: center;
	gap: 10px;
}

.hledu-page-header__subtitle {
	margin: 0;
	font-size: 13px;
	font-weight: 400;
	color: var(--hledu-text-muted);
}

.hledu-page-header__actions {
	margin-left: auto;
	display: flex;
	gap: 8px;
	align-items: center;
}

.hledu-version-badge {
	display: inline-flex;
	align-items: center;
	padding: 2px 8px;
	background: var(--hledu-primary-light);
	color: var(--hledu-primary);
	border-radius: var(--hledu-radius-full);
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.3px;
}

/* --------------------------------------------------------------------------
   4. Card component (.hledu-card)
   -------------------------------------------------------------------------- */
.hledu-card {
	background: var(--hledu-bg-card);
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius-lg);
	box-shadow: var(--hledu-shadow);
	margin-bottom: 24px;
	overflow: hidden;
}

.hledu-card-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 14px 20px;
	border-bottom: 1px solid var(--hledu-border);
	background: var(--hledu-bg);
	border-radius: var(--hledu-radius-lg) var(--hledu-radius-lg) 0 0;
}

/* Allows an absolutely-positioned dropdown (e.g. .hledu-tag-dropdown) inside
   this card to escape its bounds instead of being clipped. */
.hledu-card--overflow-visible {
	overflow: visible;
}

.hledu-card-header h2 {
	margin: 0;
	font-size: 14px;
	font-weight: 700;
	color: var(--hledu-text);
	text-transform: uppercase;
	letter-spacing: 0.5px;
}

.hledu-card-body {
	padding: 20px;
}

.hledu-card-footer {
	padding: 12px 20px;
	border-top: 1px solid var(--hledu-border);
	background: var(--hledu-bg);
}

/* --------------------------------------------------------------------------
   5. Table component (.hledu-table)
   -------------------------------------------------------------------------- */
.hledu-table {
	width: 100%;
	border-collapse: collapse;
	font-size: 13px;
}

.hledu-table thead tr {
	background: var(--hledu-bg);
}

.hledu-table th {
	padding: 10px 16px;
	text-align: left;
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.6px;
	color: var(--hledu-text-muted);
	border-bottom: 2px solid var(--hledu-border);
	white-space: nowrap;
}

.hledu-table td {
	padding: 12px 16px;
	border-bottom: 1px solid var(--hledu-border-light);
	color: var(--hledu-text);
	vertical-align: middle;
}

.hledu-table tbody tr:last-child td {
	border-bottom: none;
}

.hledu-table tbody tr:hover td {
	background: var(--hledu-bg);
}

.hledu-table tbody tr.hledu-row--selected td {
	background: var(--hledu-bg);
}

.hledu-table .column-cb {
	width: 36px;
}

/* Row-selection checkmark (Users list bulk select) */
.hledu-user-select-th {
	width: 44px;
}

.hledu-user-select-cell {
	text-align: center;
}

.hledu-user-select-check {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	border: none;
	border-radius: 6px;
	background: transparent;
	color: var(--hledu-text-muted);
	opacity: 0.3;
	cursor: pointer;
	padding: 0;
	transition: background 0.15s, opacity 0.15s, color 0.15s;
}

.hledu-user-select-check:hover {
	opacity: 0.75;
	background: var(--hledu-bg);
}

.hledu-user-select-check--selected {
	color: var(--hledu-success, #16a34a);
	opacity: 1;
}

.hledu-user-select-check--selected:hover {
	background: var(--hledu-success-light, #f0fdf4);
}

/* --------------------------------------------------------------------------
   6. Form components (.hledu-form, .hledu-form-group, .hledu-btn)
   -------------------------------------------------------------------------- */
.hledu-form-group {
	margin-bottom: 20px;
}

/* Two (or more) form groups side by side, e.g. a lesson's Title + Content Type. */
.hledu-form-row {
	display: flex;
	gap: 16px;
}

.hledu-form-row>.hledu-form-group {
	flex: 1;
	min-width: 0;
}

.hledu-form-row>.hledu-form-group:has(.hledu-lesson-form-title) {
	flex: 2;
}

.hledu-form-group label {
	display: block;
	margin-bottom: 5px;
	font-size: 13px;
	font-weight: 600;
	color: var(--hledu-text);
}

.hledu-form-group label .required {
	color: var(--hledu-danger);
	margin-left: 2px;
}

.hledu-input,
.hledu-select,
.hledu-textarea {
	width: 100%;
	max-width: 500px;
	padding: 10px 14px;
	border: 1.5px solid var(--hledu-border);
	border-radius: var(--hledu-radius);
	font-size: 13px;
	font-family: var(--hledu-font);
	color: var(--hledu-text);
	background: var(--hledu-surface);
	box-shadow: var(--hledu-shadow-xs);
	transition: border-color var(--hledu-transition), box-shadow var(--hledu-transition), background var(--hledu-transition);
	/*
	 * These fields sit inside rows with draggable="true" (for reordering).
	 * Browsers make draggable elements — and their descendants — unselectable
	 * by default, and also let a click-drag on a descendant start the row's
	 * native drag instead of the field's own text selection. The JS
	 * "dragFromFormField" guard can only cancel that drag after the fact,
	 * leaving neither a drag nor a text selection. Restoring normal
	 * selection here and opting the field out of starting a native drag
	 * lets normal text selection happen instead.
	 */
	user-select: text;
	-webkit-user-drag: none;
}

.hledu-input:hover,
.hledu-select:hover,
.hledu-textarea:hover {
	border-color: var(--hledu-text-light);
}

/* Lesson Content Type select — custom chevron so it visibly reads as a dropdown.
   !important needed because .hledu-form-group--floating .hledu-select sets the
   `background` shorthand later in this file, which would otherwise wipe the
   background-image/position/repeat set here (same issue as .hledu-toolbar .hledu-select above). */
.hledu-lesson-form-content-type {
	appearance: none;
	-webkit-appearance: none;
	-moz-appearance: none;
	background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%236b7280' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") !important;
	background-repeat: no-repeat !important;
	background-position: right 14px center !important;
	padding-right: 36px;
	cursor: pointer;
}

.hledu-input:focus,
.hledu-select:focus,
.hledu-textarea:focus {
	outline: none;
	border-color: var(--hledu-primary);
	box-shadow: var(--hledu-glow-primary);
}

/* Looks and behaves locked like a disabled field, without actually being
   disabled — the Invite modal's Company select on the frontend dashboards
   can't use the native disabled attribute because hledu-invite.js's shared
   toggleCompanyField() re-enables it on load whenever the selected role
   requires a company (true for Learner here). */
.hledu-select--locked {
	pointer-events: none;
	cursor: not-allowed;
	background: var(--hledu-bg) !important;
	color: var(--hledu-text-muted) !important;
}

.hledu-input--full,
.hledu-select--full,
.hledu-textarea--full {
	max-width: 100%;
}

.hledu-textarea {
	resize: vertical;
	min-height: 120px;
	line-height: 1.6;
}

.hledu-form-hint {
	display: block;
	margin-top: 4px;
	font-size: 11px;
	color: var(--hledu-text-light);
}

.hledu-form-hint-inline {
	font-weight: 400;
	font-size: 12px;
	color: var(--hledu-text-light);
}

.hledu-form-error {
	display: block;
	margin-top: 4px;
	font-size: 11px;
	color: var(--hledu-danger);
}

/* Lesson editor — YouTube preview (Module 07) */
.hledu-lesson-form-video-preview:empty {
	display: none;
}

.hledu-lesson-form-video-preview {
	position: relative;
	width: 100%;
	max-width: 500px;
	margin-top: 10px;
	padding-top: 56.25%;
	/* 16:9 */
	border-radius: var(--hledu-radius);
	overflow: hidden;
	background: var(--hledu-border-light);
}

.hledu-lesson-video-embed {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: 0;
}

/* Lesson editor — Downloadable Resource section (Module 07). Dense form
   content stays on the solid surface, not glass, per the design system. */
.hledu-lesson-form-download {
	margin-top: 16px;
	padding: 14px 16px;
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius-lg);
	background: var(--hledu-surface);
}

.hledu-lesson-form-download-header {
	display: flex;
	align-items: center;
	gap: 6px;
	font-size: 13px;
	font-weight: 600;
	color: var(--hledu-text);
}

.hledu-lesson-form-download-header .dashicons {
	color: var(--hledu-text-muted);
	font-size: 16px;
	width: 16px;
	height: 16px;
}

.hledu-lesson-form-download .hledu-form-hint {
	margin: 4px 0 10px;
}

.hledu-lesson-form-download-preview:not(:empty) {
	margin-bottom: 10px;
}

.hledu-lesson-form-download-actions {
	display: flex;
	gap: 8px;
}

/* Capability checklist (Add/Edit user forms) */
.hledu-caps-toolbar {
	display: flex;
	justify-content: flex-end;
	margin: -4px 0 12px;
}

.hledu-caps-select-all {
	display: flex;
	align-items: center;
	gap: 6px;
	font-size: 12px;
	font-weight: 600;
	color: var(--hledu-primary);
	cursor: pointer;
}

.hledu-caps-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
	gap: 8px;
}

.hledu-cap-item {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 10px 12px;
	background: var(--hledu-bg);
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius-sm);
	font-size: 13px;
	color: var(--hledu-text);
	cursor: pointer;
	transition: background var(--hledu-transition), border-color var(--hledu-transition);
}

.hledu-cap-item:hover {
	border-color: var(--hledu-text-muted);
}

.hledu-cap-item--checked {
	background: var(--hledu-primary-light);
	border-color: var(--hledu-primary);
	color: var(--hledu-primary);
}

.hledu-cap-item[hidden] {
	display: none;
}

.hledu-cap-item:has(input:disabled) {
	opacity: 0.55;
	cursor: not-allowed;
}

.hledu-form-group--caps {
	position: relative;
}

.hledu-cap-toast {
	position: absolute;
	left: 50%;
	top: 8px;
	transform: translateX(-50%);
	background: var(--hledu-text);
	color: var(--hledu-bg-card);
	padding: 10px 18px;
	border-radius: var(--hledu-radius-sm);
	font-size: 13px;
	box-shadow: var(--hledu-shadow-md);
	z-index: 20;
	opacity: 0;
	pointer-events: none;
	transition: opacity 300ms ease;
}

.hledu-cap-toast--visible {
	opacity: 1;
}

.hledu-cap-item input[type="checkbox"]:disabled {
	cursor: not-allowed;
}

/* Icon shown before the capability label */
.hledu-cap-item__icon {
	font-size: 16px !important;
	width: 16px !important;
	height: 16px !important;
	color: var(--hledu-text-muted);
	flex-shrink: 0;
}

.hledu-cap-item--checked .hledu-cap-item__icon {
	color: var(--hledu-primary);
}

.hledu-cap-item__label {
	flex: 1 1 auto;
}

/* Pushes the checkbox to the right edge of the card (it's last in the markup)
   and gives it a smooth, custom look instead of the default browser checkbox.
   Also reused by "Select All", which uses the same last-in-markup pattern. */
.hledu-cap-item input[type="checkbox"],
.hledu-caps-select-all input[type="checkbox"] {
	appearance: none;
	-webkit-appearance: none;
	margin-left: auto;
	flex-shrink: 0;
	width: 20px;
	height: 20px;
	border: 1.5px solid var(--hledu-border);
	border-radius: 6px;
	background: var(--hledu-bg-card);
	cursor: pointer;
	position: relative;
	transition: background var(--hledu-transition), border-color var(--hledu-transition);
}

.hledu-cap-item input[type="checkbox"]:checked,
.hledu-caps-select-all input[type="checkbox"]:checked {
	background: var(--hledu-primary);
	border-color: var(--hledu-primary);
}

.hledu-cap-item input[type="checkbox"]:checked::after,
.hledu-caps-select-all input[type="checkbox"]:checked::after {
	content: "";
	position: absolute;
	left: 6px;
	top: 2px;
	width: 5px;
	height: 10px;
	border: solid #fff;
	border-width: 0 2px 2px 0;
	transform: rotate(45deg);
}

.hledu-cap-item input[type="checkbox"]:focus-visible,
.hledu-caps-select-all input[type="checkbox"]:focus-visible {
	box-shadow: var(--hledu-glow-primary);
}

/* --------------------------------------------------------------------------
   Icon card headers (icon circle + title + subtitle) — User Edit page
   -------------------------------------------------------------------------- */
.hledu-card-header--icon {
	/* Override the base header's justify-content: space-between — that only
	   reads correctly when a 3rd "decoration" element balances it (Personal
	   Details); without one it pushed the title/subtitle to the far right
	   instead of sitting next to the icon. The decoration still lands on the
	   right via its own margin-left: auto below. */
	justify-content: flex-start;
	align-items: flex-start;
	gap: 14px;
}

.hledu-card-header__icon-circle {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	border-radius: var(--hledu-radius);
	background: var(--hledu-secondary-light);
	color: var(--hledu-secondary);
	flex-shrink: 0;
}

.hledu-card-header__icon-circle .dashicons {
	font-size: 22px !important;
	width: 22px !important;
	height: 22px !important;
}

.hledu-card-header__title-group {
	min-width: 0;
}

.hledu-card-header--icon .hledu-card-header__title-group h2 {
	text-transform: none;
	letter-spacing: normal;
	font-size: 16px;
}

.hledu-card-header__subtitle {
	margin: 2px 0 0;
	font-size: 12px;
	font-weight: 400;
	color: var(--hledu-text-muted);
	text-transform: none;
}

.hledu-card-header__decoration {
	margin-left: auto;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 56px;
	height: 56px;
	border-radius: var(--hledu-radius);
	background: var(--hledu-bg);
	color: var(--hledu-border);
	flex-shrink: 0;
}

.hledu-card-header__decoration .dashicons {
	font-size: 26px !important;
	width: 26px !important;
	height: 26px !important;
}

/* Icon prefix inside an input/select, and an optional trailing icon button
   (e.g. the password show/hide toggle) */
.hledu-input-icon-wrap {
	position: relative;
}

.hledu-input-icon-wrap__icon {
	position: absolute;
	left: 12px;
	top: 50%;
	transform: translateY(-50%);
	color: var(--hledu-text-light);
	font-size: 16px !important;
	width: 16px !important;
	height: 16px !important;
	pointer-events: none;
	z-index: 1;
}

.hledu-input-icon-wrap .hledu-input--icon,
.hledu-input-icon-wrap .hledu-select--icon {
	padding-left: 38px !important;
}

.hledu-input-icon-wrap .hledu-input--icon-trailing {
	padding-right: 38px !important;
}

/* Trailing (end) variant of the decorative icon above — e.g. a dropdown
   chevron at the end of a select instead of a leading icon at the start. */
.hledu-input-icon-wrap__icon--end {
	left: auto;
	right: 12px;
}

.hledu-select--icon-end {
	padding-right: 38px !important;
}

.hledu-input-icon-wrap__toggle {
	position: absolute;
	right: 10px;
	top: 50%;
	transform: translateY(-50%);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 24px;
	height: 24px;
	padding: 0;
	border: none;
	background: transparent;
	color: var(--hledu-text-light);
	cursor: pointer;
}

.hledu-input-icon-wrap__toggle:hover {
	color: var(--hledu-text-muted);
}

/* Notice row with an action control (e.g. "Select All") pinned to the right */
.hledu-notice--with-action {
	justify-content: space-between;
}

/* Without this, the <p> shrinks to its own content width and
   justify-content: space-between centers it in the leftover space instead
   of letting it sit flush left next to the icon. */
.hledu-notice--with-action p {
	flex: 1 1 auto;
	text-align: left;
}

.hledu-notice--with-action .hledu-caps-select-all {
	flex-shrink: 0;
	white-space: nowrap;
}

/* Small icon + muted text row inside a .hledu-card-footer */
.hledu-card-footer-note {
	display: flex;
	align-items: center;
	gap: 6px;
	margin: 0;
	font-size: 12px;
	color: var(--hledu-text-muted);
}

.hledu-card-footer-note .dashicons {
	font-size: 14px !important;
	width: 14px !important;
	height: 14px !important;
	flex-shrink: 0;
}

/* Buttons */
.hledu-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 9px 18px;
	background: var(--hledu-primary);
	background-image: var(--hledu-gradient-primary);
	background-size: 200% 100%;
	background-position: 0 0;
	color: #fff !important;
	border: 1px solid transparent;
	border-radius: var(--hledu-radius);
	font-size: 13px;
	font-weight: 700;
	font-family: var(--hledu-font);
	cursor: pointer;
	text-decoration: none !important;
	box-shadow: var(--hledu-shadow-xs);
	transition: background-position var(--hledu-transition-slow), box-shadow var(--hledu-transition), transform var(--hledu-transition);
	line-height: 1.4;
	white-space: nowrap;
}

.hledu-btn:hover,
.hledu-btn:focus {
	background-position: 100% 0;
	color: #fff !important;
	box-shadow: var(--hledu-shadow-md);
	transform: translateY(-1px);
}

.hledu-btn:active {
	transform: translateY(0);
	box-shadow: var(--hledu-shadow-xs);
}

.hledu-btn:focus-visible {
	box-shadow: var(--hledu-glow-primary);
}

.hledu-btn--sm {
	padding: 5px 10px;
	font-size: 12px;
}

.hledu-btn--lg {
	padding: 11px 22px;
	font-size: 14px;
}

.hledu-btn--secondary {
	background: var(--hledu-bg-card);
	color: var(--hledu-text) !important;
	border-color: var(--hledu-border);
}

.hledu-btn--secondary:hover,
.hledu-btn--secondary:focus {
	background: var(--hledu-bg) !important;
	color: var(--hledu-text) !important;
	border-color: var(--hledu-text-muted);
}

.hledu-btn--danger {
	background: var(--hledu-danger);
}

.hledu-btn--danger:hover {
	background: #b91c1c;
}

.hledu-btn--success {
	background: var(--hledu-success);
}

.hledu-btn--success:hover {
	background: #15803d;
}

.hledu-btn--ghost {
	background: transparent;
	color: var(--hledu-primary) !important;
	border-color: transparent;
	box-shadow: none;
}

.hledu-btn--ghost:hover {
	background: var(--hledu-primary-light);
}

.hledu-btn[disabled],
.hledu-btn:disabled {
	opacity: 0.55;
	cursor: not-allowed;
	pointer-events: none;
}

/* Icon-only Edit/Delete buttons (modules, lessons, quizzes, questions) —
   bordered square icon button; Delete turns reddish on hover. */
.hledu-icon-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	padding: 0 !important;
	background: var(--hledu-bg-card) !important;
	border: 1px solid var(--hledu-border) !important;
	border-radius: var(--hledu-radius-sm);
	color: var(--hledu-text-muted) !important;
	opacity: 1;
	box-shadow: none !important;
}

.hledu-icon-btn:hover {
	background: var(--hledu-bg) !important;
	border-color: var(--hledu-text-muted) !important;
	color: var(--hledu-text) !important;
	opacity: 1;
	box-shadow: none !important;
	transform: none !important;
}

/* .hledu-btn--danger's text stays white for its normal filled background;
   with that background removed here, force a visible icon color instead,
   turning reddish on hover. */
.hledu-icon-btn.hledu-btn--danger {
	color: var(--hledu-text-muted) !important;
}

.hledu-icon-btn.hledu-btn--danger:hover {
	background: var(--hledu-danger-light) !important;
	border-color: var(--hledu-danger) !important;
	color: var(--hledu-danger) !important;
}

/* Platform Owner's Courses list — Delete icon. Renamed away from the
   admin course list's .hledu-course-delete-btn (below), which sets
   opacity: 0 by default and only reveals itself on row/icon hover — a
   different button this one accidentally shared a class name with,
   making it invisible on load. This one should always be visible, same
   dark color as the Edit/View icons beside it. */
.hledu-icon-btn.hledu-btn--danger.hledu-owner-course-delete-btn {
	color: var(--hledu-text) !important;
}

.hledu-icon-btn.hledu-btn--danger.hledu-owner-course-delete-btn:hover {
	color: var(--hledu-danger) !important;
}

/* .hledu-btn--success's text stays white for its normal filled background;
   same fix as .hledu-icon-btn.hledu-btn--danger above, so the icon (e.g.
   the Certificates page's Revoke button after it flips to "Reinstate")
   doesn't render invisible white-on-white. */
.hledu-icon-btn.hledu-btn--success {
	color: var(--hledu-text-muted) !important;
}

.hledu-icon-btn.hledu-btn--success:hover {
	background: var(--hledu-success-light) !important;
	border-color: var(--hledu-success) !important;
	color: var(--hledu-success) !important;
}

/* --------------------------------------------------------------------------
   7. Badge component (.hledu-badge)
   -------------------------------------------------------------------------- */
.hledu-badge {
	display: inline-flex;
	align-items: center;
	padding: 2px 9px;
	border-radius: var(--hledu-radius-full);
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.3px;
	text-transform: capitalize;
	white-space: nowrap;
}

/* Modifier classes */
.hledu-badge--success,
.hledu-badge--active,
.hledu-badge--published,
.hledu-badge--completed,
.hledu-badge--approved {
	background: var(--hledu-success-light);
	color: var(--hledu-success);
}

.hledu-badge--warning,
.hledu-badge--pending,
.hledu-badge--draft {
	background: var(--hledu-warning-light);
	color: var(--hledu-warning);
}

.hledu-badge--danger,
.hledu-badge--inactive,
.hledu-badge--cancelled,
.hledu-badge--rejected,
.hledu-badge--failed {
	background: var(--hledu-danger-light);
	color: var(--hledu-danger);
}

.hledu-badge--info,
.hledu-badge--processing {
	background: var(--hledu-info-light);
	color: var(--hledu-info);
}

.hledu-badge--primary {
	background: var(--hledu-primary-light);
	color: var(--hledu-primary);
}

.hledu-badge--secondary {
	background: var(--hledu-secondary-light);
	color: var(--hledu-secondary);
}

.hledu-badge--neutral {
	background: var(--hledu-border-light);
	color: var(--hledu-text-muted);
}

/* --------------------------------------------------------------------------
   8. Notice component (.hledu-notice)
   -------------------------------------------------------------------------- */
.hledu-notice {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 12px 16px;
	border-radius: var(--hledu-radius-sm);
	border-left: 4px solid;
	margin-bottom: 16px;
	font-size: 13px;
	line-height: 1.5;
}

.hledu-notice p {
	margin: 0;
}

.hledu-notice--success {
	background: var(--hledu-success-light);
	border-color: var(--hledu-success);
	color: var(--hledu-success);
}

.hledu-notice--error {
	background: var(--hledu-danger-light);
	border-color: var(--hledu-danger);
	color: var(--hledu-danger);
}

.hledu-notice--warning {
	background: var(--hledu-warning-light);
	border-color: var(--hledu-warning);
	color: var(--hledu-warning);
}

.hledu-notice--info {
	background: var(--hledu-info-light);
	border-color: var(--hledu-info);
	color: var(--hledu-info);
}

.hledu-notice--flush {
	margin-bottom: 0;
}

/* Row layout for the module/lesson Content toolbar: action buttons on the
   left, an info notice pinned to the right (wraps to its own line on narrow
   viewports). */
.hledu-content-toolbar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 12px;
}

.hledu-content-toolbar__actions {
	display: flex;
	align-items: center;
	gap: 10px;
	flex-wrap: wrap;
	flex-shrink: 0;
}

.hledu-content-toolbar .hledu-notice {
	border-left: none;
	border-right: 4px solid;
}

.hledu-content-toolbar .hledu-notice p {
	text-align: right;
}

/* Frontend course form embeds this toolbar in a narrower main column (there's
   a sidebar), so it wraps to two rows there even though it fits on one row
   on the full-width admin page — keep it on the same row here specifically. */
.hledu-frontend .hledu-content-toolbar {
	flex-wrap: nowrap;
}

.hledu-notice--mt {
	margin-top: 16px;
}

/* Users list — avatar before the name (real photo, or initials fallback) */
.hledu-user-cell {
	display: flex;
	align-items: center;
	gap: 10px;
}

.hledu-user-avatar {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	border-radius: 50%;
	flex-shrink: 0;
	object-fit: cover;
}

.hledu-user-avatar--initials {
	font-size: 12px;
	font-weight: 700;
	color: #fff;
	letter-spacing: 0.3px;
}

.hledu-user-avatar--c0 {
	background: #7c3aed;
}

.hledu-user-avatar--c1 {
	background: #f97316;
}

.hledu-user-avatar--c2 {
	background: #2563eb;
}

.hledu-user-avatar--c3 {
	background: #16a34a;
}

.hledu-user-avatar--c4 {
	background: #eab308;
}

.hledu-user-avatar--c5 {
	background: #0891b2;
}

.hledu-user-avatar--c6 {
	background: #db2777;
}

.hledu-user-avatar--c7 {
	background: #dc2626;
}

.hledu-profile-picture-picker {
	display: flex;
	align-items: center;
	gap: 16px;
}

.hledu-profile-picture-picker .hledu-user-avatar,
.hledu-profile-picture-picker__preview {
	width: 72px;
	height: 72px;
	font-size: 26px;
	border-radius: var(--hledu-radius-full);
	object-fit: cover;
	flex-shrink: 0;
}

.hledu-profile-picture-picker__preview-wrap {
	position: relative;
	display: inline-flex;
	flex-shrink: 0;
}

.hledu-profile-picture-picker__remove {
	position: absolute;
	top: -4px;
	right: -4px;
	width: 20px;
	height: 20px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: var(--hledu-radius-full);
	background: #dc2626;
	color: #fff;
	border: 2px solid var(--hledu-surface, #fff);
	font-size: 14px;
	line-height: 1;
	padding: 0;
	cursor: pointer;
}

.hledu-profile-picture-picker__field {
	display: flex;
	flex-direction: column;
	gap: 4px;
}

/* --------------------------------------------------------------------------
   9. Stats row
   -------------------------------------------------------------------------- */
.hledu-stats-row {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
	gap: 16px;
	margin-bottom: 24px;
}

.hledu-stat-card {
	display: flex;
	align-items: center;
	gap: 14px;
	padding: 18px;
	background: var(--hledu-bg-card);
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius);
	box-shadow: var(--hledu-shadow-xs);
	transition: box-shadow var(--hledu-transition);
	position: relative;
	overflow: hidden;
}

a.hledu-stat-card {
	color: inherit;
	text-decoration: none;
}

/* Soft decorative glow in the bottom-right corner, tinted per card variant */
.hledu-stat-card::after {
	content: "";
	position: absolute;
	right: -30px;
	bottom: -30px;
	width: 130px;
	height: 130px;
	border-radius: 50%;
	background: currentColor;
	opacity: 0.07;
	pointer-events: none;
	z-index: 0;
}

.hledu-stat-card--companies::after {
	color: var(--hledu-primary);
}

.hledu-stat-card--students::after {
	color: var(--hledu-success);
}

.hledu-stat-card--courses::after {
	color: var(--hledu-secondary);
}

.hledu-stat-card--employees::after {
	color: var(--hledu-warning);
}

.hledu-stat-card--logins::after {
	color: var(--hledu-info);
}



.hledu-stat-card:hover {
	box-shadow: var(--hledu-shadow-md);
}

.hledu-stat-card--highlight {
	border-color: var(--hledu-primary);
	background: var(--hledu-primary-light);
}

/* .hledu-bento-card sets flex-direction: column and is defined later in this
   file, which was silently overriding the icon/number/chart row layout below
   (equal specificity, later rule wins). Force the row layout back with a
   higher-specificity compound selector. */
.hledu-stat-card.hledu-bento-card {
	flex-direction: row;
	align-items: center;
	gap: 14px;
}

.hledu-stat-icon {
	font-size: 26px !important;
	width: 26px !important;
	height: 26px !important;
	color: var(--hledu-primary);
	flex-shrink: 0;
}

.hledu-stat-body {
	display: flex;
	flex-direction: column;
	gap: 2px;
	min-width: 0;
}

.hledu-stat-value {
	font-size: 28px;
	font-weight: 800;
	color: var(--hledu-text);
	line-height: 1;
}

.hledu-stat-label {
	font-size: 11px;
	font-weight: 600;
	color: var(--hledu-text-muted);
	text-transform: uppercase;
	letter-spacing: 0.4px;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* --------------------------------------------------------------------------
   10. Toolbar (search + filter bar above tables)
   -------------------------------------------------------------------------- */
.hledu-toolbar {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 14px 16px;
	border-bottom: 1px solid var(--hledu-border);
	background: var(--hledu-bg);
	flex-wrap: wrap;
}

.hledu-toolbar-spacer {
	flex: 1;
}

.hledu-toolbar .hledu-select {
	/* !important on border/radius/shadow, same as .hledu-header-search__input:
	   WP core admin CSS styles <select> with enough specificity to otherwise
	   partially override these and keep it visually out of sync. */
	appearance: none;
	-webkit-appearance: none;
	-moz-appearance: none;
	width: auto;
	height: 36px !important;
	padding: 0 30px 0 12px !important;
	border: 1.5px solid var(--hledu-border) !important;
	border-radius: var(--hledu-radius) !important;
	box-shadow: var(--hledu-shadow-xs) !important;
	background-color: var(--hledu-surface);
	background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%236b7280' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 12px center;
	cursor: pointer;
	transition: border-color var(--hledu-transition), box-shadow var(--hledu-transition);
}

.hledu-toolbar .hledu-select:hover {
	border-color: var(--hledu-text-muted) !important;
}

.hledu-toolbar .hledu-select:focus {
	outline: none !important;
	border-color: var(--hledu-primary) !important;
	box-shadow: var(--hledu-glow-primary) !important;
}

.hledu-bulk-actions-wrap {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 6px 8px;
	background: var(--hledu-bg-card);
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius);
}

.hledu-bulk-actions-wrap .hledu-select {
	max-width: 160px;
}

.hledu-search-wrap {
	position: relative;
	display: flex;
	align-items: center;
}

.hledu-search-input {
	/* !important throughout, same as .hledu-header-search__input: WP core
	   admin CSS styles input[type=text] with enough specificity to otherwise
	   partially override this, keeping it visually out of sync with the
	   rest of the design system. */
	box-sizing: border-box !important;
	height: 36px !important;
	padding: 0 34px 0 14px !important;
	border: 1.5px solid var(--hledu-border) !important;
	border-radius: var(--hledu-radius-full) !important;
	font-size: 13px !important;
	min-width: 240px;
	background: var(--hledu-surface) !important;
	color: var(--hledu-text) !important;
	box-shadow: var(--hledu-shadow-xs) !important;
	transition: border-color var(--hledu-transition), box-shadow var(--hledu-transition);
}

.hledu-search-input:focus {
	outline: none !important;
	border-color: var(--hledu-primary) !important;
	box-shadow: var(--hledu-glow-primary) !important;
}

/* --------------------------------------------------------------------------
   11. Tabs
   -------------------------------------------------------------------------- */
.hledu-tabs {
	display: flex;
	gap: 0;
	border-bottom: 2px solid var(--hledu-border);
	margin-bottom: 20px;
}

.hledu-tab {
	padding: 10px 16px;
	font-size: 13px;
	font-weight: 600;
	color: var(--hledu-text-muted);
	text-decoration: none;
	border-bottom: 2px solid transparent;
	margin-bottom: -2px;
	transition: color var(--hledu-transition), border-color var(--hledu-transition);
	cursor: pointer;
	white-space: nowrap;
}

.hledu-tab:hover {
	color: var(--hledu-text);
	text-decoration: none;
}

.hledu-tab.active,
.hledu-tab--active {
	color: var(--hledu-primary);
	border-bottom-color: var(--hledu-primary);
}

.hledu-tab-count {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 20px;
	padding: 0 5px;
	height: 18px;
	border-radius: 9px;
	background: var(--hledu-border);
	color: var(--hledu-text-muted);
	font-size: 11px;
	font-weight: 600;
	margin-left: 5px;
	line-height: 1;
}

.hledu-tab--active .hledu-tab-count {
	background: var(--hledu-primary-light);
	color: var(--hledu-primary);
}

/* --------------------------------------------------------------------------
   12. Pagination
   -------------------------------------------------------------------------- */
.hledu-pagination {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 4px;
	padding: 16px;
}

.hledu-pagination a,
.hledu-pagination span {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 32px;
	height: 32px;
	padding: 0 6px;
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius-sm);
	font-size: 13px;
	text-decoration: none;
	color: var(--hledu-text-muted);
	transition: background var(--hledu-transition);
}

.hledu-pagination a:hover {
	background: var(--hledu-bg);
}

.hledu-pagination .current {
	background: var(--hledu-primary);
	border-color: var(--hledu-primary);
	color: #fff;
}

/* --------------------------------------------------------------------------
   13. Modal
   -------------------------------------------------------------------------- */
.hledu-modal-overlay {
	position: fixed;
	inset: 0;
	background: rgb(0 0 0 / 0.45);
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
}

.hledu-modal {
	background: var(--hledu-bg-card);
	border-radius: var(--hledu-radius-lg);
	box-shadow: var(--hledu-shadow-lg);
	width: 100%;
	max-width: 620px;
	max-height: 90vh;
	overflow-y: auto;
}

.hledu-modal-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 16px 30px;
	border-bottom: 1px solid var(--hledu-border);
}

.hledu-modal-header h2 {
	margin: 0;
	font-size: 16px;
	font-weight: 700;
	color: var(--hledu-text);
}

.hledu-modal-close {
	background: none;
	border: none;
	cursor: pointer;
	color: var(--hledu-text-light);
	padding: 0;
	line-height: 1;
	font-size: 22px;
	transition: color var(--hledu-transition);
}

.hledu-modal-close:hover {
	color: var(--hledu-danger);
}

.hledu-modal-body {
	padding: 20px 30px;
}

.hledu-modal-footer {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 8px;
	padding: 14px 30px;
	border-top: 1px solid var(--hledu-border);
}

/* Confirmation-style modal (centred icon + text) — hidden by default via ID */
#hledu-delete-modal {
	display: none;
}

#hledu-delete-modal.hledu-modal--open {
	display: flex;
}

#hledu-delete-all-modules-modal {
	display: none;
}

#hledu-delete-all-modules-modal.hledu-modal--open {
	display: flex;
}

#hledu-reset-lms-modal {
	display: none;
}

#hledu-reset-lms-modal.hledu-modal--open {
	display: flex;
}

.hledu-modal--confirm {
	max-width: 440px;
	padding: 32px 28px 28px;
	text-align: center;
	position: relative;
}

.hledu-modal-close {
	position: absolute;
	top: 14px;
	right: 16px;
}

.hledu-modal-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 56px;
	height: 56px;
	border-radius: 50%;
	margin: 0 auto 16px;
}

.hledu-modal-icon--danger {
	background: var(--hledu-danger-light);
	color: var(--hledu-danger);
}

#hledu-delete-modal-title {
	margin: 0 0 8px;
	font-size: 17px;
	font-weight: 700;
	color: var(--hledu-text);
}

.hledu-modal-course-name {
	margin: 0 0 10px;
	font-weight: 600;
	color: var(--hledu-text);
	font-size: 14px;
}

.hledu-modal-warning {
	margin: 0 0 24px;
	font-size: 13px;
	color: var(--hledu-text-muted);
	line-height: 1.55;
}

.hledu-modal-actions {
	display: flex;
	gap: 10px;
	justify-content: center;
}

/* Module 12 — Invite Learner modal (Company Account + Company Employee dashboards) */
#hledu-invite-modal {
	display: none;
	/* On the frontend dashboards this modal is a direct child of the block
	   theme's .is-layout-constrained post-content wrapper, whose global
	   styles cap every non-aligned child to the theme's content width
	   (theme.json's contentSize, e.g. 620px) via a low-specificity :where()
	   selector — capping this overlay (and the .hledu-modal box sized off
	   it) far narrower than on wp-admin, which has no such wrapper. This ID
	   selector's specificity always wins without needing !important. */
	max-width: none;
}

#hledu-invite-modal.hledu-modal--open {
	display: flex;
}

/* Scoped, ID-anchored overrides for this modal only:
   1. .hledu-modal-header's own justify-content:space-between (declared later
      in this file than .hledu-card-header--icon's flex-start) otherwise wins
      the cascade tie, pushing the title away from the icon instead of
      sitting left-aligned next to it.
   2. wp-admin core's own forms.css styles input[type="email"]/"text"/select
      etc. with a bare attribute selector, which beats a lone .hledu-input
      class selector on specificity — so on this wp-admin screen the fields
      were silently falling back to WP's plain 2px-radius default instead of
      this design system's input styling. */
#hledu-invite-modal .hledu-modal-header {
	justify-content: flex-start;
}

#hledu-invite-modal .hledu-input,
#hledu-invite-modal .hledu-select,
#hledu-invite-modal .hledu-textarea {
	border: 1.5px solid var(--hledu-border);
	border-radius: var(--hledu-radius);
	box-shadow: var(--hledu-shadow-xs);
	background: var(--hledu-surface);
	color: var(--hledu-text);
}

#hledu-invite-modal .hledu-modal {
	max-width: 880px;
}

#hledu-invite-modal .hledu-card-header__icon-circle svg {
	width: 22px;
	height: 22px;
}

/* The Invite Method box needs more room than Role/Company to fit its 3-way
   Email/WhatsApp/Invite Link segmented control without the buttons
   overflowing their shared border. */
#hledu-invite-modal .hledu-form-row>.hledu-form-group {
	flex: 0.9 1 0;
}

#hledu-invite-modal .hledu-form-row>#hledu-invite-method-field {
	flex: 1.2 1 0;
}

/* Footer has a left-side "N users ready" status alongside Cancel/Send —
   the shared .hledu-modal-footer rule is flex-end only, scoped override here. */
#hledu-invite-modal .hledu-modal-footer {
	justify-content: space-between;
}

.hledu-invite-footer-status {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 13px;
	font-weight: 600;
	color: var(--hledu-text-muted);
}

.hledu-invite-footer-status__icon {
	color: var(--hledu-success);
}

.hledu-invite-footer-actions {
	display: flex;
	align-items: center;
	gap: 8px;
}

/* Two-column body layout: People to Invite (left) + Permissions (right),
   divided by a horizontal rule from the row above and a vertical rule
   between the columns. */
.hledu-invite-columns {
	display: flex;
	align-items: flex-start;
	margin-top: 10px;
	padding-top: 30px;
	border-top: 1px solid var(--hledu-border);
}

.hledu-invite-col-left,
.hledu-invite-col-right {
	flex: 1;
	min-width: 0;
}

.hledu-invite-col-left {
	padding-right: 24px;
}

.hledu-invite-col-right {
	padding-left: 24px;
	border-left: 1px solid var(--hledu-border);
}

.hledu-invite-caps-header {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 10px;
}

.hledu-invite-caps-header .hledu-invite-section-title {
	margin: 0;
}

.hledu-invite-caps-actions {
	display: flex;
	align-items: center;
	gap: 14px;
}


/* Permissions list: 2 per row, no card/border, checkbox before the label
   (markup order changed to checkbox-first, so the shared .hledu-cap-item
   rule's margin-left:auto — written for the old "checkbox last" layout —
   needs to be neutralized here). Scoped to this modal's own grid ID only;
   the Add User page's capability grid (a different ID) is unaffected. */
#hledu-invite-caps-grid {
	grid-template-columns: repeat(2, 1fr);
}

#hledu-invite-caps-grid .hledu-cap-item {
	background: none;
	border: none;
	padding: 4px 0;
}

#hledu-invite-caps-grid .hledu-cap-item:hover {
	border-color: transparent;
}

#hledu-invite-caps-grid .hledu-cap-item--checked {
	background: none;
	border-color: transparent;
}

#hledu-invite-caps-grid .hledu-cap-item input[type="checkbox"] {
	margin-left: 0;
}

/* No focus glow on click — the shared .hledu-cap-item:focus-visible rule
   (also used by the Add User page's own capability grid) is intentionally
   left alone; this only cancels it out within this modal's grid. */
#hledu-invite-caps-grid input[type="checkbox"]:focus-visible {
	box-shadow: none;
}

.hledu-invite-section-title {
	margin: 0 0 10px;
	font-size: 14px;
	font-weight: 700;
	color: var(--hledu-text);
}

.hledu-invite-generate-row {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	gap: 12px;
	margin-bottom: 18px;
}

.hledu-invite-generate-row .hledu-form-group {
	margin: 0;
}

.hledu-invite-generate-row .hledu-input {
	width: 110px;
}

.hledu-invite-table td {
	vertical-align: middle;
}

.hledu-invite-table td:first-child {
	display: flex;
	align-items: center;
	gap: 8px;
	min-width: 260px;
}

.hledu-invite-table td:first-child .hledu-input {
	flex: 1;
}

/* Invite User modal — channel picker (Email / WhatsApp / Link), styled as one
   seamless segmented control (shared outer border, divider between segments,
   rounded corners only at the two outer ends) rather than 3 separate pill buttons. */
.hledu-invite-channel-tabs {
	display: flex;
	border: 1.5px solid var(--hledu-border);
	border-radius: var(--hledu-radius);
	overflow: hidden;
}

.hledu-invite-channel-btn {
	flex: 1;
	min-width: 0;
	justify-content: center;
	gap: 5px;
	padding: 9px 10px;
	border: none;
	border-radius: 0;
	background: var(--hledu-surface);
	color: var(--hledu-text) !important;
	font-size: 12.5px;
	transition: background var(--hledu-transition), box-shadow var(--hledu-transition), color var(--hledu-transition);
}

.hledu-invite-channel-btn+.hledu-invite-channel-btn {
	border-left: 1.5px solid var(--hledu-border);
}

.hledu-invite-channel-btn:hover,
.hledu-invite-channel-btn:focus {
	background: var(--hledu-bg) !important;
}

.hledu-invite-channel-btn.hledu-invite-channel-btn--active {
	position: relative;
	z-index: 1;
	background: var(--hledu-primary-light) !important;
	color: var(--hledu-primary) !important;
	box-shadow: inset 0 0 0 1.5px var(--hledu-primary);
}

/* Invite User modal — multi-value chip input (recipient emails/phone numbers) */
.hledu-chip-input {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px;
	width: 100%;
	max-width: 500px;
	min-height: 42px;
	padding: 6px 8px;
	border: 1.5px solid var(--hledu-border);
	border-radius: var(--hledu-radius);
	background: var(--hledu-surface);
	box-shadow: var(--hledu-shadow-xs);
}

.hledu-chip-input:focus-within {
	border-color: var(--hledu-primary);
}

/* WhatsApp invites aren't available yet — the chip box visibly dims when
   its input is disabled instead of looking identical to the working state. */
.hledu-chip-input:has(input:disabled) {
	background: var(--hledu-bg);
	opacity: 0.65;
}

.hledu-chip-input__field:disabled {
	cursor: not-allowed;
}

.hledu-chip {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 4px 6px 4px 10px;
	border-radius: 999px;
	background: var(--hledu-primary-light);
	color: var(--hledu-primary);
	font-size: 12px;
	font-weight: 600;
	white-space: nowrap;
}

.hledu-chip__remove {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 16px;
	height: 16px;
	padding: 0;
	border: none;
	border-radius: 50%;
	background: transparent;
	color: inherit;
	cursor: pointer;
	line-height: 1;
	font-size: 14px;
}

.hledu-chip__remove:hover {
	background: rgb(0 0 0 / 0.08);
}

.hledu-chip-input__field {
	flex: 1;
	min-width: 140px;
	border: none;
	outline: none;
	background: transparent;
	font-size: 13px;
	font-family: var(--hledu-font);
	color: var(--hledu-text);
	padding: 4px;
}

/* Course list — permanent delete icon button (archived rows only) */
.hledu-course-delete-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	border: none;
	border-radius: 6px;
	background: transparent;
	color: var(--hledu-danger);
	cursor: pointer;
	padding: 0;
	opacity: 0;
	transition: opacity 0.15s, background 0.15s;
}

tr:hover .hledu-course-delete-btn {
	opacity: 0.55;
}

.hledu-course-delete-btn:hover {
	opacity: 1 !important;
	background: var(--hledu-danger-light);
}

/* --------------------------------------------------------------------------
   14. Empty state
   -------------------------------------------------------------------------- */
.hledu-empty-state {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 56px 20px;
	text-align: center;
}

.hledu-empty-state .dashicons {
	font-size: 44px !important;
	width: 44px !important;
	height: 44px !important;
	color: var(--hledu-border);
	margin-bottom: 14px;
}

.hledu-empty-state p {
	margin: 0;
	font-size: 14px;
	color: var(--hledu-text-muted);
}

/* --------------------------------------------------------------------------
   15. Coming soon
   -------------------------------------------------------------------------- */
.hledu-coming-soon {
	display: flex;
	flex-direction: column;
	align-items: center;
	padding: 64px 20px;
	text-align: center;
}

.hledu-coming-soon .dashicons {
	font-size: 52px !important;
	width: 52px !important;
	height: 52px !important;
	color: var(--hledu-border);
	margin-bottom: 18px;
}

.hledu-coming-soon h2 {
	margin: 0 0 8px;
	font-size: 20px;
	font-weight: 700;
	color: var(--hledu-text);
}

.hledu-coming-soon p {
	margin: 0;
	font-size: 14px;
	color: var(--hledu-text-muted);
}

/* --------------------------------------------------------------------------
   16. Quick links
   -------------------------------------------------------------------------- */
.hledu-quick-links {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	padding: 18px;
}

.hledu-quick-link {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	padding: 9px 15px;
	background: var(--hledu-bg);
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius);
	font-size: 13px;
	font-weight: 600;
	color: var(--hledu-text) !important;
	text-decoration: none !important;
	transition: background var(--hledu-transition), border-color var(--hledu-transition), color var(--hledu-transition);
}

.hledu-quick-link:hover {
	background: var(--hledu-primary-light);
	border-color: var(--hledu-primary);
	color: var(--hledu-primary) !important;
}

.hledu-quick-link .dashicons {
	font-size: 16px !important;
	width: 16px !important;
	height: 16px !important;
}

/* --------------------------------------------------------------------------
   17. Row actions (inside table cells)
   -------------------------------------------------------------------------- */
.hledu-row-actions {
	display: flex;
	gap: 10px;
	align-items: center;
	flex-wrap: wrap;
}

.hledu-row-actions a {
	font-size: 12px;
	color: var(--hledu-primary);
	text-decoration: none;
}

.hledu-row-actions a:hover {
	text-decoration: underline;
}

.hledu-row-actions a.hledu-delete,
.hledu-row-actions .hledu-row-delete {
	color: var(--hledu-danger);
}

/* --------------------------------------------------------------------------
   18. Dashboard — Super Admin (Module 03)
   -------------------------------------------------------------------------- */

/* Full width on every Haulity LMS admin page. "hledu-page-*" is stamped by
   our own admin_body_class filter (Hledu_Admin::add_body_class()) on every
   hledu- page, so this never affects core WP admin screens. Existing
   .hledu-toolbar / .hledu-table responsive breakpoints elsewhere are
   unaffected since they key off viewport width, not this wrapper. */
body[class*="hledu-page-"] .hledu-wrap {
	max-width: none;
}

/* Stat card color variants for each platform metric */
.hledu-stat-card--companies .hledu-stat-icon {
	color: var(--hledu-primary);
}

.hledu-stat-card--students .hledu-stat-icon {
	color: var(--hledu-success);
}

.hledu-stat-card--courses .hledu-stat-icon {
	color: var(--hledu-secondary);
}

.hledu-stat-card--employees .hledu-stat-icon {
	color: var(--hledu-warning);
}

.hledu-stat-card--logins .hledu-stat-icon {
	color: var(--hledu-info);
}

/* Circular icon avatar wrapping the stat icon */
.hledu-stat-icon-circle {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 56px;
	height: 56px;
	border-radius: 50%;
	flex-shrink: 0;
}

.hledu-stat-icon-circle .hledu-stat-icon {
	font-size: 26px !important;
	width: 26px !important;
	height: 26px !important;
}

.hledu-stat-card--companies .hledu-stat-icon-circle {
	background: var(--hledu-primary-light);
}

.hledu-stat-card--students .hledu-stat-icon-circle {
	background: var(--hledu-success-light);
}

.hledu-stat-card--courses .hledu-stat-icon-circle {
	background: var(--hledu-secondary-light);
}

.hledu-stat-card--employees .hledu-stat-icon-circle {
	background: var(--hledu-warning-light);
}

.hledu-stat-card--logins .hledu-stat-icon-circle {
	background: var(--hledu-info-light);
}

/* "+2 this month" trend line under the label */
.hledu-stat-trend {
	display: inline-flex;
	align-items: center;
	font-size: 11px;
	font-weight: 700;
	margin-top: 2px;
}

.hledu-stat-trend .dashicons {
	font-size: 13px !important;
	width: 13px !important;
	height: 13px !important;
}

.hledu-stat-trend--up {
	color: var(--hledu-success);
}

.hledu-stat-trend--down {
	color: var(--hledu-danger);
}

.hledu-stat-trend--flat {
	color: var(--hledu-text-light);
}


/* ── Dashboard header cluster: search, icon buttons, user profile ────────── */
.hledu-header-search {
	position: relative;
	display: flex;
	align-items: center;
}

.hledu-header-search__input {
	/* !important throughout: WP core admin CSS styles input[type=text] with
	   enough specificity to otherwise win over this single class, which was
	   partially overriding the border/radius/padding (causing the icon to
	   sit on top of the placeholder text instead of clear of it). */
	box-sizing: border-box !important;
	width: 220px !important;
	height: 36px !important;
	padding: 0 14px 0 36px !important;
	border: 1.5px solid var(--hledu-border) !important;
	border-radius: var(--hledu-radius-full) !important;
	background: var(--hledu-surface) !important;
	color: var(--hledu-text) !important;
	font-size: 13px !important;
	font-family: var(--hledu-font) !important;
	box-shadow: var(--hledu-shadow-xs) !important;
	transition: border-color var(--hledu-transition), box-shadow var(--hledu-transition);
}

.hledu-header-search__input:focus {
	outline: none !important;
	border-color: var(--hledu-primary) !important;
	box-shadow: var(--hledu-glow-primary) !important;
}

.hledu-header-search__icon {
	position: absolute;
	left: 11px;
	top: 50%;
	transform: translateY(-50%);
	color: var(--hledu-text-light);
	font-size: 16px !important;
	width: 16px !important;
	height: 16px !important;
	pointer-events: none;
}

.hledu-header-icon-btn {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	padding: 0;
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius-full);
	background: var(--hledu-bg-card);
	color: var(--hledu-text-muted) !important;
	text-decoration: none !important;
	cursor: pointer;
	flex-shrink: 0;
	transition: background var(--hledu-transition), color var(--hledu-transition), border-color var(--hledu-transition);
}

.hledu-header-icon-btn:hover {
	border-color: var(--hledu-primary);
	color: var(--hledu-primary) !important;
}

.hledu-header-icon-btn .dashicons {
	font-size: 18px !important;
	width: 18px !important;
	height: 18px !important;
}

/* Icon + label header button (e.g. "Frontend View") — same pill language
   as .hledu-header-icon-btn, just sized to fit a text label instead of a
   lone icon. */
.hledu-header-frontend-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	height: 36px;
	padding: 0 14px;
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius-full);
	background: var(--hledu-bg-card);
	color: var(--hledu-text-muted) !important;
	font-size: 13px;
	font-weight: 500;
	white-space: nowrap;
	text-decoration: none !important;
	cursor: pointer;
	flex-shrink: 0;
	transition: background var(--hledu-transition), color var(--hledu-transition), border-color var(--hledu-transition);
}

.hledu-header-frontend-btn:hover {
	border-color: var(--hledu-primary);
	color: var(--hledu-primary) !important;
}

.hledu-header-frontend-btn svg {
	flex-shrink: 0;
}

.hledu-header-badge {
	position: absolute;
	top: -4px;
	right: -4px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 16px;
	height: 16px;
	padding: 0 4px;
	border-radius: var(--hledu-radius-full);
	background: var(--hledu-danger);
	color: #fff;
	font-size: 10px;
	font-weight: 700;
	line-height: 1;
	border: 2px solid var(--hledu-bg-card);
}

.hledu-header-user-wrap {
	position: relative;
	flex-shrink: 0;
}

.hledu-header-user {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 4px 10px 4px 4px;
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius-full);
	background: var(--hledu-bg-card);
	color: var(--hledu-text) !important;
	font-family: var(--hledu-font);
	text-decoration: none !important;
	cursor: pointer;
	flex-shrink: 0;
	outline: none;
}

.hledu-header-user-dropdown {
	display: none;
	position: absolute;
	top: calc(100% + 8px);
	right: 0;
	min-width: 160px;
	padding: 6px;
	background: var(--hledu-bg-card);
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius);
	box-shadow: var(--hledu-shadow-md);
	z-index: 1000;
}

.hledu-header-user-wrap.is-open .hledu-header-user-dropdown {
	display: block;
}

.hledu-header-user-dropdown__item {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 8px 10px;
	border-radius: var(--hledu-radius-sm);
	font-size: 13px;
	font-weight: 600;
	color: var(--hledu-text) !important;
	text-decoration: none !important;
	white-space: nowrap;
}

.hledu-header-user-dropdown__item:hover {
	background: var(--hledu-bg);
}

.hledu-header-user-dropdown__item--logout {
	color: var(--hledu-danger) !important;
}

.hledu-header-user-dropdown__item--logout:hover {
	background: var(--hledu-danger-light);
}

.hledu-header-user__avatar {
	width: 28px;
	height: 28px;
	border-radius: 50%;
	display: block;
}

.hledu-header-user__meta {
	display: flex;
	flex-direction: column;
	line-height: 1.25;
}

.hledu-header-user__name {
	font-size: 12px;
	font-weight: 700;
	color: var(--hledu-text);
}

.hledu-header-user__role {
	font-size: 11px;
	color: var(--hledu-text-muted);
}

.hledu-header-user__chevron {
	font-size: 14px !important;
	width: 14px !important;
	height: 14px !important;
	color: var(--hledu-text-light);
}

/* Visual order in the header actions row, independent of DOM insertion order.
   -1 (rather than 1) so the toggle also sorts before page-specific action
   buttons that have no explicit order (default 0), e.g. "Add New User". */
.hledu-page-header__actions .hledu-theme-toggle {
	order: -1;
}

.hledu-page-header__actions .hledu-header-frontend-btn {
	order: 1;
}

.hledu-page-header__actions .hledu-header-search {
	order: 2;
}

.hledu-page-header__actions .hledu-header-icon-btn {
	order: 3;
}

.hledu-page-header__actions .hledu-header-user-wrap {
	order: 4;
}

.hledu-page-header__actions .hledu-version-badge {
	order: 5;
}

@media (max-width: 1200px) {
	.hledu-header-search__input {
		width: 160px;
	}
}

@media (max-width: 900px) {
	.hledu-header-search {
		display: none;
	}
}

/* "Live data" notice beneath stat grid */
.hledu-dashboard-data-notice {
	display: flex;
	align-items: center;
	gap: 7px;
	margin: -12px 0 20px;
	font-size: 12px;
	color: var(--hledu-text-light);
}

.hledu-dashboard-data-notice .dashicons {
	font-size: 14px !important;
	width: 14px !important;
	height: 14px !important;
}

/* --------------------------------------------------------------------------
   19. Module 05 — Course Builder
   -------------------------------------------------------------------------- */

/* Archived badge (neutral grey — indicates disabled, not failed) */
.hledu-badge--archived {
	background: var(--hledu-border-light);
	color: var(--hledu-text-muted);
}

/* Two-column form layout: main content + sidebar */
.hledu-form-layout {
	display: grid;
	grid-template-columns: 1fr 300px;
	gap: 20px;
	align-items: start;
}

.hledu-form-main {
	min-width: 0;
}

.hledu-form-sidebar {
	min-width: 0;
}

/* Form action buttons row inside card */
.hledu-form-actions {
	display: flex;
	gap: 8px;
	align-items: center;
	justify-content: flex-end;
	padding-top: 12px;
	border-top: 1px solid var(--hledu-border-light);
	margin-top: 8px;
}

/* Thumbnail uploader */
.hledu-thumbnail-wrap {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.hledu-thumbnail-preview {
	width: 100%;
	height: auto;
	border-radius: var(--hledu-radius-sm);
	border: 1px solid var(--hledu-border);
	display: block;
	object-fit: cover;
	max-height: 160px;
}

.hledu-thumbnail-actions {
	display: flex;
	gap: 8px;
	align-items: center;
	flex-wrap: wrap;
}

/* Utility: hidden element */
.hledu-hidden {
	display: none !important;
}

/* Pagination info line below pagination links */
.hledu-pagination-info {
	text-align: center;
	font-size: 12px;
	color: var(--hledu-text-muted);
	margin: 4px 0 0;
}

/* Zero-padding modifier for card body when containing a table */
.hledu-card-body--flush {
	padding: 0;
}

/* Search icon inside .hledu-search-wrap */
.hledu-search-wrap .dashicons {
	position: absolute;
	right: 8px;
	top: 50%;
	transform: translateY(-50%);
	color: var(--hledu-text-light);
	font-size: 16px !important;
	line-height: 1 !important;
	width: 16px !important;
	height: 16px !important;
	pointer-events: none;
}

/* Form sidebar hint paragraph (no extra margin needed) */
.hledu-form-sidebar .hledu-form-hint {
	margin: 0;
}

/* --------------------------------------------------------------------------
   21. Course detail view (action=view)
   -------------------------------------------------------------------------- */
.hledu-course-view-layout {
	display: grid;
	grid-template-columns: 1fr 280px;
	gap: 20px;
	align-items: start;
}

.hledu-course-view-main,
.hledu-course-view-sidebar {
	min-width: 0;
}

.hledu-course-view-thumbnail {
	width: 100%;
	height: auto;
	border-radius: var(--hledu-radius-sm);
	display: block;
	max-height: 320px;
	object-fit: cover;
}

.hledu-course-view-description {
	font-size: 14px;
	line-height: 1.7;
	color: var(--hledu-text);
}

.hledu-course-view-description p {
	margin: 0 0 14px;
}

/* Definition list used in sidebar */
.hledu-detail-list {
	display: grid;
	grid-template-columns: auto 1fr;
	gap: 8px 16px;
	margin: 0;
	font-size: 13px;
}

.hledu-detail-list dt {
	font-weight: 600;
	color: var(--hledu-text-muted);
	white-space: nowrap;
}

.hledu-detail-list dd {
	margin: 0;
	color: var(--hledu-text);
}

/* Full-width button in sidebar */
.hledu-btn--full {
	width: 100%;
	justify-content: center;
}

/* Spacing above the edit action button inside a detail card */
.hledu-detail-edit-action {
	margin-top: 16px;
}

/* --------------------------------------------------------------------------
   23. Course Media (form — tabs, YouTube, gallery)
   -------------------------------------------------------------------------- */

/* Tab strip */
.hledu-media-tabs {
	display: flex;
	gap: 0;
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius-sm);
	overflow: hidden;
	margin-bottom: 12px;
}

.hledu-media-tab {
	flex: 1;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	padding: 7px 10px;
	font-size: 12px;
	font-weight: 600;
	background: var(--hledu-bg);
	border: none;
	border-right: 1px solid var(--hledu-border);
	color: var(--hledu-text-muted);
	cursor: pointer;
	transition: background var(--hledu-transition), color var(--hledu-transition);
}

.hledu-media-tab:last-child {
	border-right: none;
}

.hledu-media-tab:hover {
	background: var(--hledu-primary-light);
	color: var(--hledu-primary);
}

.hledu-media-tab--active {
	background: var(--hledu-primary);
	color: #fff !important;
}

.hledu-media-tab .dashicons {
	font-size: 14px !important;
	width: 14px !important;
	height: 14px !important;
}

/* YouTube pane — spacing above URL input */
#hledu-primary-pane-yt .hledu-form-group {
	margin-bottom: 10px;
}

/* Form label (above the tab strip) */
.hledu-form-label {
	display: block;
	font-size: 12px;
	font-weight: 600;
	color: var(--hledu-text-muted);
	text-transform: uppercase;
	letter-spacing: 0.04em;
	margin: 0 0 8px;
}

/* Gallery grid */
.hledu-gallery-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 6px;
	margin-bottom: 10px;
	min-height: 0;
}

.hledu-gallery-item {
	position: relative;
	aspect-ratio: 1;
	border-radius: var(--hledu-radius-sm);
	overflow: hidden;
	border: 1px solid var(--hledu-border);
}

.hledu-gallery-item img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.hledu-gallery-remove {
	position: absolute;
	top: 2px;
	right: 2px;
	width: 20px;
	height: 20px;
	padding: 0;
	border: none;
	border-radius: 50%;
	background: rgba(0, 0, 0, 0.65);
	color: #fff;
	font-size: 14px;
	line-height: 1;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 0;
	transition: opacity var(--hledu-transition);
}

.hledu-gallery-item:hover .hledu-gallery-remove {
	opacity: 1;
}

/* Primary media preview — wraps the image so the remove icon can float on top */
.hledu-primary-preview-wrap {
	position: relative;
	display: block;
	margin-bottom: 4px;
}

.hledu-primary-preview-wrap:hover .hledu-gallery-remove {
	opacity: 1;
}

/* Sidebar actions card — no divider needed when it's the only thing in the card */
.hledu-form-actions--top {
	padding-top: 0;
	border-top: none;
	margin-top: 0;
}

/* Helper note pinned left, primary action pinned right — vs. the base
   class's flex-end, which bunches everything (note included) at the end. */
.hledu-form-actions--split {
	justify-content: space-between;
}

/* --------------------------------------------------------------------------
   25. Tag picker (searchable multi-select — Assigned Employee / Authors)
   -------------------------------------------------------------------------- */
.hledu-tag-picker {
	position: relative;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px;
	padding: 6px 8px;
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius-sm);
	background: var(--hledu-bg-card);
}

.hledu-tag-picker:focus-within {
	border-color: var(--hledu-primary);
	box-shadow: 0 0 0 3px rgb(37 99 235 / 0.12);
}

.hledu-tag-chips {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
}

.hledu-tag-chip {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 3px 6px 3px 10px;
	background: var(--hledu-primary-light);
	color: var(--hledu-primary);
	border-radius: var(--hledu-radius-full);
	font-size: 12px;
	font-weight: 600;
	max-width: 100%;
	white-space: normal;
	word-break: break-word;
}

.hledu-tag-chip-remove {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 16px;
	height: 16px;
	flex-shrink: 0;
	padding: 0;
	border: none;
	border-radius: 50%;
	background: transparent;
	color: var(--hledu-primary);
	font-size: 14px;
	line-height: 1;
	cursor: pointer;
}

.hledu-tag-chip-remove:hover {
	background: rgb(37 99 235 / 0.15);
}

.hledu-tag-chip--more {
	background: var(--hledu-primary-light);
	color: var(--hledu-primary);
	border: none;
	padding: 3px 10px;
	cursor: pointer;
}

.hledu-tag-chip--more:hover {
	background: rgb(37 99 235 / 0.15);
}

.hledu-tag-search {
	flex: 1 1 100px;
	min-width: 100px;
	border: none;
	outline: none;
	padding: 4px 2px;
	font-size: 13px;
	font-family: var(--hledu-font);
	color: var(--hledu-text);
	background: transparent;
}

.hledu-tag-dropdown {
	position: absolute;
	top: calc(100% + 4px);
	left: 0;
	right: 0;
	z-index: 20;
	max-height: 220px;
	overflow-y: auto;
	background: var(--hledu-bg-card);
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius-sm);
	box-shadow: var(--hledu-shadow-md);
}

.hledu-tag-option {
	padding: 8px 12px;
	font-size: 13px;
	color: var(--hledu-text);
	cursor: pointer;
}

.hledu-tag-option:hover {
	background: var(--hledu-primary-light);
	color: var(--hledu-primary);
}

.hledu-tag-option--empty {
	color: var(--hledu-text-light);
	cursor: default;
}

.hledu-tag-option--empty:hover {
	background: none;
	color: var(--hledu-text-light);
}

/* --------------------------------------------------------------------------
   26. Course view — media stage & gallery strip
   -------------------------------------------------------------------------- */

.hledu-media-stage {
	background: #000;
	border-radius: var(--hledu-radius-sm) var(--hledu-radius-sm) 0 0;
	overflow: hidden;
	line-height: 0;
}

.hledu-media-stage__img {
	width: 100%;
	max-height: 380px;
	object-fit: contain;
	display: block;
	background: #000;
	transition: opacity 0.2s ease;
}

.hledu-media-stage__yt {
	position: relative;
	padding-top: 56.25%;
}

.hledu-media-stage__yt iframe {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: none;
}

.hledu-media-stage__empty {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 40px 20px;
	color: var(--hledu-text-muted);
	font-size: 13px;
	background: var(--hledu-bg-alt);
}

.hledu-media-stage__empty .dashicons {
	font-size: 36px !important;
	width: 36px !important;
	height: 36px !important;
	margin-bottom: 8px;
}

/* Gallery thumbnail strip below the stage */
.hledu-gallery-strip {
	display: flex;
	gap: 4px;
	padding: 6px;
	background: #111;
	border-radius: 0 0 var(--hledu-radius-sm) var(--hledu-radius-sm);
	overflow-x: auto;
}

.hledu-gallery-thumb {
	flex-shrink: 0;
	width: 56px;
	height: 56px;
	padding: 0;
	border: 2px solid transparent;
	border-radius: 3px;
	overflow: hidden;
	cursor: pointer;
	opacity: 0.65;
	transition: opacity var(--hledu-transition), border-color var(--hledu-transition);
	background: none;
}

.hledu-gallery-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.hledu-gallery-thumb:hover {
	opacity: 1;
}

.hledu-gallery-thumb--active {
	border-color: var(--hledu-primary);
	opacity: 1;
}

/* --------------------------------------------------------------------------
   22. Responsive
   -------------------------------------------------------------------------- */
@media (max-width: 1024px) {
	.hledu-stats-row {
		grid-template-columns: repeat(3, 1fr);
	}
}

@media (max-width: 782px) {
	.hledu-stats-row {
		grid-template-columns: repeat(2, 1fr);
	}

	.hledu-toolbar {
		flex-direction: column;
		align-items: flex-start;
	}

	.hledu-search-input {
		width: 100%;
		min-width: unset;
	}

	.hledu-bulk-actions-wrap {
		width: 100%;
	}

	.hledu-modal {
		max-width: 100%;
	}
}

@media (max-width: 480px) {
	.hledu-stats-row {
		grid-template-columns: 1fr;
	}

	.hledu-page-header {
		flex-wrap: wrap;
	}
}

/* --------------------------------------------------------------------------
   Activity log — read / unread states & row interactions
   -------------------------------------------------------------------------- */

/* Clickable rows */
.hledu-activity-row {
	cursor: pointer;
	transition: background 0.12s;
}

/* Unread = same shade as the hover state so it stands out */
.hledu-activity-row--unread td {
	background: var(--hledu-bg);
	font-weight: 600;
}

/* Override the generic hover so unread rows get the same hover feel */
.hledu-activity-table tbody tr.hledu-activity-row--unread:hover td,
.hledu-activity-table tbody tr.hledu-activity-row--read:hover td {
	background: #e9edf2;
}

/* Read rows — muted */
.hledu-activity-row--read td {
	color: var(--hledu-text-muted);
	font-weight: 400;
}

/* Narrow actions column — no header text */
.hledu-activity-th-actions {
	width: 72px;
	text-align: right;
	padding-right: 14px !important;
}

.hledu-activity-actions-cell {
	text-align: right;
	padding-right: 14px !important;
}

/* Action button group */
.hledu-activity-actions {
	display: inline-flex;
	align-items: center;
	gap: 4px;
}

/* Shared icon-button base */
.hledu-activity-check,
.hledu-activity-delete {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	border: none;
	border-radius: 6px;
	background: transparent;
	cursor: pointer;
	padding: 0;
	transition: background 0.15s, opacity 0.15s, color 0.15s;
}

/* Checkmark — full opacity when read, dim when unread */
.hledu-activity-check {
	color: var(--hledu-success, #16a34a);
}

.hledu-activity-row--unread .hledu-activity-check {
	opacity: 0.22;
}

.hledu-activity-row--read .hledu-activity-check {
	opacity: 1;
}

.hledu-activity-check:hover {
	opacity: 1 !important;
	background: var(--hledu-success-light, #f0fdf4);
}

/* Trash — hidden until row hover */
.hledu-activity-delete {
	color: var(--hledu-danger);
	opacity: 0;
}

.hledu-activity-row:hover .hledu-activity-delete {
	opacity: 0.55;
}

.hledu-activity-delete:hover {
	opacity: 1 !important;
	background: var(--hledu-danger-light, #fef2f2);
}

/* Header-row "mark all read" / "delete all" — same icon-button base as the
   per-row actions above, but always visible since they aren't tied to a
   specific row's read/hover state. */
.hledu-activity-check-all,
.hledu-activity-delete-all {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	border: none;
	border-radius: 6px;
	background: transparent;
	cursor: pointer;
	padding: 0;
	transition: background 0.15s, opacity 0.15s, color 0.15s;
}

.hledu-activity-check-all {
	color: var(--hledu-success, #16a34a);
}

.hledu-activity-check-all:hover {
	background: var(--hledu-success-light, #f0fdf4);
}

.hledu-activity-delete-all {
	color: var(--hledu-danger);
}

.hledu-activity-delete-all:hover {
	background: var(--hledu-danger-light, #fef2f2);
}

/* Delete animation */
.hledu-activity-row--removing {
	pointer-events: none;
	opacity: 0.5;
}

.hledu-activity-other {
	color: var(--hledu-text-muted);
	font-style: italic;
	font-size: 12px;
}

/* --------------------------------------------------------------------------
   20. Module: Bulk User Upload — progress bar
   -------------------------------------------------------------------------- */
.hledu-progress-track {
	width: 100%;
	height: 10px;
	background: var(--hledu-border-light);
	border-radius: var(--hledu-radius-full);
	overflow: hidden;
}

.hledu-progress-fill {
	height: 100%;
	width: 0%;
	background: var(--hledu-primary);
	border-radius: var(--hledu-radius-full);
	transition: width 0.25s ease;
}

.hledu-progress-fill--done {
	background: var(--hledu-success);
}

.hledu-progress-label {
	margin-top: 6px;
	margin-bottom: 0;
	font-size: 12px;
	color: var(--hledu-text-light);
	text-align: center;
}

/* --------------------------------------------------------------------------
   21. Module: Modules & Lessons Manager (accordion, drag-drop)
   -------------------------------------------------------------------------- */
.hledu-accordion {
	display: flex;
	flex-direction: column;
	gap: 10px;
	margin-top: 16px;
}

.hledu-accordion-item {
	background: var(--hledu-bg-card);
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius);
	box-shadow: var(--hledu-shadow-xs);
}

.hledu-accordion-item.is-dragging,
.hledu-lesson-row.is-dragging {
	opacity: 0.4;
}

.hledu-accordion-header {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 12px 16px;
}

.hledu-drag-handle {
	cursor: grab;
	color: var(--hledu-text);
}

.hledu-drag-handle:active {
	cursor: grabbing;
}

.hledu-accordion-toggle {
	flex: 1;
	display: flex;
	align-items: center;
	gap: 8px;
	background: none;
	border: none;
	padding: 0;
	font-size: 14px;
	font-weight: 600;
	color: var(--hledu-text);
	cursor: pointer;
	text-align: left;
}

.hledu-accordion-toggle:focus,
.hledu-quiz-item-toggle:focus,
.hledu-quiz-question-item-toggle:focus {
	outline: none;
}

.hledu-accordion-actions .dashicons-arrow-down-alt2 {
	transition: transform var(--hledu-transition);
	color: var(--hledu-text-light);
}

.hledu-accordion-item.is-open .hledu-accordion-actions .dashicons-arrow-down-alt2 {
	transform: rotate(-180deg);
}

.hledu-accordion-actions {
	display: flex;
	align-items: center;
	gap: 6px;
	flex-shrink: 0;
}

.hledu-accordion-body {
	display: none;
	padding: 0 16px 16px 40px;
	border-top: 1px solid var(--hledu-border-light);
}

.hledu-accordion-item.is-open .hledu-accordion-body {
	display: block;
	padding-top: 16px;
}

.hledu-module-description {
	margin: 0 0 12px;
	font-size: 13px;
	color: var(--hledu-text-muted);
}

.hledu-lessons-list {
	display: flex;
	flex-direction: column;
	gap: 6px;
	margin-bottom: 12px;
}

.hledu-lesson-row {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 8px 12px;
	background: var(--hledu-bg);
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius-sm);
}

.hledu-lesson-row .dashicons-video-alt3,
.hledu-lesson-row .dashicons-media-document,
.hledu-lesson-row .dashicons-media-text {
	color: var(--hledu-text-muted);
}

.hledu-lesson-title {
	flex: 1;
	font-size: 13px;
	color: var(--hledu-text);
	cursor: pointer;
}

.hledu-lesson-actions {
	display: flex;
	align-items: center;
	gap: 6px;
	flex-shrink: 0;
}

.hledu-inline-form {
	margin: 10px 0;
}

/* ── Quiz builder (Module 08) ────────────────────────────────────────────── */
.hledu-answer-row {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 6px;
}

.hledu-answer-row .hledu-answer-row-text {
	flex: 1;
}

.hledu-answer-review-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 4px;
}

.hledu-answer-review-list li {
	display: flex;
	align-items: center;
	gap: 6px;
	padding: 6px 10px;
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius-sm);
	color: var(--hledu-text);
}

.hledu-answer-review-list__item--correct {
	border-color: var(--hledu-success);
	background: var(--hledu-success-light);
	color: var(--hledu-success);
}

/* ── Quizzes nested inside a module (Module & Lesson manager) — deliberately
   distinct class names from .hledu-accordion-* so they never collide with
   admin/js/hledu-lesson-manager.js's module drag-reorder / toggle listeners. ── */
.hledu-module-actions-row {
	display: flex;
	gap: 8px;
	margin-top: 10px;
}

.hledu-quiz-items-list {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin-top: 12px;
}

/* Combined lesson+quiz list — built client-side by moving the already-bound
   .hledu-lesson-row / .hledu-quiz-item elements out of their original
   (now-empty) containers into one interleaved, drag-reorderable sequence. */
.hledu-module-content-list {
	display: flex;
	flex-direction: column;
	gap: 6px;
	margin-bottom: 12px;
}

.hledu-quiz-item {
	background: var(--hledu-bg-card);
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius);
}

.hledu-quiz-item-header {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 10px 14px;
}

.hledu-quiz-item-toggle {
	flex: 1;
	display: flex;
	align-items: center;
	gap: 8px;
	background: none;
	border: none;
	padding: 0;
	font-size: 14px;
	font-weight: 600;
	color: var(--hledu-text);
	cursor: pointer;
	text-align: left;
}

.hledu-quiz-item-actions .dashicons-arrow-down-alt2 {
	transition: transform var(--hledu-transition);
	color: var(--hledu-text-light);
}

.hledu-quiz-item.is-open .hledu-quiz-item-actions .dashicons-arrow-down-alt2 {
	transform: rotate(-180deg);
}

.hledu-quiz-item-actions {
	display: flex;
	align-items: center;
	gap: 6px;
	flex-shrink: 0;
}

.hledu-quiz-item-body {
	display: none;
	padding: 0 14px 14px 36px;
	border-top: 1px solid var(--hledu-border-light);
}

.hledu-quiz-item.is-open .hledu-quiz-item-body {
	display: block;
	padding-top: 14px;
}

.hledu-quiz-item-meta {
	color: var(--hledu-text-muted);
	font-size: 13px;
	margin: 0 0 10px;
}

/* ── Questions embedded inline inside a quiz item (Module 08) ────────────── */
.hledu-quiz-question-list {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin-bottom: 10px;
}

.hledu-quiz-question-item {
	background: var(--hledu-bg-card);
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius-sm);
	padding: 10px 12px;
}

.hledu-quiz-question-item-header {
	display: flex;
	align-items: center;
	gap: 8px;
}

.hledu-quiz-question-item-toggle {
	flex: 1;
	display: flex;
	align-items: center;
	gap: 8px;
	background: none;
	border: none;
	padding: 0;
	cursor: pointer;
	text-align: left;
}

.hledu-quiz-question-item-actions .dashicons-arrow-down-alt2 {
	transition: transform var(--hledu-transition);
	color: var(--hledu-text-light);
}

.hledu-quiz-question-item.is-open .hledu-quiz-question-item-actions .dashicons-arrow-down-alt2 {
	transform: rotate(-180deg);
}

.hledu-quiz-question-item-actions {
	display: flex;
	align-items: center;
	gap: 6px;
	flex-shrink: 0;
}

.hledu-quiz-question-item-body {
	display: none;
}

.hledu-quiz-question-item.is-open .hledu-quiz-question-item-body {
	display: block;
	margin-top: 8px;
}

.hledu-quiz-question-item-text {
	flex: 1;
	font-weight: 600;
	color: var(--hledu-text);
}

/*
 * The row/item these titles sit in has draggable="true" for reordering, and
 * browsers make draggable elements non-selectable by default (so a
 * click-drag reliably moves the element instead of selecting its text).
 * That default reaches into these title buttons too, so a click-drag over
 * the title text can't select it. Opt just the title text back into normal
 * selection and stop it from starting a native drag itself — dragging from
 * elsewhere in the row (e.g. the drag handle) is unaffected.
 */
.hledu-accordion-title-text,
.hledu-quiz-item-title,
.hledu-quiz-question-item-text {
	user-select: text;
	-webkit-user-drag: none;
}

.hledu-lesson-edit-slot {
	margin-bottom: 6px;
}

/* --------------------------------------------------------------------------
   27. Bento/Glass design system — Module 06B
   -------------------------------------------------------------------------- */

/* ── Bento grid ──────────────────────────────────────────────────────────── */
.hledu-bento {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	grid-auto-rows: minmax(120px, auto);
	gap: 16px;
	margin-bottom: 24px;
}

/* Opt-in modifier for a row that must hold 5 equal cards (e.g. the Super
   Admin dashboard's stat cards) without changing the default 4-column
   .hledu-bento grid used elsewhere. */
.hledu-bento--cols-5 {
	grid-template-columns: repeat(5, 1fr);
}

.hledu-bento-card {
	grid-column: span 1;
	display: flex;
	flex-direction: column;
	gap: 10px;
	padding: 20px;
	border-radius: var(--hledu-radius-lg);
	background: var(--hledu-surface);
	border: 1px solid var(--hledu-border);
	box-shadow: var(--hledu-shadow-xs);
}

.hledu-bento-card--wide {
	grid-column: span 2;
}

.hledu-bento-card--tall {
	grid-row: span 2;
}

.hledu-bento-card--large {
	grid-column: span 2;
	grid-row: span 2;
}

/* Notice/activity card — spans the full row, holds a scrollable list */
.hledu-bento-card--notice {
	grid-column: 1 / -1;
	display: flex;
	flex-direction: column;
	padding: 0;
	overflow: hidden;
}

.hledu-bento-card--notice .hledu-bento-card__header {
	padding: 16px 20px;
	border-bottom: 1px solid var(--hledu-border);
}

.hledu-bento-card__header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
}

.hledu-bento-card__header h2,
.hledu-bento-card__header h3 {
	margin: 0;
	font-size: 14px;
	font-weight: 700;
	color: var(--hledu-text);
	text-transform: uppercase;
	letter-spacing: 0.5px;
}

.hledu-bento-card__icon {
	font-size: 26px !important;
	width: 26px !important;
	height: 26px !important;
	color: var(--hledu-primary);
}

.hledu-bento-card__value {
	font-size: 28px;
	font-weight: 800;
	color: var(--hledu-text);
	line-height: 1;
}

.hledu-bento-card__label {
	font-size: 12px;
	font-weight: 600;
	color: var(--hledu-text-muted);
	text-transform: uppercase;
	letter-spacing: 0.4px;
}

/* ── Glass modifier — bento dashboard cards + modals only ───────────────── */
.hledu-card--glass {
	background: var(--hledu-surface-glass);
	backdrop-filter: blur(var(--hledu-blur));
	-webkit-backdrop-filter: blur(var(--hledu-blur));
	border: 1px solid rgb(255 255 255 / 0.18);
	box-shadow: var(--hledu-shadow-glass);
}

[data-hledu-theme="dark"] .hledu-card--glass {
	border-color: rgb(255 255 255 / 0.08);
}

/* ── Gradient primary button ─────────────────────────────────────────────── */
.hledu-btn-primary {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 9px 18px;
	border: none;
	border-radius: var(--hledu-radius-sm);
	font-size: 13px;
	font-weight: 700;
	font-family: var(--hledu-font);
	color: #fff !important;
	cursor: pointer;
	text-decoration: none !important;
	background-image: var(--hledu-gradient-primary);
	background-size: 200% 100%;
	background-position: 0 0;
	transition: background-position var(--hledu-transition-slow), box-shadow var(--hledu-transition);
}

.hledu-btn-primary:hover,
.hledu-btn-primary:focus-visible {
	background-position: 100% 0;
	box-shadow: var(--hledu-glow-primary);
}

.hledu-btn-secondary {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 9px 18px;
	background: var(--hledu-surface);
	color: var(--hledu-text) !important;
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius-sm);
	font-size: 13px;
	font-weight: 600;
	font-family: var(--hledu-font);
	cursor: pointer;
	text-decoration: none !important;
	transition: background var(--hledu-transition), border-color var(--hledu-transition);
}

.hledu-btn-secondary:hover {
	background: var(--hledu-bg);
	border-color: var(--hledu-text-muted);
}

.hledu-btn-tertiary {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 9px 14px;
	background: transparent;
	color: var(--hledu-primary) !important;
	border: 1px solid transparent;
	border-radius: var(--hledu-radius-sm);
	font-size: 13px;
	font-weight: 600;
	font-family: var(--hledu-font);
	cursor: pointer;
	text-decoration: none !important;
	transition: background var(--hledu-transition);
}

.hledu-btn-tertiary:hover {
	background: var(--hledu-primary-light);
}

/* ── Floating label form pattern ─────────────────────────────────────────── */
/* JS toggles .is-active on .hledu-form-group--floating when the field has
   focus or a non-empty value — works regardless of label/input DOM order. */
.hledu-form-group--floating {
	position: relative;
	padding-top: 18px;
}

/* Anchored a fixed distance from the group's top edge (roughly the resting
   vertical center of a standard input) rather than 50% of the group's total
   height, so a hint/error line below the field doesn't pull the label down. */
.hledu-form-group--floating label {
	position: absolute;
	left: 13px;
	top: 36px;
	transform: translateY(-50%);
	margin: 0;
	padding: 0 4px;
	font-size: 13px;
	font-weight: 500;
	color: var(--hledu-text-light);
	background: var(--hledu-surface);
	pointer-events: none;
	transition: top var(--hledu-transition), font-size var(--hledu-transition), color var(--hledu-transition);
}

.hledu-form-group--floating .hledu-input,
.hledu-form-group--floating .hledu-select,
.hledu-form-group--floating .hledu-textarea {
	background: var(--hledu-surface);
}

.hledu-form-group--floating.is-active label {
	top: 6px;
	left: -2px;
	transform: translateY(-50%);
	font-size: 11px;
	font-weight: 700;
	color: var(--hledu-primary);
}

/* When the field has a leading icon (.hledu-input-icon-wrap), the resting
   label sat at the same left offset as the icon and was hidden behind it —
   move it clear of the icon at rest; once floated up it's above the icon's
   row so it can return to the normal left offset. */
.hledu-form-group--floating:has(.hledu-input-icon-wrap) label {
	left: 38px;
}

.hledu-form-group--floating.is-active:has(.hledu-input-icon-wrap) label {
	left: -2px;
}

/* ── Motion — fade/slide entrance ─────────────────────────────────────────── */
@keyframes hledu-fade-slide-in {
	from {
		opacity: 0;
		transform: translateY(8px);
	}

	to {
		opacity: 1;
		transform: translateY(0);
	}
}

@keyframes hledu-fade-slide-out {
	from {
		opacity: 1;
		transform: translateY(0);
	}

	to {
		opacity: 0;
		transform: translateY(8px);
	}
}

.hledu-fade-slide-in {
	animation: hledu-fade-slide-in 220ms ease-out;
}

.hledu-fade-slide-out {
	animation: hledu-fade-slide-out 220ms ease-out;
}

.hledu-wrap {
	animation: hledu-fade-slide-in 220ms ease-out;
}

/* ── Distraction-Free Mode (scaffolded here, wired in Module 16) ─────────── */
body.hledu-focus-mode #wpadminbar,
body.hledu-focus-mode #adminmenumain,
body.hledu-focus-mode #wpfooter {
	display: none !important;
}

body.hledu-focus-mode #wpcontent,
body.hledu-focus-mode #wpbody-content {
	margin-left: 0 !important;
}

/* ── Skeleton loading shimmer ─────────────────────────────────────────────── */
.hledu-skeleton {
	position: relative;
	overflow: hidden;
	background: var(--hledu-border-light);
	border-radius: var(--hledu-radius-sm);
	color: transparent !important;
}

.hledu-skeleton::after {
	content: "";
	position: absolute;
	inset: 0;
	transform: translateX(-100%);
	background-image: linear-gradient(90deg, transparent, rgb(255 255 255 / 0.35), transparent);
	animation: hledu-skeleton-shimmer 1.4s ease-in-out infinite;
}

[data-hledu-theme="dark"] .hledu-skeleton::after {
	background-image: linear-gradient(90deg, transparent, rgb(255 255 255 / 0.08), transparent);
}

@keyframes hledu-skeleton-shimmer {
	100% {
		transform: translateX(100%);
	}
}

/* ── Progress ring — output of hledu_render_progress_ring() ──────────────── */
.hledu-ring {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	position: relative;
}

.hledu-ring svg {
	transform: rotate(-90deg);
}

.hledu-ring-track {
	stroke: var(--hledu-border);
	fill: none;
}

.hledu-ring-fill {
	stroke: var(--hledu-primary);
	fill: none;
	stroke-linecap: round;
	transition: stroke-dashoffset var(--hledu-transition-slow);
}

.hledu-ring__label {
	position: absolute;
	font-size: 13px;
	font-weight: 700;
	color: var(--hledu-text);
}

/* ── Reduced motion — disable animation, keep the instant end state ──────── */
@media (prefers-reduced-motion: reduce) {

	.hledu-wrap,
	.hledu-fade-slide-in,
	.hledu-fade-slide-out,
	.hledu-skeleton::after {
		animation: none !important;
	}

	html,
	.hledu-btn-primary,
	.hledu-ring-fill {
		transition: none !important;
	}
}

/* ── Bento responsive ──────────────────────────────────────────────────────── */
@media (max-width: 1024px) {
	.hledu-bento {
		grid-template-columns: repeat(2, 1fr);
	}

	.hledu-bento--cols-5 {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 480px) {
	.hledu-bento {
		grid-template-columns: 1fr;
	}

	.hledu-bento--cols-5 {
		grid-template-columns: 1fr;
	}

	.hledu-bento-card--wide,
	.hledu-bento-card--large {
		grid-column: span 1;
	}
}

/* ── Theme toggle switch (injected by hledu-admin.js) ─────────────────────── */
.hledu-theme-toggle {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	padding: 0;
	border: 1px solid var(--hledu-border);
	border-radius: var(--hledu-radius-full);
	background: var(--hledu-bg-card);
	color: var(--hledu-text-muted);
	cursor: pointer;
	flex-shrink: 0;
	transition: background var(--hledu-transition), color var(--hledu-transition), border-color var(--hledu-transition);
}

.hledu-theme-toggle:hover {
	border-color: var(--hledu-primary);
	color: var(--hledu-primary);
}

.hledu-theme-toggle svg {
	width: 16px;
	height: 16px;
}

.hledu-theme-toggle .hledu-theme-toggle__sun {
	display: block !important;
}

.hledu-theme-toggle .hledu-theme-toggle__moon {
	display: none !important;
}

[data-hledu-theme="dark"] .hledu-theme-toggle .hledu-theme-toggle__sun {
	display: none !important;
}

[data-hledu-theme="dark"] .hledu-theme-toggle .hledu-theme-toggle__moon {
	display: block !important;
}