/* [site_vcard] shortcode: QR code to save the company contact. Theme tokens come from the theme. */

.ft-vcard {
	--ft-vcard-size: 200px;
}

.ft-vcard--compact {
	--ft-vcard-size: 128px;
	display: flex;
	align-items: center;
	gap: 1rem;
	margin-top: 1rem;
}

.ft-vcard__qr {
	box-sizing: border-box;
	width: var(--ft-vcard-size);
	max-width: 100%;
	flex: 0 0 auto;
	padding: 8px;
	background: #fff;
	border: 1px solid var(--color-border, #e5e7eb);
	border-radius: var(--radius-md, 8px);
}

/* Square placeholder until the script draws the code. */
.ft-vcard__qr:empty {
	aspect-ratio: 1 / 1;
}

.ft-vcard__qr svg {
	display: block;
	width: 100%;
	height: auto;
}

.ft-vcard--card .ft-vcard__qr {
	margin: 0 0 1rem;
}

.ft-vcard__hint {
	margin: 0 0 1rem;
	font-size: 0.9375rem;
	color: var(--color-text-muted, #6b7280);
}

.ft-vcard--compact .ft-vcard__hint {
	display: block;
	margin: 0 0 0.35rem;
	font-size: 0.875rem;
	color: inherit;
	opacity: 0.85;
}

.ft-vcard__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.75rem 1rem;
}

.ft-vcard__downloads {
	font-size: 0.875rem;
	color: var(--color-text-muted, #6b7280);
}

.ft-vcard__downloads a {
	color: var(--color-accent, #d97706);
	text-decoration: underline;
}

.ft-vcard--compact .ft-vcard__save {
	font-weight: 600;
	text-decoration: underline;
}

.ft-vcard--compact .ft-vcard__downloads {
	display: block;
	margin-top: 0.35rem;
	font-size: 0.8125rem;
}

/* Inside a card (Contact page) the block follows the card's own spacing. On desktop the
   four-column cards are narrow, so the QR sits above the text instead of beside it. */
.ft-card .ft-vcard--compact {
	margin-top: 0;
	gap: 0.875rem;
}

@media (min-width: 1025px) {
	.ft-card .ft-vcard--compact {
		--ft-vcard-size: 120px;
		flex-direction: column;
		align-items: flex-start;
		gap: 0.75rem;
	}
}

/* Wide band: QR left, text and buttons right; stacks on phones. */
.ft-vcard--wide {
	--ft-vcard-size: 184px;
	display: flex;
	align-items: center;
	gap: 2.5rem;
}

.ft-vcard--wide .ft-vcard__body {
	flex: 1 1 auto;
	min-width: 0;
}

.ft-vcard__eyebrow {
	margin: 0 0 0.5rem;
	font-size: 14px;
	font-weight: 700;
	letter-spacing: 1.5px;
	text-transform: uppercase;
	color: var(--color-accent, #d97706);
}

.ft-vcard__title {
	margin: 0 0 0.75rem;
	font-family: var(--font-heading, inherit);
	font-size: 1.75rem;
	line-height: 1.15;
	color: var(--color-heading, #0b2545);
}

.ft-vcard--wide .ft-vcard__hint {
	max-width: 60ch;
}

@media (max-width: 767px) {
	.ft-vcard--wide {
		flex-direction: column;
		align-items: flex-start;
		gap: 1.5rem;
	}

	.ft-vcard--wide .ft-vcard__qr {
		--ft-vcard-size: 160px;
	}
}

/* Fallback button styling when the theme does not provide .button */
.ft-vcard--card .ft-vcard__save:not(.button) {
	display: inline-block;
	padding: 0.75em 1.5em;
	background: var(--color-accent, #d97706);
	color: #fff;
	border-radius: 8px;
	text-decoration: none;
}
