/* links.css — the community link catalog: the cards, the town picker and the
   logos.
   ---------
   The cards, filters, buttons, form fields and hints are the site's own
   (style.css, listings.css); this file adds only what the catalog has of its
   own: the logo beside the name, the line of category and towns, and the
   tick-box town picker on the form. Every colour and every space comes from the
   tokens in style.css. Loaded by the catalog's own templates, so it costs
   nothing on the rest of the site. */

/* ---- A card: the logo on the left, the name and the words on the right ---- */
.lnk-card .lnk-row { display: flex; align-items: flex-start; gap: var(--space-3); }

.lnk-text { min-width: 0; }   /* the text column may shrink, so a long address wraps instead of pushing the logo out */
.lnk-text > :last-child { margin-bottom: 0; }

/* The row's own line is the heading's gold one, which is the card's only line */
.lnk-text h3 { margin-top: 0; }
.lnk-text h3 a { color: inherit; text-decoration: none; }
.lnk-card:hover .lnk-text h3 a { color: var(--text-hover); }

/* The whole card goes to the resource, the way every other card on the site
   follows its own title */
.lnk-text h3 a::after { content: ''; position: absolute; inset: 0; z-index: 0; }

/* Where the link goes, what it is and which towns it is in: one quiet line */
.lnk-meta {
	margin: 0 0 var(--space-2); font-family: var(--font-ui); font-size: var(--fs-ui); color: var(--text-muted);
}

/* A logo is a drawing, not a photo: it is shown whole rather than cropped to
   fill, and gets no frame, so one on a transparent background sits on the
   parchment as its maker intended */
.lnk-logo {
	flex: 0 0 auto; display: block;
	width: 96px; height: 96px;   /* design-ok: a square the size of the bazaar's thumbnail, about two lines of the description tall */
	object-fit: contain;
}

/* Above the stretched title link, so the owner and the staff can reach them */
.lnk-actions {
	position: relative; z-index: 1;
	display: flex; flex-wrap: wrap; gap: var(--space-2); margin-top: var(--space-3);
}

/* ---- The form: towns as tick boxes, one group per country ---- */
.lnk-city-pick { display: flex; flex-wrap: wrap; gap: var(--space-4); }
.lnk-city-country { flex: 1 1 14rem; }   /* design-ok: about the width of the longest town name twice over, so the groups sit side by side on a desktop and stack on a phone */

.lnk-city-country-name {
	display: block; font-family: var(--font-caps); font-size: var(--fs-sm);
	letter-spacing: .04em; color: var(--text-faint); margin-bottom: var(--space-2);
}

.lnk-city-list { display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-3); }
.lnk-city-box, .lnk-logo-drop {
	display: flex; align-items: center; gap: var(--space-1);
	font-family: var(--font-ui); font-size: var(--fs-ui);
}

.lnk-logo-current .lnk-logo { margin: var(--space-1) 0 var(--space-2); }

/* ---- The removal question ---- */
.lnk-confirm > h2 { margin-bottom: var(--space-4); }   /* a card follows the heading, so its gold line never touches the card's */

@media (max-width: 480px) {
	.lnk-logo { width: 64px; height: 64px; }   /* design-ok: as above, one size down */
}
