/* Nodi della Rete — archive page */

.grp-label {
	font-size: .8rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
	color: var(--ali-teal, #00C0C6); margin-bottom: 10px;
}

/* Hero */
.grp-hero { padding: 72px 24px 40px; text-align: center; }
.grp-hero__content { max-width: 760px; margin: 0 auto; }
.grp-hero h1 { margin: 0 0 12px; font-size: clamp(2rem, 4.5vw, 3.1rem); }
.grp-hero__subtitle { font-size: 1.1rem; color: var(--ali-text-secondary, #64748B); margin: 0; }

/* Non-affiliation disclaimer */
.nodo-disclaimer {
	margin: 0 0 28px; padding: 12px 16px;
	background: var(--ali-cream, #FAFAF8);
	border: 1px solid var(--ali-warm-gray, #E2E8F0);
	border-left: 4px solid var(--ali-teal, #00C0C6);
	border-radius: 8px;
	font-size: .9rem; line-height: 1.55; color: var(--ali-text-secondary, #64748B);
}

/* Filters */
.grp-grid-section { padding: 0 24px 72px; }
.grp-grid-inner { max-width: 1140px; margin: 0 auto; }
.grp-filters { display: flex; flex-wrap: wrap; gap: 16px; margin: 0 0 32px; }
.grp-filter { display: flex; flex-direction: column; gap: 6px; min-width: 200px; }
.grp-filter label { font-size: .82rem; font-weight: 600; color: var(--ali-navy-light, #A367A1); }
.grp-filter select {
	padding: 10px 12px; border: 1px solid var(--ali-warm-gray, #E2E8F0);
	border-radius: 8px; background: #fff; font-size: .95rem;
}
.grp-filter select:disabled { opacity: .55; }

/* Grid */
.grp-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 22px; }
.grp-card {
	display: flex; flex-direction: column; text-decoration: none; color: inherit;
	background: #fff; border: 1px solid var(--ali-warm-gray, #E2E8F0);
	border-radius: 14px; overflow: hidden; transition: transform .15s, box-shadow .15s;
}
.grp-card:hover { transform: translateY(-3px); box-shadow: 0 10px 30px rgba(124,94,150,.15); }
.grp-card--hidden { display: none; }
.grp-card__img { aspect-ratio: 16 / 10; background: #eef6f8; overflow: hidden; }
.grp-card__img img { width: 100%; height: 100%; object-fit: cover; }
.grp-card__placeholder {
	display: block; width: 100%; height: 100%;
	background: linear-gradient(120deg, var(--ali-teal, #00C0C6), var(--ali-navy-light, #A367A1)); opacity: .25;
}
.grp-card__body { padding: 16px; }
.grp-card__body h2 { margin: 0 0 10px; font-size: 1.15rem; }
.grp-card__badges { display: flex; flex-wrap: wrap; gap: 6px; }
.grp-badge {
	display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: .78rem; font-weight: 600;
}
.grp-badge--tipo { background: rgba(180,83,9,.10); color: #B45309; }
.grp-badge--regione { background: rgba(8,145,178,.12); color: var(--ali-teal, #00C0C6); }
.grp-badge--provincia { background: rgba(124,94,150,.12); color: var(--ali-navy-light, #A367A1); }
.grp-grid-empty { grid-column: 1 / -1; text-align: center; color: var(--ali-text-secondary, #64748B); padding: 40px 0; }

/* CTA */
.grp-cta { padding: 64px 24px; text-align: center; background: var(--ali-cream, #FAFAF8); }
.grp-cta-inner { max-width: 640px; margin: 0 auto; }
.grp-cta h2 { margin: 0 0 12px; }
.grp-cta-text { color: var(--ali-text-secondary, #64748B); margin: 0 0 24px; }
.grp-btn {
	display: inline-block; padding: 12px 28px; border-radius: 999px;
	background: var(--ali-teal, #00C0C6); color: #fff; text-decoration: none; font-weight: 600;
}
.grp-btn:hover { background: var(--ali-navy-light, #A367A1); }

/* Search input */
.grp-filter--search { flex: 1 1 240px; }
.grp-filter input[type="search"] {
	padding: 10px 12px; border: 1px solid var(--ali-warm-gray, #E2E8F0);
	border-radius: 8px; background: #fff; font-size: .95rem; width: 100%;
}

/* Results bar */
.grp-results { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 18px; }
.grp-results__count { font-size: .9rem; color: var(--ali-text-secondary, #64748B); font-weight: 600; }
.grp-results__clear {
	background: none; border: 0; cursor: pointer; padding: 4px 8px;
	font-size: .88rem; font-weight: 600; color: var(--ali-teal, #00C0C6);
}
.grp-results__clear:hover { color: var(--ali-navy-light, #A367A1); text-decoration: underline; }

/* No hover underline on cards / primary CTA button */
.grp-card, .grp-card:hover, .grp-card:focus { text-decoration: none; }
.grp-btn, .grp-btn:hover, .grp-btn:focus { text-decoration: none; }

/* Quick-view modal */
.grp-modal {
	position: fixed; inset: 0; z-index: 1000;
	display: none; align-items: flex-start; justify-content: center;
	padding: 32px 16px; overflow-y: auto;
	background: rgba(15, 23, 42, .6);
}
.grp-modal.is-open { display: flex; animation: grp-modal-fade .2s ease both; }
body.grp-modal-open { overflow: hidden; }
.grp-modal__dialog {
	position: relative; width: 100%; max-width: 640px;
	margin: auto; /* centers when shorter than the viewport; scrolls from top when taller */
	background: #fff; border-radius: 16px; overflow: hidden;
	box-shadow: 0 20px 60px rgba(15, 23, 42, .35);
}
.grp-modal.is-open .grp-modal__dialog { animation: grp-modal-pop .25s cubic-bezier(.16, 1, .3, 1) both; }
@keyframes grp-modal-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes grp-modal-pop {
	from { opacity: 0; transform: translateY(16px) scale(.98); }
	to   { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
	.grp-modal.is-open,
	.grp-modal.is-open .grp-modal__dialog { animation: none; }
}
.grp-modal__close {
	position: absolute; top: 12px; right: 12px; z-index: 2;
	width: 36px; height: 36px; border: 0; border-radius: 999px; cursor: pointer;
	background: rgba(255, 255, 255, .9); color: #0f172a;
	font-size: 1.4rem; line-height: 1;
	display: flex; align-items: center; justify-content: center;
}
.grp-modal__close:hover { background: #fff; }
.grp-modal__img { aspect-ratio: 16 / 9; background: #eef6f8; }
.grp-modal__img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.grp-modal__body { padding: 24px; }
.grp-modal__title { margin: 0 0 12px; font-size: 1.5rem; }
/* When there's no image, keep the title clear of the floating close button. */
.grp-modal__card > .grp-modal__body:first-child .grp-modal__title { padding-right: 32px; }
.grp-modal__badges { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 16px; }
.grp-modal__stats { display: flex; flex-wrap: wrap; gap: 20px; margin: 0 0 18px; }
.grp-modal__stat { display: flex; flex-direction: column; }
.grp-modal__stat-value { font-size: 1.25rem; font-weight: 700; color: var(--ali-navy-light, #A367A1); }
.grp-modal__stat-label { font-size: .8rem; color: var(--ali-text-secondary, #64748B); }
.grp-modal__desc { color: var(--ali-text-secondary, #64748B); line-height: 1.6; }
.grp-modal__desc p:first-child { margin-top: 0; }
.grp-modal__socials { display: flex; flex-wrap: wrap; gap: 10px; margin: 18px 0 0; }
.grp-modal__social {
	display: inline-flex; align-items: center; justify-content: center;
	width: 40px; height: 40px; border-radius: 999px;
	background: var(--ali-cream, #FAFAF8); border: 1px solid var(--ali-warm-gray, #E2E8F0);
	color: var(--ali-navy-light, #A367A1); text-decoration: none;
}
.grp-modal__social:hover { color: var(--ali-teal, #00C0C6); border-color: var(--ali-teal, #00C0C6); }
.grp-modal__social svg { width: 20px; height: 20px; }
.grp-modal__full {
	display: inline-block; margin: 20px 0 0; font-weight: 600;
	color: var(--ali-teal, #00C0C6); text-decoration: none;
}
.grp-modal__full:hover { color: var(--ali-navy-light, #A367A1); text-decoration: underline; }
@media (max-width: 600px) {
	.grp-modal { padding: 0; }
	.grp-modal__dialog { min-height: 100%; border-radius: 0; max-width: none; }
}
