/**
 * Job table: the job-portal list format (template-parts/job/table.php).
 * Locked design tokens only. Rows stack into labelled blocks below 768px.
 */

.ifja-job-table-wrap {
	overflow-x: visible;
	margin: 0 0 1.5rem;
	border: 1px solid var(--ifja-border);
	border-radius: 8px;
	background: var(--ifja-bg);
}

.ifja-job-table {
	width: 100%;
	min-width: 0;
	border-collapse: collapse;
	font-size: 0.875rem;
}

.ifja-job-table th,
.ifja-job-table td {
	padding: 0.625rem 0.75rem;
	border-bottom: 1px solid var(--ifja-border);
	text-align: left;
	vertical-align: top;
}

.ifja-job-table thead th {
	background: var(--ifja-surface);
	color: var(--ifja-text-muted);
	font-size: 0.75rem;
	font-weight: 700;
	letter-spacing: 0.03em;
	text-transform: uppercase;
	white-space: nowrap;
}

.ifja-job-table tbody tr:last-child td {
	border-bottom: 0;
}

.ifja-job-table tbody tr:hover {
	background: var(--ifja-surface);
}

.ifja-job-table__date,
.ifja-job-table__vac,
.ifja-job-table__last {
	white-space: nowrap;
}

.ifja-job-table__org {
	color: var(--ifja-text-muted);
}

.ifja-job-table__post {
	min-width: 0;
}

.ifja-job-table__post a {
	color: var(--ifja-text);
	font-weight: 600;
	text-decoration: none;
}

.ifja-job-table__post a:hover,
.ifja-job-table__post a:focus-visible {
	color: var(--ifja-accent);
	text-decoration: underline;
}

.ifja-job-table__new {
	display: inline-block;
	margin-left: 0.375rem;
	padding: 0.0625rem 0.375rem;
	border-radius: 999px;
	background: rgba(22, 163, 74, 0.1);
	color: var(--ifja-success);
	font-size: 0.6875rem;
	font-weight: 700;
	vertical-align: middle;
}

.ifja-job-table__qual {
	color: var(--ifja-text-muted);
}

.ifja-job-table__days {
	display: block;
	color: var(--ifja-text-muted);
	font-size: 0.75rem;
}

.ifja-job-table__days--urgent {
	color: var(--ifja-error);
	font-weight: 600;
}

.ifja-job-table__btn {
	display: inline-block;
	padding: 0.25rem 0.75rem;
	border: 1px solid var(--ifja-accent);
	border-radius: 6px;
	color: var(--ifja-accent);
	font-weight: 600;
	text-decoration: none;
	white-space: nowrap;
}

.ifja-job-table__btn:hover,
.ifja-job-table__btn:focus-visible {
	background: var(--ifja-accent);
	color: #ffffff;
}

.ifja-job-table-empty {
	margin: 0 0 1.5rem;
	padding: 1rem;
	border: 1px dashed var(--ifja-border);
	border-radius: 8px;
	background: var(--ifja-surface);
	color: var(--ifja-text-muted);
}

.ifja-job-section {
	margin: 0 0 0.5rem;
}

.ifja-job-section__title {
	margin: 1.5rem 0 0.75rem;
	font-size: 1.125rem;
}

.ifja-job-section__more {
	margin: -0.75rem 0 1.5rem;
	font-size: 0.875rem;
}

/* Narrow screens: each row becomes a labelled block. */
@media (max-width: 767px) {
	.ifja-job-table-wrap {
		overflow: visible;
	}

	.ifja-job-table thead {
		position: absolute;
		width: 1px;
		height: 1px;
		overflow: hidden;
		clip: rect(0 0 0 0);
	}

	.ifja-job-table,
	.ifja-job-table tbody,
	.ifja-job-table tr,
	.ifja-job-table td {
		display: block;
		width: 100%;
	}

	.ifja-job-table tr {
		padding: 0.75rem 0.875rem;
		border-bottom: 1px solid var(--ifja-border);
	}

	.ifja-job-table tbody tr:last-child {
		border-bottom: 0;
	}

	.ifja-job-table td {
		display: flex;
		gap: 0.5rem;
		min-width: 0;
		padding: 0.1875rem 0;
		border: 0;
		white-space: normal;
	}

	.ifja-job-table td::before {
		content: attr(data-label);
		flex: 0 0 6.5rem;
		color: var(--ifja-text-muted);
		font-size: 0.75rem;
		font-weight: 600;
	}

	.ifja-job-table td.ifja-job-table__post {
		display: block;
		order: -1;
		padding-bottom: 0.375rem;
		font-size: 0.9375rem;
	}

	.ifja-job-table td.ifja-job-table__post::before,
	.ifja-job-table td.ifja-job-table__action::before {
		content: none;
	}

	.ifja-job-table__days {
		display: inline;
		margin-left: 0.375rem;
	}

	.ifja-job-table td.ifja-job-table__action {
		padding-top: 0.5rem;
	}
}
