/* ── Post Types & Taxonomy shared layout ──────────────────── */
#wpcontent { padding-left: 0 !important; }

/* ── Page header ─────────────────────────────────────────── */
.cpt-page-header {
	display: flex;
	align-items: center;
	gap: 14px;
	padding: 18px 28px;
	background: #fff;
	border-bottom: 1px solid #e2e6ed;
}

.cpt-page-header-icon {
	width: 44px;
	height: 44px;
	border-radius: 11px;
	background: linear-gradient(135deg, #5F4AFE 0%, #3362FF 100%);
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
}

.cpt-page-header--pink .cpt-page-header-icon {
	background: linear-gradient(135deg, #e91e8c 0%, #5F4AFE 100%);
}

.cpt-page-header-icon .dashicons {
	font-size: 22px;
	width: 22px;
	height: 22px;
	color: #fff;
}

/* Brand logo replaces the gradient dashicon badge in the page header. */
.cpt-page-header-icon.has-logo,
.cpt-page-header--pink .cpt-page-header-icon.has-logo {
	background: none;
	border-radius: 0;
}
.cpt-page-header-logo {
	display: block;
	width: 44px;
	height: 44px;
	object-fit: contain;
}

.cpt-page-header-title h1 {
	font-size: 17px;
	font-weight: 700;
	color: #010F1C;
	margin: 0 0 2px;
}

.cpt-page-header-title p {
	font-size: 12px;
	color: #5b6470;
	margin: 0;
}

/* ── Two-column layout ───────────────────────────────────── */
.cpt-layout {
	display: grid;
	grid-template-columns: 1fr 300px;
	min-height: calc(100vh - 140px);
	background: #f4f6fb;
}

/* ── LEFT: main area ─────────────────────────────────────── */
.cpt-main {
	padding: 32px;
	display: flex;
	flex-direction: column;
}

/* ── Welcome screen ──────────────────────────────────────── */
.cpt-welcome {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 24px;
	max-width: 560px;
}

.cpt-welcome-hero {
	display: flex;
	align-items: center;
	gap: 16px;
}

.cpt-welcome-hero-icon {
	width: 64px;
	height: 64px;
	border-radius: 16px;
	background: linear-gradient(135deg, #5F4AFE 0%, #3362FF 100%);
	display: flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 8px 24px rgba(95,74,254,.3);
	flex-shrink: 0;
}

.tax-page .cpt-welcome-hero-icon {
	background: linear-gradient(135deg, #e91e8c 0%, #5F4AFE 100%);
	box-shadow: 0 8px 24px rgba(233,30,140,.25);
}

.cpt-welcome-hero-icon .dashicons {
	font-size: 28px;
	width: 28px;
	height: 28px;
	color: #fff;
}

.cpt-welcome-hero-text h2 {
	font-size: 24px;
	font-weight: 800;
	color: #010F1C;
	letter-spacing: -.3px;
	margin: 0 0 6px;
}

.cpt-welcome-hero-text p {
	font-size: 14px;
	color: #5b6470;
	margin: 0;
	line-height: 1.5;
}

/* Feature pills */
.cpt-welcome-features {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 10px;
	width: 100%;
}

.cpt-feature {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 12px 14px;
	background: #fff;
	border: 1.5px solid #e2e6ed;
	border-radius: 8px;
}

.cpt-feature-icon {
	width: 34px;
	height: 34px;
	border-radius: 8px;
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
}

.cpt-feature-icon .dashicons { font-size: 16px; width: 16px; height: 16px; }

.cpt-feature-icon--blue   { background: #e8eeff; color: #3362FF; }
.cpt-feature-icon--purple { background: #ede9ff; color: #5F4AFE; }
.cpt-feature-icon--green  { background: #e6f4ed; color: #1a8455; }
.cpt-feature-icon--orange { background: #fff3e6; color: #c05621; }
.cpt-feature-icon--pink   { background: #fff0f6; color: #e91e8c; }

.cpt-feature-text strong {
	display: block;
	font-size: 12px;
	font-weight: 700;
	color: #010F1C;
	margin-bottom: 1px;
}

.cpt-feature-text span {
	font-size: 11px;
	color: #5b6470;
}

/* CTA button */
.cpt-create-btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 12px 28px;
	font-size: 14px;
	font-weight: 600;
	border-radius: 50px;
	border: none;
	background: linear-gradient(135deg, #5F4AFE 0%, #3362FF 100%);
	color: #fff;
	cursor: pointer;
	box-shadow: 0 6px 20px rgba(95,74,254,.32);
	transition: transform .15s, box-shadow .15s;
	font-family: inherit;
}

.tax-page .cpt-create-btn {
	background: linear-gradient(135deg, #e91e8c 0%, #5F4AFE 100%);
	box-shadow: 0 6px 20px rgba(233,30,140,.28);
}

.cpt-create-btn:hover {
	transform: translateY(-2px);
	box-shadow: 0 10px 28px rgba(95,74,254,.4);
}

.cpt-create-btn .dashicons { font-size: 18px; width: 18px; height: 18px; }

/* ── RIGHT: sidebar ──────────────────────────────────────── */
.cpt-sidebar {
	background: #fff;
	border-left: 1px solid #e2e6ed;
	display: flex;
	flex-direction: column;
	overflow: hidden;
}

.cpt-sidebar-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 14px 16px;
	border-bottom: 1px solid #e2e6ed;
	background: #fafbfd;
}

.cpt-sidebar-header h3 {
	font-size: 12px;
	font-weight: 700;
	letter-spacing: .05em;
	text-transform: uppercase;
	color: #5b6470;
	margin: 0;
}

.cpt-count {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 22px;
	height: 22px;
	padding: 0 6px;
	border-radius: 50px;
	background: #5F4AFE;
	color: #fff;
	font-size: 11px;
	font-weight: 700;
}

.cpt-sidebar--pink .cpt-count { background: #e91e8c; }

.cpt-sidebar-list { flex: 1; overflow-y: auto; padding: 6px; }

.cpt-sidebar-empty {
	display: flex;
	flex-direction: column;
	align-items: center;
	padding: 32px 16px;
	text-align: center;
	gap: 8px;
	color: #c8d0d9;
}

.cpt-sidebar-empty .dashicons { font-size: 28px; width: 28px; height: 28px; }
.cpt-sidebar-empty p { font-size: 12px; color: #a8b4bf; margin: 0; }

/* Sidebar item */
.cpt-item {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 10px 10px;
	border-radius: 7px;
	cursor: pointer;
	transition: background .15s;
}

.cpt-item:hover { background: #f4f6fb; }
.cpt-item.is-active { background: #ede9ff; }
.tax-page .cpt-item.is-active { background: #fff0f6; }

.cpt-item-icon {
	width: 32px;
	height: 32px;
	border-radius: 7px;
	background: #ede9ff;
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
}

.tax-page .cpt-item-icon { background: #fff0f6; }

.cpt-item-icon .dashicons {
	font-size: 16px;
	width: 16px;
	height: 16px;
	color: #5F4AFE;
}

.tax-page .cpt-item-icon .dashicons { color: #e91e8c; }

.cpt-item-info { flex: 1; min-width: 0; }

.cpt-item-name {
	font-size: 13px;
	font-weight: 600;
	color: #010F1C;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.cpt-item-slug {
	font-size: 10px;
	color: #5b6470;
	font-family: ui-monospace, Menlo, Consolas, monospace;
}

.cpt-item-actions {
	display: flex;
	gap: 2px;
	opacity: 0;
	transition: opacity .15s;
}

.cpt-item:hover .cpt-item-actions { opacity: 1; }

.cpt-item-actions button {
	width: 26px;
	height: 26px;
	border: 0;
	background: none;
	border-radius: 5px;
	cursor: pointer;
	color: #5b6470;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background .15s, color .15s;
}

.cpt-item-actions button:hover { background: rgba(0,0,0,.06); }
.cpt-item-actions .cpt-del:hover { background: #fbeaea; color: #d63638; }
.cpt-item-actions button .dashicons { font-size: 14px; width: 14px; height: 14px; }

/* ── Loader overlay ──────────────────────────────────────── */
.cpt-loader {
	position: fixed;
	inset: 0;
	z-index: 99999;
	background: rgba(255,255,255,.92);
	backdrop-filter: blur(6px);
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 0;
	pointer-events: none;
	transition: opacity .3s ease;
}

.cpt-loader.is-active {
	opacity: 1;
	pointer-events: all;
}

.cpt-loader-inner {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 20px;
}

.cpt-loader-ring {
	width: 52px;
	height: 52px;
	border-radius: 50%;
	border: 3px solid rgba(95,74,254,.15);
	border-top-color: #5F4AFE;
	animation: cptSpin .8s linear infinite;
}

.cpt-loader-ring--pink {
	border-color: rgba(233,30,140,.15);
	border-top-color: #e91e8c;
}

@keyframes cptSpin { to { transform: rotate(360deg); } }

.cpt-loader-text {
	font-size: 14px;
	font-weight: 500;
	color: #5b6470;
	margin: 0;
	transition: opacity .25s;
}

.cpt-loader-text.is-fading { opacity: 0; }

/* ── Multi-step form ─────────────────────────────────────── */
.cpt-form-screen {
	display: flex;
	flex-direction: column;
	gap: 0;
	flex: 1;
}

/* Form header with back + steps */
.cpt-form-header {
	display: flex;
	align-items: center;
	gap: 16px;
	margin-bottom: 28px;
}

.cpt-back-btn {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	padding: 7px 14px;
	font-size: 12px;
	font-weight: 600;
	border: 1.5px solid #e2e6ed;
	border-radius: 50px;
	background: #fff;
	color: #5b6470;
	cursor: pointer;
	transition: all .15s;
	font-family: inherit;
	white-space: nowrap;
}

.cpt-back-btn:hover {
	border-color: #5F4AFE;
	color: #5F4AFE;
	background: #ede9ff;
}

.tax-page .cpt-back-btn:hover { border-color: #e91e8c; color: #e91e8c; background: #fff0f6; }

.cpt-form-title { font-size: 20px; font-weight: 800; color: #010F1C; margin: 0; }

/* Step indicator */
.cpt-steps {
	display: flex;
	align-items: center;
	gap: 0;
	margin-left: auto;
}

.cpt-step-indicator {
	display: flex;
	align-items: center;
}

.cpt-step-num {
	width: 28px;
	height: 28px;
	border-radius: 50%;
	border: 2px solid #e2e6ed;
	background: #fff;
	color: #a8b4bf;
	font-size: 11px;
	font-weight: 700;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: all .2s;
}

.cpt-step-num.is-active {
	border-color: #5F4AFE;
	background: #5F4AFE;
	color: #fff;
}

.tax-page .cpt-step-num.is-active { border-color: #e91e8c; background: #e91e8c; }

.cpt-step-num.is-done {
	border-color: #1a8455;
	background: #1a8455;
	color: #fff;
}

.cpt-step-line {
	width: 28px;
	height: 2px;
	background: #e2e6ed;
	transition: background .2s;
}

.cpt-step-line.is-done { background: #1a8455; }

.cpt-step-label {
	font-size: 9px;
	font-weight: 600;
	letter-spacing: .04em;
	text-transform: uppercase;
	color: #a8b4bf;
	text-align: center;
	margin-top: 3px;
}

/* Form body — step panels */
.cpt-form-body {
	background: #fff;
	border: 1.5px solid #e2e6ed;
	border-radius: 10px;
	overflow: hidden;
	flex: 1;
}

.cpt-step-panel {
	display: none;
	padding: 28px;
	animation: cptFadeIn .25s ease;
}

.cpt-step-panel.is-active { display: block; }

@keyframes cptFadeIn {
	from { opacity: 0; transform: translateY(8px); }
	to   { opacity: 1; transform: translateY(0); }
}

.cpt-step-panel h3 {
	font-size: 14px;
	font-weight: 700;
	color: #010F1C;
	margin: 0 0 6px;
}

.cpt-step-panel .cpt-step-desc {
	font-size: 12px;
	color: #5b6470;
	margin: 0 0 22px;
}

/* Form grid */
.cpt-form-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.cpt-form-grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; }

/* Form row */
.cpt-form-row { margin-bottom: 18px; }
.cpt-form-row label {
	display: block;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: .05em;
	text-transform: uppercase;
	color: #5b6470;
	margin-bottom: 6px;
}

.cpt-form-row input[type="text"],
.cpt-form-row input[type="number"],
.cpt-form-row textarea,
.cpt-form-row select {
	width: 100%;
	height: 40px;
	padding: 0 12px;
	border: 1.5px solid #e2e6ed;
	border-radius: 7px;
	font-size: 13px;
	color: #010F1C;
	background: #fafbfd;
	box-shadow: none;
	outline: none;
	font-family: inherit;
	box-sizing: border-box;
	transition: border-color .15s, box-shadow .15s;
}

.cpt-form-row textarea { height: 80px; padding: 10px 12px; resize: vertical; line-height: 1.5; }

.cpt-form-row input:focus,
.cpt-form-row textarea:focus,
.cpt-form-row select:focus {
	border-color: #5F4AFE;
	box-shadow: 0 0 0 3px rgba(95,74,254,.1);
	background: #fff;
}

.tax-page .cpt-form-row input:focus,
.tax-page .cpt-form-row textarea:focus,
.tax-page .cpt-form-row select:focus {
	border-color: #e91e8c;
	box-shadow: 0 0 0 3px rgba(233,30,140,.1);
}

.cpt-form-hint { font-size: 11px; color: #a8b4bf; margin: 4px 0 0; }

.cpt-mono { font-family: ui-monospace, Menlo, Consolas, monospace !important; }

/* Toggle switches */
.cpt-toggles-grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 10px;
}

.cpt-toggle-item {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 12px 14px;
	background: #fafbfd;
	border: 1.5px solid #e2e6ed;
	border-radius: 8px;
	gap: 12px;
	transition: border-color .15s;
}

.cpt-toggle-item:hover { border-color: #c8d6ff; }

.cpt-toggle-info strong { display: block; font-size: 12px; color: #010F1C; }
.cpt-toggle-info span  { font-size: 10px; color: #a8b4bf; }

/* Toggle switch visual */
.cpt-toggle {
	position: relative;
	width: 40px;
	height: 22px;
	flex-shrink: 0;
}

.cpt-toggle input { display: none; }

.cpt-toggle-slider {
	position: absolute;
	inset: 0;
	border-radius: 11px;
	background: #d1d9e0;
	cursor: pointer;
	transition: background .22s;
}

.cpt-toggle-slider::before {
	content: '';
	position: absolute;
	top: 3px;
	left: 3px;
	width: 16px;
	height: 16px;
	border-radius: 50%;
	background: #fff;
	box-shadow: 0 1px 3px rgba(0,0,0,.2);
	transition: left .2s;
}

.cpt-toggle input:checked + .cpt-toggle-slider { background: #5F4AFE; }
.tax-page .cpt-toggle input:checked + .cpt-toggle-slider { background: #e91e8c; }
.cpt-toggle input:checked + .cpt-toggle-slider::before { left: 21px; }

/* Pill supports */
.cpt-pill-group { display: flex; flex-wrap: wrap; gap: 7px; }

.cpt-pill {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	padding: 6px 13px;
	border-radius: 50px;
	border: 1.5px solid #e2e6ed;
	background: #fff;
	font-size: 12px;
	font-weight: 500;
	color: #5b6470;
	cursor: pointer;
	transition: all .15s;
	user-select: none;
}

.cpt-pill:hover { border-color: #5F4AFE; color: #5F4AFE; background: #ede9ff; }
.tax-page .cpt-pill:hover { border-color: #e91e8c; color: #e91e8c; background: #fff0f6; }

.cpt-pill.is-active {
	border-color: #5F4AFE;
	background: #ede9ff;
	color: #5F4AFE;
}

.tax-page .cpt-pill.is-active { border-color: #e91e8c; background: #fff0f6; color: #e91e8c; }

/* Checkbox grid for post types / taxonomies attachment */
.cpt-check-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
	gap: 7px;
}

.cpt-check-item {
	display: flex;
	align-items: center;
	gap: 7px;
	padding: 8px 10px;
	border: 1.5px solid #e2e6ed;
	border-radius: 6px;
	font-size: 12px;
	font-weight: 500;
	color: #5b6470;
	cursor: pointer;
	transition: all .15s;
	background: #fafbfd;
}

.cpt-check-item:hover { border-color: #5F4AFE; background: #ede9ff; color: #5F4AFE; }
.tax-page .cpt-check-item:hover { border-color: #e91e8c; background: #fff0f6; color: #e91e8c; }
.cpt-check-item input { margin: 0; accent-color: #5F4AFE; }
.tax-page .cpt-check-item input { accent-color: #e91e8c; }

/* ── Form footer (prev / next / save) ────────────────────── */
.cpt-form-footer {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 16px 28px;
	border-top: 1px solid #e2e6ed;
	background: #fafbfd;
}

.cpt-footer-left  { display: flex; gap: 10px; }
.cpt-footer-right { display: flex; gap: 10px; }

.cpt-btn {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	padding: 9px 22px;
	font-size: 13px;
	font-weight: 600;
	border-radius: 7px;
	border: 1.5px solid #e2e6ed;
	background: #fff;
	color: #5b6470;
	cursor: pointer;
	font-family: inherit;
	transition: all .15s;
}

.cpt-btn:hover { border-color: #5F4AFE; color: #5F4AFE; background: #ede9ff; }
.tax-page .cpt-btn:hover { border-color: #e91e8c; color: #e91e8c; background: #fff0f6; }

.cpt-btn--primary {
	background: linear-gradient(135deg, #5F4AFE 0%, #3362FF 100%);
	border-color: transparent;
	color: #fff;
	box-shadow: 0 4px 14px rgba(95,74,254,.3);
}

.cpt-btn--primary:hover {
	border-color: transparent;
	color: #fff;
	background: linear-gradient(135deg, #4f3de8 0%, #2851e0 100%);
	box-shadow: 0 6px 20px rgba(95,74,254,.4);
}

.tax-page .cpt-btn--primary {
	background: linear-gradient(135deg, #e91e8c 0%, #5F4AFE 100%);
	box-shadow: 0 4px 14px rgba(233,30,140,.28);
}

.tax-page .cpt-btn--primary:hover {
	background: linear-gradient(135deg, #d01882 0%, #4f3de8 100%);
	color: #fff;
	border-color: transparent;
	box-shadow: 0 6px 20px rgba(233,30,140,.38);
}

.cpt-btn[disabled], .cpt-btn:disabled { opacity: .4; pointer-events: none; }

/* ── Toast notification ──────────────────────────────────── */
.cpt-toast {
	position: fixed;
	bottom: 24px;
	right: 24px;
	z-index: 99999;
	padding: 11px 18px;
	border-radius: 8px;
	font-size: 13px;
	font-weight: 600;
	color: #fff;
	box-shadow: 0 4px 20px rgba(0,0,0,.15);
	transform: translateY(12px);
	opacity: 0;
	transition: opacity .25s, transform .25s;
	pointer-events: none;
}

.cpt-toast.is-visible { opacity: 1; transform: translateY(0); }
.cpt-toast--success   { background: #1a8455; }
.cpt-toast--error     { background: #d63638; }
