/* Gated Resource Downloads - front-end styles */

.grd-grid {
	display: grid;
	gap: 20px;
	margin: 24px 0;
}
.grd-cols-1 { grid-template-columns: 1fr; }
.grd-cols-2 { grid-template-columns: repeat(2, 1fr); }
.grd-cols-3 { grid-template-columns: repeat(3, 1fr); }
.grd-cols-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 900px) {
	.grd-cols-3, .grd-cols-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
	.grd-grid { grid-template-columns: 1fr; }
}

.grd-card {
	display: flex;
	flex-direction: column;
	border: 1px solid #e3e6ea;
	border-radius: 12px;
	padding: 18px;
	background: #fff;
	box-shadow: 0 1px 2px rgba(16, 24, 40, 0.05);
	transition: box-shadow 0.15s ease, transform 0.15s ease;
}
.grd-card:hover {
	box-shadow: 0 8px 24px rgba(16, 24, 40, 0.10);
	transform: translateY(-2px);
}
.grd-card__thumb img {
	width: 100%;
	height: auto;
	border-radius: 8px;
	margin-bottom: 12px;
	display: block;
}
.grd-card__title {
	font-size: 1.15rem;
	line-height: 1.3;
	margin: 0 0 8px;
}
.grd-card__desc {
	color: #4b5563;
	font-size: 0.95rem;
	line-height: 1.5;
	margin-bottom: 16px;
	flex: 1 1 auto;
}
.grd-nofile {
	color: #9ca3af;
	font-style: italic;
	font-size: 0.9rem;
}

.grd-btn {
	display: inline-block;
	background: #242f49;
	color: #fff;
	border: none;
	border-radius: 8px;
	padding: 12px 20px;
	font-size: 1rem;
	font-weight: 600;
	cursor: pointer;
	text-align: center;
	line-height: 1.2;
	transition: background 0.15s ease;
}
.grd-btn:hover { background: #1a2338; }
.grd-btn:disabled { opacity: 0.6; cursor: default; }

/* Modal */
.grd-modal {
	position: fixed;
	inset: 0;
	display: none;
	align-items: center;
	justify-content: center;
	z-index: 999999;
}
.grd-modal.is-open { display: flex; }
.grd-modal__overlay {
	position: absolute;
	inset: 0;
	background: rgba(16, 24, 40, 0.55);
}
.grd-modal__box {
	position: relative;
	background: #fff;
	width: 100%;
	max-width: 440px;
	margin: 16px;
	border-radius: 14px;
	padding: 28px 26px 24px;
	box-shadow: 0 20px 60px rgba(16, 24, 40, 0.30);
	max-height: 90vh;
	overflow-y: auto;
}
.grd-modal__close {
	position: absolute;
	top: 10px;
	right: 12px;
	background: none;
	border: none;
	font-size: 26px;
	line-height: 1;
	color: #6b7280;
	cursor: pointer;
}
.grd-modal__close:hover { color: #111827; }
.grd-modal__title {
	margin: 0 0 6px;
	font-size: 1.3rem;
	padding-right: 24px;
}
.grd-modal__intro {
	color: #4b5563;
	font-size: 0.95rem;
	margin: 0 0 18px;
}

.grd-field { margin-bottom: 14px; }
.grd-field label {
	display: block;
	font-size: 0.9rem;
	font-weight: 600;
	margin-bottom: 5px;
	color: #1f2937;
}
.grd-field input[type="text"],
.grd-field input[type="tel"],
.grd-field input[type="email"] {
	width: 100%;
	padding: 11px 12px;
	border: 1px solid #cbd2da;
	border-radius: 8px;
	font-size: 1rem;
	box-sizing: border-box;
}
.grd-field input:focus {
	outline: none;
	border-color: #0b5cff;
	box-shadow: 0 0 0 3px rgba(11, 92, 255, 0.15);
}
.grd-consent label {
	display: flex;
	align-items: flex-start;
	gap: 8px;
	font-weight: 400;
	font-size: 0.85rem;
	color: #4b5563;
	line-height: 1.4;
}
.grd-consent input { margin-top: 2px; }

.grd-submit {
	width: 100%;
	margin-top: 6px;
}
.grd-error {
	background: #fef2f2;
	color: #b32d2e;
	border: 1px solid #fecaca;
	border-radius: 8px;
	padding: 10px 12px;
	font-size: 0.9rem;
	margin-bottom: 12px;
}
.grd-success {
	text-align: center;
}
.grd-success p { margin: 0 0 16px; color: #1f2937; }
.grd-success .grd-download-link {
	display: inline-block;
	background: #1a7f37;
	color: #fff;
	text-decoration: none;
	border-radius: 8px;
	padding: 12px 22px;
	font-weight: 600;
}
.grd-success .grd-download-link:hover { background: #15682d; }

/* Honeypot: keep it out of view without display:none (some bots skip those). */
.grd-hp {
	position: absolute;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}
