/*
 * Suisse Int'l — SGS corporate typeface
 * ------------------------------------------------------------------
 * Web files copied from sgs.com (Swiss Typefaces, licensed).
 *
 * SGS ships only two cuts: Regular (400) and Bold (700), roman only.
 * The theme asks for 500 and 600 in places (menu, page titles, widget
 * titles, submenu). Rather than let browsers fake those with a
 * synthesized weight, the @font-face weight RANGES below map anything
 * up to 600 onto the real Regular cut, and 700+ onto the real Bold.
 * That is the same two-weight system sgs.com itself uses.
 *
 * The7 12.5 exposes every typeface as a CSS custom property, so this
 * file only redefines those variables. No !important, and icon fonts
 * (FontAwesome, icomoon-the7, Defaults) are untouched.
 *
 * Selector is :root:root purely to raise specificity above The7's own
 * :root block, so this wins regardless of stylesheet load order.
 */

@font-face {
	font-family: "Suisse Intl";
	font-style: normal;
	font-weight: 100 600;
	src: url("../fonts/SuisseIntl-Regular-WebS.woff2") format("woff2"),
	     url("../fonts/SuisseIntl-Regular-WebS.woff") format("woff");
	font-display: swap;
}

@font-face {
	font-family: "Suisse Intl";
	font-style: normal;
	font-weight: 700 900;
	src: url("../fonts/SuisseIntl-Bold-WebS.woff2") format("woff2"),
	     url("../fonts/SuisseIntl-Bold-WebS.woff") format("woff");
	font-display: swap;
}

:root {
	--iq-suisse: "Suisse Intl", "Helvetica Neue", Helvetica, Arial, sans-serif;
}

/* Every typeface The7 exposes, repointed at Suisse Int'l. */
:root:root {
	--the7-additional-logo-elements-font-family: var(--iq-suisse);
	--the7-additional-menu-elements-font-family: var(--iq-suisse);
	--the7-base-font-family: var(--iq-suisse);
	--the7-breadcrumbs-font-family: var(--iq-suisse);
	--the7-btn-l-font-family: var(--iq-suisse);
	--the7-btn-m-font-family: var(--iq-suisse);
	--the7-btn-s-font-family: var(--iq-suisse);
	--the7-close-menu-caption-font-family: var(--iq-suisse);
	--the7-close-mobile-menu-caption-font-family: var(--iq-suisse);
	--the7-filter-font-family: var(--iq-suisse);
	--the7-form-md-font-family: var(--iq-suisse);
	--the7-h1-font-family: var(--iq-suisse);
	--the7-h2-font-family: var(--iq-suisse);
	--the7-h3-font-family: var(--iq-suisse);
	--the7-h4-font-family: var(--iq-suisse);
	--the7-h5-font-family: var(--iq-suisse);
	--the7-h6-font-family: var(--iq-suisse);
	--the7-mega-menu-desc-font-family: var(--iq-suisse);
	--the7-mega-menu-title-font-family: var(--iq-suisse);
	--the7-menu-caption-font-family: var(--iq-suisse);
	--the7-menu-font-family: var(--iq-suisse);
	--the7-microwidget-button-2-font-family: var(--iq-suisse);
	--the7-microwidget-button-font-family: var(--iq-suisse);
	--the7-microwidgets-in-top-line-font-family: var(--iq-suisse);
	--the7-mobile-menu-caption-font-family: var(--iq-suisse);
	--the7-mobile-menu-font-family: var(--iq-suisse);
	--the7-mobile-menu-microwidgets-font-family: var(--iq-suisse);
	--the7-mobile-microwidgets-font-family: var(--iq-suisse);
	--the7-mobile-sub-menu-font-family: var(--iq-suisse);
	--the7-mw-search-font-family: var(--iq-suisse);
	--the7-page-title-font-family: var(--iq-suisse);
	--the7-sub-subtitle-font-family: var(--iq-suisse);
	--the7-submenu-font-family: var(--iq-suisse);
	--the7-subtitle-font-family: var(--iq-suisse);
	--the7-top-bar-font-family: var(--iq-suisse);
	--the7-widget-content-font-family: var(--iq-suisse);
	--the7-widget-title-font-family: var(--iq-suisse);
	--the7-woo-content-font-family: var(--iq-suisse);
	--the7-woo-title-font-family: var(--iq-suisse);
}

/* Form controls default to a system font in most browsers, and are not
   covered by The7's variables. */
body,
button,
input,
optgroup,
select,
textarea {
	font-family: var(--iq-suisse);
}

/* ------------------------------------------------------------------
 * Layer 2 — beat the other two things setting fonts on this site.
 *
 * 1. The "Fonts Plugin" (olympus-google-fonts) prints an inline <style>
 *    in wp_head pinning Calibri on body, headings, nav and form
 *    controls. Being inline it can land after this file, and it targets
 *    elements directly rather than The7's variables, so variables alone
 *    do not win. Its own rules carry no !important, but load order is
 *    not guaranteed — hence !important here.
 *
 *    (Worth noting Calibri is a Windows font: on macOS, iOS and Android
 *    it does not exist, so that plugin has effectively been serving
 *    Arial to most visitors.)
 *
 * 2. iq_child/style.css pins "Open Sans" with !important on three
 *    heading helper classes.
 *
 * Selectors below deliberately match elements only — never descendants
 * (`footer *` and friends), so icon fonts keep their own family.
 * ------------------------------------------------------------------ */

:root:root {
	--font-base: var(--iq-suisse);
	--font-headings: var(--iq-suisse);
	--font-input: var(--iq-suisse);
}

body,
#content, .entry-content, .post-content, .page-content,
.post-excerpt, .entry-summary, .entry-excerpt,
.widget-area, .widget, .sidebar, #sidebar,
footer, .footer, #footer, .site-footer,
#site-title, .site-title, #site-title a, .site-title a,
#site-description, .site-description, #site-tagline, .site-tagline,
.entry-title, .entry-title a,
h1, h2, h3, h4, h5, h6,
.widget-title, .elementor-heading-title,
.menu, .page_item a, .menu-item a,
button, .button, input, select, textarea,
.wp-block-button, .wp-block-button__link {
	font-family: var(--iq-suisse) !important;
}

/* Heading helpers in iq_child/style.css that pin Open Sans !important. */
.heading-2,
.heading-lrg,
.heading-lrger {
	font-family: var(--iq-suisse) !important;
}

/* NOT overridden on purpose: .testimonial-content and .quote use
   "Volkhov" (serif) as a deliberate editorial accent. Change those only
   if the brand guide says quotes should also be Suisse Int'l. */

/* ------------------------------------------------------------------
 * Layer 3 — rules that use the `font:` SHORTHAND with a literal stack.
 *
 * The7 generates most typography from its CSS variables, but a handful
 * of nav rules are emitted as e.g.
 *     .main-nav > li > a .menu-text { font: 600 16px/20px "Open Sans", ... }
 * A shorthand sets font-family as a normal-priority longhand, so it
 * ignores the variables entirely. An !important longhand beats it while
 * leaving the size/weight/line-height from the shorthand intact.
 *
 * These four selectors were identified empirically from the rendered
 * page, not guessed. If The7's CSS is regenerated and the nav still
 * looks wrong, re-check for new shorthand rules.
 * ------------------------------------------------------------------ */

.main-nav > li > a .menu-text,
.main-nav .sub-nav > li > a .menu-text,
.mobile-main-nav li > a .menu-text,
.dt-mobile-header .mobile-main-nav li .sub-nav > li > a .menu-text {
	font-family: var(--iq-suisse) !important;
}

/* LayerSlider defaults its text layers to Arial. Slider layers are
   absolutely positioned, so a typeface change can nudge text alignment —
   worth eyeballing the homepage slider after this. */
html body .ls-container .ls-layer,
html body .ls-container .ls-l,
#ls-global .ls-container .ls-layer,
#ls-global .ls-container .ls-l {
	font-family: var(--iq-suisse) !important;
}

/* ------------------------------------------------------------------
 * Header nav fit.
 *
 * Suisse Int'l sets slightly wider than the Open Sans it replaced. The
 * main nav sits in a fixed 754px track, and the seven items plus their
 * 12px side margins came to 758px — 4px over — so "Contacts" wrapped to
 * a second line and doubled the header height.
 *
 * Trimming the per-item margin from 12px to 9px recovers 42px (7 items x
 * 2 x 3px). That clears the wrap at 1366/1440 and also fixes ~1200px, which
 * wrapped on the old font too — so this is slightly better than the previous
 * behaviour, not just parity. Effective gap between items goes 36px -> 30px.
 *
 * Lives with the font change on purpose: it exists only because of it, so
 * reverting the typeface should revert this too.
 * ------------------------------------------------------------------ */

.main-nav > li {
	margin-left: 9px;
	margin-right: 9px;
}
