/* ==========================================================================
   Tefillin Customizer — frontend
   Values ported 1:1 from the approved design.
   ========================================================================== */

@font-face { font-family: 'Google Sans'; src: url('../fonts/GoogleSans-Regular.woff2') format('woff2'), url('../fonts/GoogleSans-Regular.woff') format('woff'); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: 'Google Sans'; src: url('../fonts/GoogleSans-Medium.woff2') format('woff2'), url('../fonts/GoogleSans-Medium.woff') format('woff'); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: 'Google Sans'; src: url('../fonts/GoogleSans-SemiBold.woff2') format('woff2'), url('../fonts/GoogleSans-SemiBold.woff') format('woff'); font-weight: 600; font-style: normal; font-display: swap; }
@font-face { font-family: 'Google Sans'; src: url('../fonts/GoogleSans-Bold.woff2') format('woff2'), url('../fonts/GoogleSans-Bold.woff') format('woff'); font-weight: 700; font-style: normal; font-display: swap; }

.tfc-block {
	font-family: 'Google Sans', system-ui, -apple-system, sans-serif;
	color: #1a1a1a;
	direction: rtl;
	text-align: right;
	margin: 26px 0 14px;
	max-width: 100%;
	-webkit-font-smoothing: antialiased;
}
.tfc-block *, .tfc-lightbox * { box-sizing: border-box; }

/* block header — mirrors the "התאמה אישית" divider */
.tfc-head { border-top: 1px solid #1a1a1a; padding-top: 18px; margin-bottom: 20px; }
.tfc-head-title { font-size: 18px; font-weight: 600; line-height: 1.3; }
.tfc-head-sub { font-size: 13px; color: #8a8a8a; margin-top: 4px; line-height: 1.6; }

/* group headers */
.tfc-group-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.tfc-group-head--spaced { margin-top: 34px; }
.tfc-group-title { font-size: 13px; font-weight: 700; letter-spacing: 0.08em; }
.tfc-group-note { font-size: 12px; color: #8a8a8a; }

/* option rows */
.tfc-rows { display: flex; flex-direction: column; gap: 10px; }

.tfc-block .tfc-row {
	display: grid !important;
	grid-template-columns: 20px 66px minmax(0, 1fr) auto !important;
	align-items: center !important;
	gap: 14px !important;
	padding: 12px !important;
	border: 1px solid #ededed !important;
	background: #fff !important;
	cursor: pointer;
	margin: 0 !important;
	width: 100% !important;
	float: none !important;
	transition: border-color .15s ease, background-color .15s ease;
}
.tfc-block .tfc-row:hover { border-color: #c9c9c9 !important; }
.tfc-block .tfc-row.is-selected { border-color: #1a1a1a !important; background: #fbfbfb !important; }

.tfc-input-radio, .tfc-input-check {
	position: absolute; opacity: 0; width: 1px; height: 1px; margin: 0; pointer-events: none;
}

.tfc-dot { width: 18px; height: 18px; flex-shrink: 0; border-radius: 50%; border: 1px solid #c9c9c9; display: flex; align-items: center; justify-content: center; }
.tfc-dot > span { width: 9px; height: 9px; border-radius: 50%; background: transparent; }
.tfc-row.is-selected .tfc-dot { border-color: #1a1a1a; }
.tfc-row.is-selected .tfc-dot > span { background: #1a1a1a; }

.tfc-box { width: 20px; height: 20px; flex-shrink: 0; border-radius: 6px; border: 1px solid #c9c9c9; background: #fff; display: flex; align-items: center; justify-content: center; position: relative; }
.tfc-row.is-selected .tfc-box { border-color: #1a1a1a; background: #1a1a1a; }
.tfc-row.is-selected .tfc-box::after { content: '\2713'; color: #fff; font-size: 12px; line-height: 1; }

.tfc-block .tfc-thumb { width: 66px; height: 66px; flex-shrink: 0; background: #f6f6f6 center/cover no-repeat; overflow: hidden; display: block; }

.tfc-text { flex: 1; min-width: 0; display: block; }
.tfc-label { display: block; font-size: 15.5px; font-weight: 600; line-height: 1.3; }
.tfc-sub { display: block; font-size: 12.5px; color: #8a8a8a; margin-top: 3px; line-height: 1.5; }

.tfc-block .tfc-price { font-size: 14px; font-weight: 600; white-space: nowrap; color: #1a1a1a; justify-self: end; }
.tfc-price.is-muted { font-size: 13px; color: #8a8a8a; }
.tfc-price .woocommerce-Price-amount { font-weight: 600; }

/* zoom button */
.tfc-block button.tfc-zoom {
	-webkit-appearance: none;
	appearance: none;
	margin: 8px 0 0 !important;
	display: inline-flex !important;
	align-items: center !important;
	gap: 6px !important;
	width: auto !important;
	min-height: 0 !important;
	height: auto !important;
	padding: 7px 14px !important;
	border: 0 !important;
	border-radius: 999px !important;
	background: #1a1a1a !important;
	background-image: none !important;
	color: #fff !important;
	font-family: 'Google Sans', system-ui, sans-serif !important;
	font-size: 12px !important;
	font-weight: 500 !important;
	line-height: 1.2 !important;
	letter-spacing: 0 !important;
	text-transform: none !important;
	text-decoration: none !important;
	box-shadow: none !important;
	cursor: pointer;
	transition: background-color .15s ease;
}
.tfc-block button.tfc-zoom:hover,
.tfc-block button.tfc-zoom:focus,
.tfc-block button.tfc-zoom:focus-visible,
.tfc-block button.tfc-zoom:active {
	background: #3d3d3d !important;
	color: #fff !important;
	border: 0 !important;
	outline: none !important;
	box-shadow: none !important;
}
.tfc-block .tfc-zoom-ico { font-size: 12px; line-height: 1; }

/* engraving field */
.tfc-field { padding: 0 12px 14px; display: flex; flex-direction: column; gap: 8px; border: 1px solid #1a1a1a; border-top: 0; background: #fbfbfb; }
.tfc-extra .tfc-field[hidden] { display: none; }
.tfc-field-line { display: flex; align-items: center; gap: 10px; padding-top: 12px; }
.tfc-text-input {
	flex: 1; padding: 11px 13px; font-size: 15px;
	font-family: 'Google Sans', system-ui, sans-serif;
	border: 1px solid #d8d8d8; border-radius: 0; background: #fff; color: #1a1a1a;
	box-shadow: none; margin: 0; height: auto; line-height: 1.4;
}
.tfc-text-input:focus { border-color: #1a1a1a; outline: none; box-shadow: none; }
.tfc-counter { font-size: 12px; color: #8a8a8a; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tfc-hint { font-size: 12px; color: #8a8a8a; line-height: 1.5; }
.tfc-hint.is-error { color: #b42318; }

/* summary */
.tfc-summary { margin-top: 34px; border: 1px solid #ededed; padding: 18px; }
.tfc-summary-line { display: flex; justify-content: space-between; gap: 14px; font-size: 14px; color: #4a4a4a; padding: 5px 0; }
.tfc-summary-line span:last-child { font-variant-numeric: tabular-nums; }
.tfc-summary-div { height: 1px; background: #ededed; margin: 12px 0; }
.tfc-summary-total { display: flex; justify-content: space-between; align-items: baseline; gap: 14px; }
.tfc-summary-total > span:first-child { font-size: 15px; font-weight: 700; }
.tfc-total { font-size: 26px; font-weight: 600; font-variant-numeric: tabular-nums; }
.tfc-total .woocommerce-Price-amount { font-weight: 600; }

.tfc-note { margin-top: 10px; font-size: 12.5px; color: #8a8a8a; line-height: 1.6; }

/* lightbox */
.tfc-lightbox {
	position: fixed; inset: 0; top: 0; right: 0; bottom: 0; left: 0;
	width: 100vw; height: 100vh; max-width: none; margin: 0;
	z-index: 2147483000;
	background: rgba(12, 12, 12, 0.88);
	-webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px);
	display: flex; align-items: center; justify-content: center;
	padding: 24px; overflow-y: auto; cursor: zoom-out;
}
.tfc-lightbox[hidden] { display: none; }
.tfc-lightbox-inner { position: relative; width: 100%; max-width: 780px; display: flex; flex-direction: column; align-items: center; gap: 14px; }
.tfc-lightbox-img { width: 100%; height: 70vh; background: center/contain no-repeat; }
.tfc-lightbox-cap { color: #f2f2f2; font: 500 15px/1.4 'Google Sans', system-ui, sans-serif; text-align: center; }
.tfc-lightbox-close {
	position: fixed; top: 18px; inset-inline-start: 18px;
	width: 44px; height: 44px; border-radius: 50%; border: 0;
	background: #fff; color: #1a1a1a; font-size: 20px; line-height: 1;
	display: flex; align-items: center; justify-content: center;
	cursor: pointer; box-shadow: 0 2px 12px rgba(0, 0, 0, 0.4); z-index: 2;
}
.tfc-lightbox-close:hover { background: #ededed; }

/* mobile */
@media (max-width: 991px) {
	.tfc-block { margin-top: 22px; }
	.tfc-block .tfc-row {
		grid-template-columns: 18px 56px minmax(0, 1fr) auto !important;
		gap: 10px !important;
		padding: 11px !important;
	}
	.tfc-block .tfc-thumb { width: 56px !important; height: 56px !important; }
	.tfc-block .tfc-label { font-size: 14.5px; }
	.tfc-block .tfc-sub { font-size: 12px; }
	.tfc-block .tfc-price { font-size: 13.5px !important; text-align: left; }
	.tfc-block .tfc-price.is-muted { font-size: 12.5px !important; }
	.tfc-block button.tfc-zoom { padding: 7px 12px !important; }
	.tfc-lightbox-img { height: 58vh; }
	.tfc-total { font-size: 23px; }
	.tfc-field-line { flex-wrap: wrap; }
	.tfc-text-input { flex: 1 1 100%; }
}

@media (max-width: 420px) {
	.tfc-block .tfc-row { grid-template-columns: 18px 48px minmax(0, 1fr) auto !important; gap: 9px !important; }
	.tfc-block .tfc-thumb { width: 48px !important; height: 48px !important; }
	.tfc-block .tfc-label { font-size: 14px; }
	.tfc-block .tfc-price { font-size: 13px !important; }
}

/* ------- mobile hardening: theme rules must not restack the row ------- */
.tfc-block .tfc-row > * { grid-row: 1 !important; }
.tfc-block .tfc-row .tfc-dot { grid-column: 1 !important; }
.tfc-block .tfc-row .tfc-box { grid-column: 1 !important; }
.tfc-block .tfc-row .tfc-thumb { grid-column: 2 !important; }
.tfc-block .tfc-row .tfc-text { grid-column: 3 !important; width: auto !important; max-width: 100% !important; float: none !important; }
.tfc-block .tfc-row .tfc-price {
	grid-column: 4 !important;
	width: auto !important;
	max-width: none !important;
	padding: 0 !important;
	margin: 0 !important;
	float: none !important;
	display: block !important;
	justify-self: end !important;
	align-self: center !important;
	text-align: left !important;
}
.tfc-block .tfc-row .tfc-price .woocommerce-Price-amount { white-space: nowrap; }

/* ===================== generic template field types ===================== */
.tfc-info {
	background: #fafafa; border: 1px solid #ededed; padding: 14px 16px;
	font-size: 13.5px; line-height: 1.7; color: #4a4a4a; margin-bottom: 4px;
}
.tfc-textgroup { margin-bottom: 4px; }
.tfc-selectwrap { margin-bottom: 4px; }
.tfc-block .tfc-input-select {
	width: 100%; padding: 12px 13px; font-size: 15px;
	font-family: 'Google Sans', system-ui, sans-serif;
	border: 1px solid #d8d8d8; border-radius: 0; background: #fff; color: #1a1a1a;
	box-shadow: none; height: auto; line-height: 1.4; appearance: auto;
}
.tfc-block .tfc-input-select:focus { border-color: #1a1a1a; outline: none; box-shadow: none; }

/* ============================== step wizard ============================== */
.tfc-progress { margin: 4px 0 22px; }
.tfc-progress-label { font-size: 12px; font-weight: 600; letter-spacing: .04em; color: #8a8a8a; margin-bottom: 8px; }
.tfc-progress-track { height: 6px; background: #ededed; border-radius: 999px; overflow: hidden; }
.tfc-progress-bar { height: 100%; width: 0; background: #1a1a1a; border-radius: 999px; transition: width .35s cubic-bezier(.4,0,.2,1); }
.tfc-progress-steps { display: flex; gap: 6px; margin-top: 10px; }
.tfc-progress-dot { width: 8px; height: 8px; border-radius: 50%; background: #dcdcdc; transition: background-color .25s ease, transform .25s ease; }
.tfc-progress-dot.is-done { background: #1a1a1a; }
.tfc-progress-dot.is-active { background: #1a1a1a; transform: scale(1.35); }

.tfc-steps { position: relative; }
.tfc-step { animation: tfc-step-in .28s ease; }
.tfc-step .tfc-group-head { margin-top: 0; }
.tfc-step.tfc-step-error .tfc-text-input { border-color: #b42318; }
@keyframes tfc-step-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.tfc-wiz-nav {
	margin-top: 28px; padding: 18px; border: 1px solid #e6e6e6; border-radius: 14px;
	background: linear-gradient(180deg, #fff, #fafafa);
	box-shadow: 0 1px 2px rgba(0,0,0,.04);
	display: flex; flex-direction: column; gap: 14px;
}
.tfc-wiz-line {
	display: flex; align-items: baseline; justify-content: space-between; gap: 12px;
	padding-bottom: 14px; border-bottom: 1px dashed #e2e2e2;
}
.tfc-wiz-total-label { font-size: 13px; font-weight: 600; color: #8a8a8a; }
.tfc-wiz-amount { font-size: 26px; font-weight: 700; color: #1a1a1a; font-variant-numeric: tabular-nums; letter-spacing: -.01em; }
.tfc-wiz-btns { display: flex; gap: 10px; }
.tfc-wiz-btns .tfc-prev, .tfc-wiz-btns .tfc-next {
	-webkit-appearance: none; appearance: none;
	font-family: 'Google Sans', system-ui, sans-serif; font-weight: 600;
	cursor: pointer; border-radius: 10px; line-height: 1;
	transition: background-color .15s ease, color .15s ease, transform .05s ease;
}
.tfc-wiz-btns .tfc-prev:active, .tfc-wiz-btns .tfc-next:active { transform: translateY(1px); }
.tfc-wiz-btns .tfc-prev { flex: 0 0 auto; background: #fff; color: #1a1a1a; border: 1px solid #d8d8d8; padding: 15px 22px; font-size: 15px; }
.tfc-wiz-btns .tfc-prev:hover { background: #f2f2f2; }
.tfc-wiz-btns .tfc-next { flex: 1; background: #1a1a1a; color: #fff; border: 1px solid #1a1a1a; padding: 15px 24px; font-size: 16px; }
.tfc-wiz-btns .tfc-next:hover { background: #333; }
.tfc-wiz-btns .tfc-next.is-finish { background: #2ea44f; border-color: #2ea44f; }
.tfc-wiz-btns .tfc-next.is-finish:hover { background: #176a2e; }

/* swatches (compact chips, no images) */
.tfc-swatches { display: flex; flex-wrap: wrap; gap: 10px; }
.tfc-block .tfc-swatch {
	position: relative; display: inline-flex; flex-direction: column;
	align-items: center; justify-content: center; min-width: 62px;
	padding: 12px 18px; border: 1px solid #ededed; background: #fff;
	cursor: pointer; text-align: center; line-height: 1.2;
	transition: border-color .15s ease, background-color .15s ease, box-shadow .15s ease;
}
.tfc-block .tfc-swatch:hover { border-color: #c9c9c9; }
.tfc-block .tfc-swatch.is-selected { border-color: #1a1a1a; background: #fbfbfb; box-shadow: inset 0 0 0 1px #1a1a1a; }
.tfc-swatch .tfc-input-radio { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.tfc-swatch-label { font-size: 15px; font-weight: 600; }
.tfc-swatch-price { font-size: 11.5px; color: #8a8a8a; margin-top: 3px; }

@media (max-width: 480px) {
	.tfc-wiz-nav { padding: 16px; border-radius: 12px; }
	.tfc-wiz-amount { font-size: 23px; }
	.tfc-wiz-btns .tfc-prev { padding: 14px 16px; font-size: 14px; }
	.tfc-wiz-btns .tfc-next { padding: 14px 18px; font-size: 15px; }
}

/* ===================== rounded surfaces + positive pricing ===================== */
.tfc-block .tfc-head-title { font-size: 21px; letter-spacing: -.01em; }
.tfc-block .tfc-head-sub { font-size: 13.5px; }
.tfc-group-title { font-size: 16px; font-weight: 700; letter-spacing: 0; text-transform: none; }
.tfc-block .tfc-row { border-radius: 14px !important; }
.tfc-block .tfc-thumb { border-radius: 10px; }
.tfc-block .tfc-swatch { border-radius: 14px; }
.tfc-block .tfc-input-select { border-radius: 14px; }
.tfc-text-input { border-radius: 14px; }
.tfc-info { border-radius: 16px; }
.tfc-summary { border-radius: 18px; }

/* smaller, correctly-placed currency symbol on totals */
.tfc-total, .tfc-wiz-amount { display: inline-flex; direction: ltr; align-items: baseline; gap: 8px; }
.tfc-cur-sym { font-size: .68em; font-weight: 600; }
.tfc-summary-total .tfc-total { color: #2ea44f; }

/* option rows with no image collapse the thumbnail column */
.tfc-block .tfc-row--noimg { grid-template-columns: 20px minmax(0, 1fr) auto !important; }
.tfc-block .tfc-row--noimg .tfc-text { grid-column: 2 !important; }
.tfc-block .tfc-row--noimg .tfc-price { grid-column: 3 !important; }
@media (max-width: 991px) { .tfc-block .tfc-row--noimg { grid-template-columns: 18px minmax(0, 1fr) auto !important; } }
@media (max-width: 420px) { .tfc-block .tfc-row--noimg { grid-template-columns: 18px minmax(0, 1fr) auto !important; } }

/* wizard footer — positive green tone */
.tfc-wiz-nav { border-radius: 20px; }
.tfc-wiz-line { background: #f0faf3; border: 1px solid #cdeed6; border-radius: 16px; padding: 16px 18px; align-items: center; }
.tfc-wiz-total-label { color: #2f7d46; }
.tfc-wiz-amount { color: #2ea44f; }
.tfc-wiz-badge { align-self: flex-start; display: inline-flex; align-items: center; gap: 8px; background: #f0faf3; color: #2ea44f; border-radius: 999px; padding: 8px 15px; font-size: 13px; font-weight: 600; }
.tfc-wiz-badge-dot { width: 8px; height: 8px; border-radius: 50%; background: #2ea44f; }
.tfc-wiz-btns .tfc-prev, .tfc-wiz-btns .tfc-next { border-radius: 999px; }
.tfc-wiz-btns .tfc-next:hover, .tfc-wiz-btns .tfc-next:focus, .tfc-wiz-btns .tfc-next:focus-visible, .tfc-wiz-btns .tfc-next:active { color: #fff !important; }

/* when the wizard is active, the theme's own add-to-cart button is replaced by it */
.tfc-block[data-wizard] ~ .single_add_to_cart_button,
.tfc-block[data-wizard] ~ * .single_add_to_cart_button,
.tfc-block[data-wizard] ~ .quantity,
.tfc-block[data-wizard] ~ * .quantity { display: none !important; }

/* wizard quantity stepper */
.tfc-wiz-qty { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.tfc-wiz-qty-label { font-size: 14px; font-weight: 600; color: #1a1a1a; }
.tfc-stepper { display: inline-flex; align-items: center; border: 1px solid #d8d8d8; border-radius: 999px; overflow: hidden; background: #fff; }
.tfc-stepper button {
	-webkit-appearance: none; appearance: none; border: 0; background: transparent;
	width: 42px; height: 44px; font-size: 20px; line-height: 1; cursor: pointer; color: #1a1a1a;
	font-family: 'Google Sans', system-ui, sans-serif; transition: background-color .15s ease;
}
.tfc-stepper button:hover { background: #f2f2f2; }
.tfc-stepper .tfc-qty-input {
	width: 52px; height: 44px; border: 0; border-inline: 1px solid #ededed; text-align: center;
	font-size: 16px; font-weight: 600; background: #fff; color: #1a1a1a;
	-moz-appearance: textfield; padding: 0; border-radius: 0;
}
.tfc-stepper .tfc-qty-input::-webkit-outer-spin-button,
.tfc-stepper .tfc-qty-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }


/* ===================== v1.3 — colour / symbol / font swatches, notes, live preview ===================== */
@font-face { font-family: 'BA Askenaz'; src: url('../fonts/BA-Askenaz.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: 'BA Kolofon'; src: url('../fonts/BA-Kolofon.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: 'BA Shalhevet'; src: url('../fonts/BA-Shalhevet.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: 'BA Yoel'; src: url('../fonts/BA-Yoel.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: 'BA Ziporen Plus'; src: url('../fonts/BA-Ziporen-Plus.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: 'BA Afikoman'; src: url('../fonts/BA-Afikoman.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: 'BA Kolmus'; src: url('../fonts/BA-Kolmus.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: 'BA Platforma'; src: url('../fonts/BA-Platforma.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; }

.tfc-block .tfc-swatches--color { gap: 14px; }
.tfc-block .tfc-swatch--color, .tfc-block .tfc-swatch--color.is-selected { border: 0; background: transparent; box-shadow: none; padding: 0; min-width: 0; width: 66px; gap: 6px; }
.tfc-sw-dot { display: block; width: 44px; height: 44px; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(0,0,0,.12), 0 0 0 3px #fff, 0 0 0 4px #e3e3e3; transition: box-shadow .15s ease; }
.tfc-swatch--color.is-selected .tfc-sw-dot { box-shadow: inset 0 0 0 1px rgba(0,0,0,.12), 0 0 0 3px #fff, 0 0 0 5px #1a1a1a; }
.tfc-swatch--color .tfc-swatch-label { font-size: 12.5px; margin-top: 4px; }

.tfc-block .tfc-swatches--symbol, .tfc-block .tfc-swatches--font { display: grid; gap: 8px; }
.tfc-block .tfc-swatches--symbol { grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); }
.tfc-block .tfc-swatches--font { grid-template-columns: repeat(auto-fill, minmax(112px, 1fr)); }
.tfc-block .tfc-swatch--symbol, .tfc-block .tfc-swatch--font { min-width: 0; padding: 12px 6px 10px; gap: 6px; }
.tfc-sw-sym { display: block; width: 40px; height: 40px; background: #1a1a1a; -webkit-mask-size: contain; mask-size: contain; -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat; -webkit-mask-position: center; mask-position: center; }
.tfc-sw-none { display: flex; align-items: center; height: 40px; font-size: 24px; color: #8a8a8a; }
.tfc-sw-sample { display: flex; align-items: center; height: 32px; font-size: 24px; line-height: 1.2; }
.tfc-swatch--symbol .tfc-swatch-label, .tfc-swatch--font .tfc-swatch-label { font-size: 12px; font-weight: 500; }

.tfc-block .tfc-textarea {
	width: 100%; padding: 12px 14px; font-size: 15px; line-height: 1.5;
	font-family: 'Google Sans', system-ui, sans-serif;
	border: 1px solid #d8d8d8; border-radius: 14px; background: #fff; color: #1a1a1a;
	box-shadow: none; margin: 0; resize: vertical; min-height: 92px;
}
.tfc-block .tfc-textarea:focus { border-color: #1a1a1a; outline: none; }
.tfc-block .tfc-text-input[data-lang] { font-size: 22px; }
.tfc-textgroup .tfc-hint { margin-top: 6px; }

/* with / without customisation */
.tfc-choice { display: flex; gap: 3px; background: #f2f2f2; border-radius: 999px; padding: 3px; margin: 0 0 22px; }
.tfc-block .tfc-choice-opt { flex: 1; position: relative; display: flex; align-items: center; justify-content: center; text-align: center; padding: 11px 14px; border-radius: 999px; cursor: pointer; font-size: 14px; font-weight: 600; color: #4a4a4a; line-height: 1.2; margin: 0; transition: background-color .15s ease, color .15s ease; }
.tfc-block .tfc-choice-opt.is-selected { background: #1a1a1a; color: #fff; }
.tfc-choice-opt input { position: absolute; opacity: 0; width: 1px; height: 1px; margin: 0; pointer-events: none; }

/* ===================== v1.4 — related products + gift note ===================== */
.tfc-block button.tfc-more {
	-webkit-appearance: none; appearance: none;
	display: inline-flex !important; align-items: center !important; gap: 7px !important;
	width: auto !important; height: auto !important; min-height: 0 !important;
	margin: 8px 0 0 !important; padding: 6px 12px !important;
	border: 1px solid #d8d8d8 !important; border-radius: 999px !important;
	background: #fff !important; background-image: none !important; color: #1a1a1a !important;
	font-family: 'Google Sans', system-ui, sans-serif !important; font-size: 12px !important; font-weight: 500 !important;
	line-height: 1.2 !important; letter-spacing: 0 !important; text-transform: none !important;
	box-shadow: none !important; text-shadow: none !important; cursor: pointer;
	transition: border-color .15s ease;
}
.tfc-block button.tfc-more:hover, .tfc-block button.tfc-more:focus, .tfc-block button.tfc-more:focus-visible, .tfc-block button.tfc-more:active {
	border-color: #1a1a1a !important; background: #fff !important; color: #1a1a1a !important; outline: none !important; box-shadow: none !important;
}
.tfc-more-ico { display: inline-block; width: 6px; height: 6px; border-left: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: translateY(-2px) rotate(-45deg); transition: transform .2s ease; }
.tfc-more[aria-expanded="true"] .tfc-more-ico { transform: translateY(1px) rotate(135deg); }
.tfc-prod-desc { margin-top: 8px; padding: 14px 16px; background: #fafafa; border: 1px solid #ededed; border-radius: 14px; font-size: 13.5px; line-height: 1.7; color: #4a4a4a; }
.tfc-prod-desc[hidden] { display: none; }
.tfc-prod-desc p { margin: 0 0 8px; }
.tfc-prod-desc ul { margin: 0 0 8px; padding-inline-start: 18px; }
.tfc-block .tfc-prod-link { display: inline-block; margin-top: 2px; font-size: 12.5px; font-weight: 600; color: #1a1a1a; text-decoration: underline; text-underline-offset: 3px; }

.tfc-gift { display: flex; align-items: flex-start; gap: 14px; margin: 34px 0 4px; padding: 16px 18px; background: #f0faf3; border: 1px solid #cdeed6; border-radius: 16px; }
.tfc-gift--first { margin-top: 0; }
.tfc-gift-ico { flex-shrink: 0; width: 40px; height: 40px; border-radius: 50%; background: #2ea44f; color: #fff; display: flex; align-items: center; justify-content: center; }
.tfc-gift-ico svg { width: 20px; height: 20px; display: block; }
.tfc-gift-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; padding-top: 2px; }
.tfc-gift-title { font-size: 15px; font-weight: 700; line-height: 1.35; color: #2ea44f; }
.tfc-gift-text { font-size: 13.5px; line-height: 1.65; color: #2f5a3c; }


/* ===================== v1.6 — steps, green selection, ataras, image symbols, summary, sticky bar ===================== */

/* steps: divider + number (green once answered) */
.tfc-block .tfc-group-head { flex-wrap: wrap; }
.tfc-block .tfc-group-head--spaced { margin-top: 28px; padding-top: 26px; border-top: 1px solid #e6e6e6; }
.tfc-block .tfc-group-title { display: flex; align-items: center; gap: 8px; }
.tfc-num { flex-shrink: 0; width: 22px; height: 22px; border-radius: 50%; border: 1px solid #c9c9c9; display: inline-flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 600; line-height: 1; color: #4a4a4a; }
.tfc-num:empty { display: none; }
.tfc-num.is-done { background: #2ea44f; border-color: #2ea44f; color: #fff; }
.tfc-group-head--kid { margin-top: 16px; }

/* missing field after an add-to-cart attempt */
.tfc-group-head.is-err .tfc-group-title { color: #b42318; }
.tfc-group-head.is-err .tfc-num { border-color: #b42318; color: #b42318; background: #fff; }
.tfc-emsg { flex-basis: 100%; margin-top: 6px; font-size: 12.5px; font-weight: 600; color: #b42318; }
.tfc-emsg[hidden] { display: none; }
.tfc-textgroup.is-err .tfc-text-input { border-color: #b42318; }
.tfc-hint.is-warn { color: #b42318; font-weight: 600; }

/* selected = one thin green line everywhere */
.tfc-block .tfc-row.is-selected { border-color: #2ea44f !important; background: #f0faf3 !important; }
.tfc-row.is-selected .tfc-dot { border-color: #2ea44f; }
.tfc-row.is-selected .tfc-dot > span { background: #2ea44f; }
.tfc-row.is-selected .tfc-box { border-color: #2ea44f; background: #2ea44f; }
.tfc-block .tfc-swatch.is-selected { border-color: #2ea44f; background: #f0faf3; box-shadow: none; }
.tfc-block .tfc-swatch--color.is-selected { border: 0; background: transparent; }
.tfc-swatch--color.is-selected .tfc-sw-dot { box-shadow: inset 0 0 0 1px rgba(0,0,0,.12), 0 0 0 3px #fff, 0 0 0 4px #2ea44f; }
.tfc-block .tfc-swatch:has(input:focus-visible), .tfc-block .tfc-row:has(input:focus-visible), .tfc-confirm:has(input:focus-visible) { outline: 2px solid #1a1a1a; outline-offset: 2px; }

/* thread colours: five per row, photo of the thread */
.tfc-block .tfc-swatches--color { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px 8px; }
.tfc-block .tfc-swatch--color, .tfc-block .tfc-swatch--color.is-selected { width: auto; min-width: 0; }

/* symbols shown as their own image; three per row when the group asks for it */
.tfc-sw-img { display: block; width: 72px; height: 72px; object-fit: contain; }
.tfc-block .tfc-swatches--cols3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.tfc-swatches--cols3 .tfc-sw-img { width: 100%; max-width: 140px; height: auto; aspect-ratio: 1 / 1; }

/* fonts shown as a sample image */
.tfc-block .tfc-swatches--font:has(.tfc-sw-fimg) { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.tfc-block .tfc-swatches--font .tfc-swatch:has(.tfc-sw-fimg) { padding: 14px 10px 10px; }
.tfc-sw-fimg { display: block; width: 100%; height: 48px; object-fit: contain; mix-blend-mode: multiply; }

/* ataras: wide image cards, two per row, magnifier opens the lightbox */
.tfc-bans { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.tfc-block .tfc-ban { position: relative; display: flex; flex-direction: column; justify-content: space-between; align-items: stretch; gap: 10px; min-width: 0; padding: 12px; border: 1px solid #ededed; border-radius: 14px; background: #fff; text-align: right; cursor: pointer; line-height: 1.3; }
.tfc-block .tfc-ban:hover { border-color: #c9c9c9; }
.tfc-block .tfc-ban.is-selected { border-color: #2ea44f; background: #f0faf3; }
.tfc-ban-h { display: flex; align-items: center; gap: 10px; padding-left: 30px; }
.tfc-ban.is-selected .tfc-dot { border-color: #2ea44f; }
.tfc-ban.is-selected .tfc-dot > span { background: #2ea44f; }
.tfc-ban-l { font-size: 14px; font-weight: 600; }
.tfc-ban-img { display: block; width: 100%; height: auto; mix-blend-mode: multiply; }
.tfc-block button.tfc-ban-zoom {
	-webkit-appearance: none; appearance: none;
	position: absolute !important; top: 6px; left: 6px; width: 32px !important; height: 32px !important; min-height: 0 !important;
	margin: 0 !important; padding: 0 !important; display: flex !important; align-items: center !important; justify-content: center !important;
	border: 0 !important; border-radius: 0 !important; background: transparent !important; box-shadow: none !important;
	color: #8a8a8a !important; cursor: zoom-in; transition: color .15s ease;
}
.tfc-block button.tfc-ban-zoom:hover, .tfc-block button.tfc-ban-zoom:focus-visible { color: #1a1a1a !important; }

/* fields that open from an add-on sit right under its row */
.tfc-block .tfc-extra.has-kids .tfc-row.is-selected { border-radius: 14px 14px 0 0 !important; }
.tfc-extra .tfc-row:not(.is-selected) + .tfc-kids { display: none; }
.tfc-kids { margin-top: -1px; padding: 2px 14px 16px; border: 1px solid #2ea44f; border-top: 0; border-radius: 0 0 14px 14px; background: #f7fbf8; }
.tfc-kids .tfc-swatch { background: #fff; }

/* summary: every choice, then prices */
.tfc-sum-t { font-size: 15px; font-weight: 700; margin-bottom: 8px; }
.tfc-choice-line { display: flex; justify-content: space-between; gap: 14px; font-size: 13.5px; padding: 4px 0; }
.tfc-choice-l { color: #6b6b6b; }
.tfc-choice-v { font-weight: 600; text-align: left; }
.tfc-choice-v.is-miss { color: #b42318; }
.tfc-choices:empty + .tfc-summary-div { display: none; }

/* "checked the spelling" confirmation */
.tfc-confirm { position: relative; display: flex; align-items: center; gap: 10px; margin-top: 14px; padding: 12px 14px; border: 1px solid #ededed; border-radius: 14px; background: #fff; cursor: pointer; font-size: 14px; font-weight: 600; line-height: 1.4; }
.tfc-confirm input { position: absolute; opacity: 0; width: 1px; height: 1px; margin: 0; pointer-events: none; }
.tfc-confirm.is-on { border-color: #2ea44f; background: #f0faf3; }
.tfc-confirm.is-on .tfc-box { border-color: #2ea44f; background: #2ea44f; }
.tfc-confirm.is-on .tfc-box::after { content: '\2713'; color: #fff; font-size: 12px; line-height: 1; }
.tfc-confirm.is-err { border-color: #b42318; }
.tfc-confirm-err { margin-top: 8px; }
.tfc-cta-err { flex-basis: 100%; width: 100%; margin-top: 10px; font-size: 13px; font-weight: 600; color: #b42318; }
.tfc-cta-err[hidden] { display: none; }

/* options must stay clickable whatever the theme does to labels / hidden inputs */
.tfc-block label.tfc-swatch, .tfc-block label.tfc-row, .tfc-block label.tfc-confirm { pointer-events: auto !important; cursor: pointer; }
.tfc-block .tfc-swatch *, .tfc-block .tfc-row *, .tfc-block .tfc-confirm * { pointer-events: auto; }
.tfc-block .tfc-input-radio, .tfc-block .tfc-input-check, .tfc-confirm input { pointer-events: none !important; }

/* selected look straight from the input state too (works even before / without the script) */
.tfc-block .tfc-swatch:has(input:checked) { border-color: #2ea44f; background: #f0faf3; }
.tfc-block .tfc-swatch--color:has(input:checked) { border: 0; background: transparent; }
.tfc-block .tfc-swatch--color:has(input:checked) .tfc-sw-dot { box-shadow: inset 0 0 0 1px rgba(0,0,0,.12), 0 0 0 3px #fff, 0 0 0 4px #2ea44f; }
.tfc-block .tfc-row:has(input:checked) { border-color: #2ea44f !important; background: #f0faf3 !important; }
.tfc-block .tfc-row:has(input:checked) .tfc-dot { border-color: #2ea44f; }
.tfc-block .tfc-row:has(input:checked) .tfc-dot > span { background: #2ea44f; }
.tfc-block .tfc-ban:has(input:checked) .tfc-dot { border-color: #2ea44f; }
.tfc-block .tfc-ban:has(input:checked) .tfc-dot > span { background: #2ea44f; }

/* ===================== v1.6.2 — multi-copy pages, Woodmart, text fields ===================== */

/* conditional groups start hidden (server-rendered) until their parent choice is made */
.tfc-block .tfc-group-head.tfc-off, .tfc-block .tfc-group-head.tfc-off + * { display: none; }

/* placeholder must not look like a typed value */
.tfc-block .tfc-text-input::placeholder, .tfc-block .tfc-textarea::placeholder { color: #9a9a9a !important; opacity: 1; }
.tfc-block .tfc-text-input[data-lang]::placeholder { font-size: 18px; }
.tfc-block .tfc-textarea::placeholder { font-size: 14px; }

/* counter under the field, on the hint's row (hint right, counter left) */
.tfc-block .tfc-textgroup .tfc-field-line { flex-wrap: nowrap; }
.tfc-block .tfc-textgroup .tfc-text-input { flex: 1 1 100%; }
.tfc-field-meta { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-top: 6px; }
.tfc-field-meta .tfc-hint { margin: 0; }
.tfc-field-meta .tfc-counter { margin-inline-start: auto; }

/* Woodmart: no sticky add-to-cart on customized products (the plugin also removes it), page bottom back to normal */
body:has(.tfc-block) .wd-sticky-btn { display: none !important; }
body:has(.tfc-block).wd-sticky-btn-on { padding-bottom: 0 !important; }
body:has(.tfc-block) .scrollToTop.wd-sticky-btn-shown { bottom: 20px !important; }

/* Elementor/Woodmart: a wishlist heart placed beside the add-to-cart column sits at the bottom, next to the button, instead of mid-block */
.elementor :has(> * .tfc-block) > :has(.wd-single-wishlist-btn):not(:has(.tfc-block)) { align-self: flex-end !important; }

/* a text input's built-in width (~20 characters at 22px) must never widen the block: inside a flex
   page-builder column that pushed the whole mobile page wider than the screen */
.tfc-block { min-width: 0; max-width: 100%; }
.tfc-block .tfc-text-input, .tfc-block .tfc-textarea { width: 100%; min-width: 0; max-width: 100%; }
.tfc-block .tfc-field-line { min-width: 0; }

/* ===================== v1.7 — red note, options per row, file upload ===================== */
.tfc-block .tfc-group-note--red { color: #d63638; font-weight: 600; }
.tfc-block .tfc-swatches.tfc-swatches--cols2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.tfc-block .tfc-swatches.tfc-swatches--cols3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.tfc-block .tfc-swatches.tfc-swatches--cols4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.tfc-block .tfc-swatches.tfc-swatches--cols5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.tfc-block .tfc-swatches.tfc-swatches--cols6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.tfc-block .tfc-swatches[class*="--cols"] .tfc-sw-fimg { width: 100%; height: auto; }
.tfc-block .tfc-filegroup { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; }
.tfc-block .tfc-file-btn { position: relative; display: inline-flex; align-items: center; padding: 10px 18px; border: 1px solid #c9c9c9; border-radius: 10px; background: #fff; font-size: 14px; cursor: pointer; }
.tfc-block .tfc-file-btn:hover, .tfc-block .tfc-file-btn:focus-within { border-color: #2ea44f; }
.tfc-block .tfc-file-input { position: absolute; inset: 0; opacity: 0; width: 100%; cursor: pointer; }
.tfc-block .tfc-file-name { font-size: 13px; color: #555; word-break: break-all; }
.tfc-block .tfc-file-name.is-ok { color: #2ea44f; }
.tfc-block .tfc-file-name.is-err { color: #d63638; }
.tfc-block .tfc-filegroup .tfc-field-meta { flex-basis: 100%; }
