/*
 * Tourbillon Core - layout glue between Elementor containers and the Tourbillon theme styles.
 * Colours and fonts are the theme's CSS variables, so the widgets look exactly like the theme.
 */

/* Header and footer templates sit inside the theme's <header>/<footer>: let the theme colours show through */
.tb-header .e-con,
.tb-footer .e-con { --background-color: transparent; }
.tb-header .elementor,
.tb-footer .elementor { width: 100%; }

/* Header pieces */
.tb-el-logo { display: flex; }
.tb-header .elementor-widget-tourbillon-site-logo { flex-shrink: 0; }
.tb-header .elementor-widget-tourbillon-product-search { flex: 1 1 320px; }
.tb-header .elementor-widget-tourbillon-product-search .tb-search { max-width: 520px; margin-inline: auto; }
.tb-el-icons { display: flex; align-items: center; justify-content: flex-end; }
.tb-nav--plain { border-top: 0; }
.tb-nav .tb-menu { padding: 0; }

@media (max-width: 960px) {
	/* The search opens as a full-width row under the header, like the built-in header. */
	.tb-header .elementor-widget-tourbillon-product-search,
	.tb-header .elementor-widget-tourbillon-product-search > .elementor-widget-container { position: static; flex: 0 0 0; min-width: 0; }
	.tb-header .elementor-widget-tourbillon-nav-menu { flex: 0 0 0; min-width: 0; }
}

/* Footer pieces */
.tb-el-footer-col .tb-logo { margin-bottom: 18px; }
.tb-footer .elementor-widget-tourbillon-footer-bottom { width: 100%; }
.tb-el-dial { display: flex; justify-content: center; }
.tb-el-dial svg { display: block; width: 92px; height: auto; }

/*
 * Footer built from native Elementor widgets (Heading, Text Editor, Icon List, Social Icons).
 * The tb-ef-* classes give them the theme footer look; anything set in the widget's Style tab wins.
 */
.tb-footer .tb-ef-headline .elementor-heading-title { margin: 0; color: var(--tb-header-text); font-family: var(--tb-font-headings); font-size: clamp(1.4rem, 3vw, 2rem); font-weight: 400; line-height: 1.2; letter-spacing: .14em; text-transform: uppercase; }
.tb-footer .tb-ef-title .elementor-heading-title { margin: 0 0 .2em; color: var(--tb-header-text); font-family: var(--tb-font-headings); font-size: .8rem; font-weight: 400; line-height: 1.4; letter-spacing: .2em; text-transform: uppercase; }
.tb-footer .tb-ef-text,
.tb-footer .tb-ef-copy { color: var(--tb-footer-text); }
.tb-footer .tb-ef-text p,
.tb-footer .tb-ef-copy p { margin: 0; }
.tb-footer .tb-ef-copy { font-size: .8rem; }

.tb-footer .tb-ef-benefits,
.tb-footer .tb-ef-links,
.tb-footer .tb-ef-badges { --e-icon-list-icon-size: 16px; --icon-vertical-offset: 0; }
.tb-footer .tb-ef-benefits .elementor-icon-list-text,
.tb-footer .tb-ef-links .elementor-icon-list-text,
.tb-footer .tb-ef-badges .elementor-icon-list-text { color: var(--tb-footer-text); transition: color .2s; }
.tb-footer .tb-ef-benefits .elementor-icon-list-icon i,
.tb-footer .tb-ef-links .elementor-icon-list-icon i,
.tb-footer .tb-ef-badges .elementor-icon-list-icon i { color: var(--tb-accent); }
.tb-footer .tb-ef-links a:hover .elementor-icon-list-text { color: var(--tb-accent); }
.tb-footer .tb-ef-benefits .elementor-icon-list-items { gap: 10px 32px; justify-content: center; }
.tb-footer .tb-ef-benefits .elementor-icon-list-item { margin: 0 !important; font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; }
.tb-footer .tb-ef-links .elementor-icon-list-item { padding: .3em 0; }
.tb-footer .tb-ef-contact .elementor-icon-list-item { align-items: flex-start; }
.tb-footer .tb-ef-contact .elementor-icon-list-icon { margin-top: .25em; }
.tb-footer .tb-ef-badges { font-size: .8rem; }
.tb-footer .tb-ef-badges .elementor-icon-list-items { gap: 8px 22px; }
.tb-footer .tb-ef-badges .elementor-icon-list-item { margin: 0 !important; }
.tb-footer .tb-ef-benefits .elementor-icon-list-icon,
.tb-footer .tb-ef-links .elementor-icon-list-icon,
.tb-footer .tb-ef-badges .elementor-icon-list-icon { padding-inline-end: 8px; }

.tb-footer .tb-ef-social { --icon-size: 18px; --icon-padding: 10px; --grid-column-gap: 8px; margin-top: 2px; }
.tb-footer .tb-ef-social .elementor-social-icon { background: transparent; color: var(--tb-footer-text); border: 1px solid rgba(255, 255, 255, .15); transition: border-color .2s, color .2s; }
.tb-footer .tb-ef-social .elementor-social-icon i { color: inherit; }
.tb-footer .tb-ef-social .elementor-social-icon:hover { border-color: var(--tb-accent); color: var(--tb-accent); opacity: 1; }
.tb-footer .elementor-widget-tourbillon-site-logo .tb-logo { margin: 0; }

@media (max-width: 767px) {
	.tb-footer .tb-ef-bottom .elementor-widget-container { text-align: center; }
	.tb-footer .tb-ef-badges .elementor-icon-list-items { justify-content: center; }
}

/* Regular pages built from native widgets (Heading, Text Editor, Accordion) */
.tb-entry--builder { padding-bottom: var(--tb-section); }
.tb-el-heading .elementor-heading-title { color: var(--tb-headings); font-family: var(--tb-font-headings); font-weight: 500; line-height: 1.2; letter-spacing: var(--tb-heading-track); }
.tb-upper .tb-el-heading .elementor-heading-title { text-transform: uppercase; }
.tb-el-prose .tb-el-heading:not(:first-child) { margin-top: .5em; }
.tb-el-text p:last-child,
.tb-el-text ul:last-child,
.tb-el-text ol:last-child { margin-bottom: 0; }
.tb-el-faq .elementor-accordion .elementor-accordion-item { border: 0; border-bottom: 1px solid var(--tb-border); }
.tb-el-faq .elementor-accordion .elementor-accordion-item + .elementor-accordion-item { border-top: 0; }
.tb-el-faq .elementor-accordion .elementor-tab-title { padding: 20px 0; border: 0; }
.tb-el-faq .elementor-accordion .elementor-tab-title .elementor-accordion-title { color: var(--tb-headings); font-family: var(--tb-font-headings); font-size: 1.05rem; font-weight: 400; letter-spacing: .04em; text-transform: none; }
.tb-el-faq .elementor-accordion .elementor-accordion-icon { color: var(--tb-accent); font-size: 16px; }
.tb-el-faq .elementor-accordion .elementor-accordion-icon i { color: inherit; }
.tb-el-faq .elementor-accordion .elementor-tab-content { padding: 0 0 20px; border: 0; color: var(--tb-text); }
.tb-el-faq .elementor-tab-content p:last-child { margin-bottom: 0; }

/* Single product template */
.tb-el-product { padding-bottom: var(--tb-section); }
.tb-el-gallery { position: relative; }
.tb-el-gallery .woocommerce-product-gallery { width: auto !important; float: none !important; margin: 0 !important; }
.tb-el-gallery.tb-gallery-grid .woocommerce-product-gallery__wrapper { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.tb-el-gallery.tb-gallery-grid .woocommerce-product-gallery__image { display: block !important; width: auto !important; margin: 0 !important; padding: 0 !important; }
.tb-el-gallery.tb-gallery-grid .woocommerce-product-gallery__image:first-child { grid-column: 1 / -1; }
.tb-el-gallery .onsale { top: 16px; inset-inline-start: 16px; }
.tb-el-summary { width: auto !important; float: none !important; margin: 0 !important; }
.tb-el-summary .product_title { margin-bottom: .4em; font-size: clamp(1.6rem, 2.6vw, 2.2rem); text-transform: none !important; letter-spacing: .03em; }
.tb-el-summary p.price,
.tb-el-summary > span.price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; margin-bottom: 20px; color: var(--tb-headings); font-size: 1.55rem; }
@media (min-width: 961px) {
	.elementor-widget.tb-el-sticky-yes { position: sticky; top: calc(var(--tb-header-h, 170px) + 24px); align-self: flex-start; z-index: 2; }
	.admin-bar .elementor-widget.tb-el-sticky-yes { top: calc(var(--tb-header-h, 170px) + 56px); }
}
.tb-el-details .woocommerce-tabs { margin-top: 0; }
.tb-el-related .related.products,
.tb-el-related .upsells.products { margin-top: 0; }

/* Shop template */
.tb-el-shop .tb-shop-toolbar { margin-top: 0; }
.tb-el-filters { position: relative; }
@media (min-width: 961px) {
	.tb-el-filters .tb-side-close { display: none; }
}

/* WooCommerce pages inside Elementor */
.tb-el-wc-page > .woocommerce { width: 100%; }
