/* Network Directory */

.nd-wrap {
	--nd-primary: #43727C;
	--nd-dark: #315863;
	--nd-accent: #ffca63;
	--nd-border: #e2e8ea;
	--nd-text-muted: #6b7c80;
	display: block;
	width: 100%;
	max-width: 100%;
	box-sizing: border-box;
	font-family: inherit;
}

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

/* Filters */
.nd-filters {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 32px;
}

.nd-filter-btn {
	font-size: 14px;
	font-weight: 600;
	padding: 9px 20px;
	border-radius: 999px;
	border: 1.5px solid var(--nd-primary);
	background: #fff;
	color: var(--nd-primary);
	cursor: pointer;
	transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.nd-filter-btn:hover {
	background: var(--nd-accent);
	border-color: var(--nd-accent);
	color: var(--nd-dark);
}

.nd-filter-btn.is-active {
	background: var(--nd-dark);
	border-color: var(--nd-dark);
	color: #fff;
}

/* Grid */
.nd-grid {
	display: grid;
	width: 100%;
	grid-template-columns: repeat(3, 1fr);
	gap: 24px;
}

@media (max-width: 991px) {
	.nd-grid {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 600px) {
	.nd-grid {
		grid-template-columns: 1fr;
	}
}

.nd-card {
	display: flex;
	flex-direction: column;
	background: #fff;
	border: 1px solid var(--nd-border);
	border-top: 4px solid var(--nd-primary);
	border-radius: 10px;
	padding: 24px;
	box-shadow: 0 2px 10px rgba(49, 88, 99, 0.06);
	transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.nd-card:hover {
	transform: translateY(-3px);
	box-shadow: 0 8px 20px rgba(49, 88, 99, 0.12);
}

.nd-card-logo img {
	max-height: 48px;
	width: auto;
	margin-bottom: 14px;
	object-fit: contain;
}

.nd-card-title {
	font-size: 19px;
	font-weight: 700;
	color: var(--nd-dark);
	margin: 0 0 8px;
}

.nd-card-topmeta {
	font-size: 12.5px;
	color: var(--nd-text-muted);
	margin: 0 0 14px;
}

.nd-card-topmeta p {
	margin: 2px 0;
}

.nd-card-tags {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin: 14px 0;
}

.nd-tag {
	font-size: 12px;
	font-weight: 600;
	color: var(--nd-dark);
	background: rgba(255, 202, 99, 0.35);
	border-radius: 6px;
	padding: 4px 10px;
}

.nd-card-financials {
	font-size: 12.5px;
	color: #333;
	border-top: 1px solid var(--nd-border);
	padding-top: 10px;
	margin-top: 10px;
}

.nd-card-financials p {
	display: flex;
	justify-content: space-between;
	gap: 10px;
	margin: 3px 0;
}

.nd-card-financials p span:first-child {
	color: var(--nd-text-muted);
}

.nd-card-financials p span:last-child {
	font-weight: 600;
	text-align: right;
}

.nd-card-footer {
	margin-top: auto;
}

.nd-card-meta {
	font-size: 12.5px;
	color: var(--nd-text-muted);
	border-top: 1px solid var(--nd-border);
	padding-top: 10px;
	margin-bottom: 16px;
}

.nd-card-meta p {
	margin: 2px 0;
}

.nd-card-btn {
	display: inline-block;
	text-align: center;
	margin-top: 0;
	padding: 10px 18px;
	background: var(--nd-dark);
	color: #fff !important;
	font-weight: 600;
	font-size: 14px;
	border-radius: 6px;
	text-decoration: none;
	transition: background 0.2s ease;
}

.nd-card-btn:hover {
	background: var(--nd-accent);
	color: var(--nd-dark) !important;
}

.nd-no-results {
	text-align: center;
	color: var(--nd-text-muted);
	padding: 40px 0;
	font-size: 15px;
}

@media (max-width: 480px) {
	.nd-filters {
		gap: 8px;
	}
	.nd-filter-btn {
		font-size: 13px;
		padding: 7px 14px;
	}
}

/* Website popup modal */
.nd-modal {
	display: none;
	position: fixed;
	inset: 0;
	z-index: 9999;
}

.nd-modal.is-open {
	display: block;
}

.nd-modal-overlay {
	position: absolute;
	inset: 0;
	background: rgba(30, 45, 49, 0.55);
	animation: nd-fade-in 0.2s ease;
}

.nd-modal-dialog {
	position: relative;
	z-index: 1;
	max-width: 440px;
	width: calc(100% - 40px);
	margin: 10vh auto 0;
	background: #fff;
	border-radius: 12px;
	border-top: 4px solid var(--nd-primary);
	padding: 32px 28px 28px;
	box-shadow: 0 20px 50px rgba(30, 45, 49, 0.25);
	animation: nd-modal-in 0.22s ease;
}

.nd-modal-close {
	position: absolute;
	top: 12px;
	right: 14px;
	border: none;
	background: none;
	font-size: 24px;
	line-height: 1;
	color: var(--nd-text-muted);
	cursor: pointer;
	padding: 4px;
}

.nd-modal-close:hover {
	color: var(--nd-dark);
}

.nd-modal-title {
	font-size: 19px;
	font-weight: 700;
	color: var(--nd-dark);
	margin: 0 0 12px;
	padding-right: 20px;
}

.nd-modal-text {
	font-size: 14.5px;
	line-height: 1.55;
	color: #333;
	margin: 0 0 24px;
}

.nd-modal-actions {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.nd-modal-btn {
	display: block;
	text-align: center;
	padding: 12px 18px;
	border-radius: 6px;
	font-weight: 600;
	font-size: 14.5px;
	text-decoration: none;
	transition: background 0.2s ease, color 0.2s ease;
}

.nd-modal-btn-primary {
	background: var(--nd-dark);
	color: #fff !important;
}

.nd-modal-btn-primary:hover {
	background: var(--nd-accent);
	color: var(--nd-dark) !important;
}

.nd-modal-btn-secondary {
	background: #fff;
	color: var(--nd-dark) !important;
	border: 1.5px solid var(--nd-border);
}

.nd-modal-btn-secondary:hover {
	border-color: var(--nd-primary);
	background: #f5f8f8;
}

@keyframes nd-fade-in {
	from { opacity: 0; }
	to { opacity: 1; }
}

@keyframes nd-modal-in {
	from { opacity: 0; transform: translateY(-12px); }
	to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 480px) {
	.nd-modal-dialog {
		margin-top: 15vh;
		padding: 26px 20px 22px;
	}
}
