/**
 * AKM Org Chart Tree - Mobile shortcode only
 * Standalone styles for [akm_org_chart_tree_mobile]
 * Does not inherit from desktop - fully independent
 */

.akm-org-chart-tree-mobile {
	font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
	font-size: 12px;
	line-height: 1.5;
	padding: 1.25rem 1rem;
	max-width: 100%;
	width: 100%;
	min-width: 0;
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
	background: #fff;
	border-radius: 10px;
	box-sizing: border-box;
}

.akm-org-chart-tree-mobile .akm-tree-root {
	display: flex;
	flex-direction: column;
	align-items: center;
}

.akm-org-chart-tree-mobile .akm-tree-branch {
	display: flex;
	flex-direction: column;
	align-items: center;
	position: relative;
}

.akm-org-chart-tree-mobile .akm-tree-children {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 12px 16px;
	margin-top: 16px;
	padding-top: 16px;
	position: relative;
}

.akm-org-chart-tree-mobile .akm-tree-children::before,
.akm-org-chart-tree-mobile .akm-tree-children::after,
.akm-org-chart-tree-mobile .akm-tree-children > .akm-tree-branch::before {
	content: none;
}

.akm-org-chart-tree-mobile .akm-tree-node {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 12px 14px;
	width: 100%;
	max-width: 180px;
	min-width: 140px;
	min-height: 48px;
	border: none;
	border-radius: 8px;
	text-align: center;
	box-sizing: border-box;
	flex-shrink: 0;
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
}

.akm-org-chart-tree-mobile .akm-tree-box-orange {
	background: linear-gradient(135deg, #2563eb 0%, #1e40af 100%);
	color: #fff;
	font-weight: 700;
	font-size: 11px;
	letter-spacing: 0.02em;
	text-transform: uppercase;
}

.akm-org-chart-tree-mobile .akm-tree-box-blue,
.akm-org-chart-tree-mobile .akm-tree-box-grey {
	background: #fff;
	color: #1e293b;
	border: 2px solid #3b82f6;
	box-shadow: 0 1px 3px rgba(59, 130, 246, 0.2);
}

.akm-org-chart-tree-mobile .akm-tree-box-vacant {
	flex-direction: column;
	background: #fff;
	border: 2px dashed #dc2626;
}

.akm-org-chart-tree-mobile .akm-tree-box-vacant .akm-tree-kosong {
	color: #dc2626;
	font-weight: 800;
	font-size: 12px;
	display: block;
	margin-bottom: 4px;
	letter-spacing: 0.05em;
}

.akm-org-chart-tree-mobile .akm-tree-box-vacant .akm-tree-label,
.akm-org-chart-tree-mobile .akm-tree-box-vacant .akm-tree-grade {
	font-size: 11px;
	color: #b91c1c;
}

.akm-org-chart-tree-mobile .akm-tree-box-person {
	flex-direction: column;
	align-items: center;
	text-align: center;
	width: 100%;
	max-width: 180px;
	min-width: 140px;
	padding: 12px 14px;
}

.akm-org-chart-tree-mobile .akm-tree-name {
	font-weight: 700;
	font-size: 12px;
	display: block;
	margin-bottom: 4px;
	line-height: 1.35;
	word-break: break-word;
	color: #0f172a;
}

.akm-org-chart-tree-mobile .akm-tree-title {
	font-size: 10px;
	color: #475569;
	display: block;
	margin-bottom: 4px;
	line-height: 1.35;
	word-break: break-word;
	font-weight: 500;
}

.akm-org-chart-tree-mobile .akm-tree-grade {
	font-size: 10px;
	color: #854d0e;
	font-weight: 600;
	display: inline-block;
	background: #fef08a;
	padding: 2px 6px;
	border-radius: 4px;
	margin-top: 2px;
	border: 1px solid #eab308;
}

.akm-org-chart-tree-mobile .akm-tree-label {
	font-weight: 700;
	word-break: break-word;
}

/* Mobile layout - single column everywhere */
.akm-org-chart-tree-mobile .akm-tree-root-layout {
	display: flex;
	flex-direction: column;
	align-items: center;
	margin-top: 16px;
	width: 100%;
}

.akm-org-chart-tree-mobile .akm-tree-root-dashed-row {
	position: relative;
	width: 100%;
	max-width: 280px;
	padding-top: 16px;
	padding-bottom: 16px;
	display: flex;
	justify-content: flex-end;
}

.akm-org-chart-tree-mobile .akm-tree-root-dashed-row::before {
	content: none;
}

.akm-org-chart-tree-mobile .akm-tree-root-dashed-item {
	position: relative;
	width: 100%;
	max-width: 180px;
}

.akm-org-chart-tree-mobile .akm-tree-root-dashed-item::before {
	content: none;
}

.akm-org-chart-tree-mobile .akm-tree-root-solid-children,
.akm-org-chart-tree-mobile .akm-tree-root > .akm-tree-branch > .akm-tree-children {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 16px;
	width: 100%;
}

.akm-org-chart-tree-mobile .akm-tree-root-solid-children > .akm-tree-branch,
.akm-org-chart-tree-mobile .akm-tree-root > .akm-tree-branch > .akm-tree-children > .akm-tree-branch {
	width: 100%;
	max-width: 280px;
}

.akm-org-chart-tree-mobile .akm-tree-root > .akm-tree-branch > .akm-tree-branch > .akm-tree-children {
	flex-direction: column;
	align-items: center;
	gap: 16px;
}

.akm-org-chart-tree-mobile .akm-tree-branch-type-department .akm-tree-children {
	display: grid;
	grid-template-columns: 1fr;
	gap: 12px;
	max-width: 100%;
}

.akm-org-chart-tree-mobile .akm-tree-empty {
	color: #64748b;
	font-size: 14px;
}

.akm-org-chart-tree-mobile .akm-tree-date {
	margin-top: 1.5rem;
	text-align: center;
	font-size: 12px;
	color: #1e40af;
	font-weight: 500;
}
