/* Harsha Trust — Tender Notices: the published notice.
   Uses the theme's own tokens so it sits inside the site without looking bolted on. */

.htn-notice {
	--htn-line: #e7e7e6;
	color: var(--text-body, #333);
}

.htn-notice__header {
	background: var(--bg-light, #f5f5f4);
	border-left: 4px solid var(--primary, #9f141b);
	border-radius: var(--radius-s, 0.75rem);
	padding: 1.6rem 1.8rem;
	margin-bottom: 1.8rem;
}

.htn-notice__org {
	margin: 0 0 .35rem;
	font-size: .8rem;
	font-weight: 700;
	letter-spacing: .12em;
	text-transform: uppercase;
	color: var(--primary, #9f141b);
}

.htn-notice__title {
	margin: 0;
	font-family: "PT Serif", Georgia, serif;
	font-size: clamp(1.2rem, 1.02rem + .55vw, 1.5rem);
	line-height: 1.35;
	color: var(--text-title, #3a0e12);
}

.htn-notice__status {
	margin: .9rem 0 0;
}

.htn-notice__meta {
	margin-top: 1.1rem;
	display: flex;
	flex-wrap: wrap;
	gap: .4rem 2rem;
	font-size: .92rem;
}

.htn-notice__meta strong {
	color: var(--text-title, #3a0e12);
}

.htn-notice__downloads {
	background: #fff;
	border: 1px solid var(--htn-line);
	border-radius: var(--radius-s, 0.75rem);
	padding: 1rem 1.4rem;
	margin-bottom: 1.8rem;
}

.htn-notice__downloads-label {
	margin: 0 0 .5rem;
	font-size: .9rem;
	text-transform: uppercase;
	letter-spacing: .08em;
	color: var(--text-muted, #6b6b6b);
}

.htn-notice__downloads-list {
	margin: 0;
	padding: 0;
	list-style: none;
	display: flex;
	flex-wrap: wrap;
	gap: .6rem 1.6rem;
}

.htn-notice__downloads-list a {
	font-weight: 600;
}

.htn-file-ext {
	font-size: .72rem;
	font-weight: 700;
	letter-spacing: .06em;
	color: var(--primary, #9f141b);
	border: 1px solid currentColor;
	border-radius: 999px;
	padding: 0 .45rem;
	margin-left: .25rem;
	vertical-align: 1px;
}

.htn-notice h3 {
	font-family: "PT Serif", Georgia, serif;
	font-size: clamp(1.15rem, 1rem + .5vw, 1.45rem);
	line-height: 1.35;
	color: var(--text-title, #3a0e12);
	margin: 2.2rem 0 .8rem;
	padding-bottom: .45rem;
	border-bottom: 1px solid var(--htn-line);
}

.htn-notice__note {
	font-size: .95rem;
	color: var(--text-muted, #6b6b6b);
}

.htn-spec {
	margin: 0;
	display: grid;
	gap: .2rem;
}

.htn-spec__row {
	display: grid;
	grid-template-columns: minmax(180px, 260px) 1fr;
	gap: .4rem 1.2rem;
	padding: .7rem 0;
	border-bottom: 1px solid var(--htn-line);
}

.htn-spec__row:last-child {
	border-bottom: 0;
}

.htn-spec dt {
	font-weight: 700;
	color: var(--text-title, #3a0e12);
}

.htn-spec dd {
	margin: 0;
}

.htn-table-wrap {
	overflow-x: auto;
	margin-bottom: 1.6rem;
	border: 1px solid var(--htn-line);
	border-radius: var(--radius-s, 0.75rem);
}

.htn-table {
	width: 100%;
	border-collapse: collapse;
	background: #fff;
	font-size: .95rem;
}

.htn-table th,
.htn-table td {
	text-align: left;
	padding: .6rem .85rem;
	border-bottom: 1px solid var(--htn-line);
	vertical-align: top;
}

.htn-table thead th {
	background: var(--bg-light, #f5f5f4);
	font-weight: 700;
	color: var(--text-title, #3a0e12);
	white-space: nowrap;
}

.htn-table tbody tr:last-child td,
.htn-table tbody tr:last-child th {
	border-bottom: 0;
}

.htn-table--dates th[scope="row"] {
	white-space: nowrap;
	width: 1%;
}

.htn-table--sites {
	font-size: .88rem;
}

.htn-table--sites th,
.htn-table--sites td {
	padding: .45rem .6rem;
}

.htn-notice__contact {
	background: var(--bg-light, #f5f5f4);
	border-radius: var(--radius-s, 0.75rem);
	padding: 1rem 1.4rem;
}

.htn-notice__keyinfo {
	background: #fff;
	border: 1px solid var(--htn-line);
	border-radius: var(--radius-s, 0.75rem);
	padding: 1rem 1.4rem 1.2rem;
	margin-bottom: 1.8rem;
}

.htn-notice__keyinfo h3 {
	margin: 0 0 .4rem;
	padding-bottom: 0;
	border-bottom: 0;
	font-size: 1.05rem;
}

.htn-notice__body > *:first-child {
	margin-top: 0;
}

.htn-notice__body table {
	width: 100%;
}

.htn-notice__back {
	margin: 2rem 0 0;
	font-weight: 600;
}

/* --------------------------------------------------------------- status */

.htn-status {
	display: inline-block;
	font-size: .72rem;
	font-weight: 700;
	letter-spacing: .07em;
	text-transform: uppercase;
	border-radius: 999px;
	padding: .2rem .7rem;
	border: 1px solid currentColor;
	white-space: nowrap;
}

.htn-status--open {
	color: #1f7a4d;
	background: #eaf6ef;
}

.htn-status--upcoming {
	color: #9a6a00;
	background: #fdf3e0;
}

.htn-status--closed {
	color: #6b6b6b;
	background: #f1f1f0;
}

/* --------------------------------------------------------- the list pages */

.htn-index__head {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: space-between;
	gap: .6rem 2rem;
	margin-bottom: 1.4rem;
}

.htn-index__intro {
	margin: 0;
	max-width: 62ch;
	color: var(--text-muted, #6b6b6b);
}

.htn-index__switch {
	font-weight: 700;
	white-space: nowrap;
}

.htn-empty {
	background: var(--bg-light, #f5f5f4);
	border-radius: var(--radius-s, 0.75rem);
	padding: 1.2rem 1.4rem;
	color: var(--text-muted, #6b6b6b);
}

.htn-table--index {
	font-size: .95rem;
}

.htn-table--index .htn-table__tender {
	width: 42%;
	font-weight: 400;
}

.htn-table--index .htn-table__title {
	display: inline-block;
	font-family: "PT Serif", Georgia, serif;
	font-size: 1.05rem;
	font-weight: 700;
	line-height: 1.35;
	color: var(--text-title, #3a0e12);
}

.htn-table--index .htn-table__title:hover {
	color: var(--primary, #9f141b);
}

.htn-table--index .htn-table__summary {
	display: block;
	margin-top: .3rem;
	font-size: .85rem;
	font-weight: 400;
	line-height: 1.5;
	color: var(--text-muted, #6b6b6b);
}

.htn-table--index .htn-table__action {
	width: 1%;
	white-space: nowrap;
}

.htn-table--index .htn-table__link {
	font-weight: 700;
}

.htn-table--index .htn-table__files {
	display: block;
	margin-top: .2rem;
	font-size: .78rem;
	color: var(--text-muted, #6b6b6b);
}

.htn-table--index tbody tr:nth-child(even) {
	background: #fcfcfc;
}

@media (max-width: 767px) {
	.htn-spec__row {
		grid-template-columns: 1fr;
	}

	.htn-notice__meta {
		flex-direction: column;
		gap: .2rem;
	}

	/* the table of tenders becomes a list of cards */
	.htn-table--index thead {
		display: none;
	}

	.htn-table--index,
	.htn-table--index tbody,
	.htn-table--index tr,
	.htn-table--index th,
	.htn-table--index td {
		display: block;
		width: auto;
	}

	.htn-table--index tr {
		border: 1px solid var(--htn-line);
		border-radius: var(--radius-s, 0.75rem);
		padding: .9rem 1rem;
		margin-bottom: .9rem;
		background: #fff;
	}

	.htn-table--index tbody tr:nth-child(even) {
		background: #fff;
	}

	.htn-table--index .htn-table__tender {
		margin-bottom: .5rem;
		padding-bottom: .5rem;
		border-bottom: 1px solid var(--htn-line);
	}

	.htn-table--index td {
		display: flex;
		justify-content: space-between;
		align-items: baseline;
		gap: 1rem;
		padding: .25rem 0;
		border: 0;
	}

	.htn-table--index td::before {
		content: attr(data-label);
		font-weight: 700;
		color: var(--text-muted, #6b6b6b);
	}

	.htn-table--index .htn-table__files {
		margin: 0;
	}
}
