/* ==========================================================================
   Finnet theme — base.css
   Reset, html/body, typography, buttons, forms, WordPress content classes,
   helpers and the `.animate` reveal states.

   Values come from the captured reference (theme-option CSS + base look),
   re-authored with the tokens from tokens.css. Breakpoints are the
   reference's: desktop ≥1240 / laptop 960–1239 / tablet 768–959 / mobile ≤767
   (helpers `.hide-desktop` ≥1441 and `.hide-laptop` 960–1440 keep the
   reference ranges, which the 1440px screenshots depend on).

   JS contract (see also header.css):
   - main.js adds class `js` to <html> as its first statement. Only then are
     `.animate` elements hidden; without JS they stay visible.
   - When an `.animate` element enters the viewport, JS adds `is-visible`.
     The reveal is a keyframe animation so that the per-page
     `animation-delay` values the old builder exported keep working.
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Reset
   -------------------------------------------------------------------------- */
a, abbr, acronym, address, applet, article, aside, audio, b, blockquote, body,
canvas, caption, center, cite, code, del, details, dfn, div, em, embed,
fieldset, figcaption, figure, footer, form, h1, h2, h3, h4, h5, h6, header,
hgroup, html, i, iframe, img, ins, kbd, label, legend, li, mark, menu, nav,
object, ol, output, p, pre, q, ruby, s, samp, section, span, strike, strong,
summary, table, tbody, td, tfoot, th, thead, time, tr, tt, u, ul, var, video {
  margin: 0;
  padding: 0;
  border: 0;
  font-size: 100%;
  font: inherit;
  vertical-align: baseline;
}

article, aside, details, figcaption, figure, footer, header, hgroup, menu, nav, section {
  display: block;
}

ol, ul {
  list-style: none;
}

blockquote, q {
  quotes: none;
}

blockquote::before, blockquote::after,
q::before, q::after {
  content: "";
  content: none;
}

/* The reference keeps the default content-box model and lets every element
   inherit it; elements that need border-box set it explicitly. */
*, ::before, ::after {
  box-sizing: inherit;
  -webkit-font-smoothing: antialiased;
}

/* --------------------------------------------------------------------------
   2. html / body
   -------------------------------------------------------------------------- */
html {
  height: 100%;
  overflow-x: hidden;
  background-color: var(--fn-color-bg);
}

body {
  min-width: 960px;
  line-height: 1;
  background-color: var(--fn-color-bg);
  color: var(--fn-color-text);
  font-family: var(--fn-font-body);
  font-size: var(--fn-body-size);
  line-height: var(--fn-body-line);
  font-weight: var(--fn-body-weight);
  letter-spacing: var(--fn-body-spacing);
  -webkit-font-smoothing: antialiased;
  -webkit-text-size-adjust: 100%;
}

@media only screen and (max-width: 1239px) {
  body {
    min-width: 0;
  }
}

@media only screen and (max-width: 767px) {
  body.responsive-overflow-x-mobile {
    overflow-x: hidden;
  }
}

body.mobile-side-slide {
  position: relative;
}

/* the off-canvas menus sit outside the viewport; nothing may scroll sideways to reach them */
html, body { overflow-x: hidden; }
#Wrapper { overflow-x: clip; }

::-moz-selection {
  background-color: var(--fn-color-theme);
  color: var(--fn-color-white);
}

::selection {
  background-color: var(--fn-color-theme);
  color: var(--fn-color-white);
}

/* --------------------------------------------------------------------------
   3. Typography
   -------------------------------------------------------------------------- */
.big {
  font-size: var(--fn-body-size);
  line-height: var(--fn-body-line);
  font-weight: var(--fn-body-weight);
  letter-spacing: var(--fn-body-spacing);
}

h1, h2, h3, h4, h5, h6 {
  margin-bottom: var(--fn-heading-margin);
  color: var(--fn-color-theme);
}

h1, h2, h3, h4 {
  font-family: var(--fn-font-heading);
}

h5, h6 {
  font-family: var(--fn-font-body);
}

h1 { font-size: var(--fn-h1-size); line-height: var(--fn-h1-line); font-weight: var(--fn-h1-weight); letter-spacing: var(--fn-h1-spacing); }
h2 { font-size: var(--fn-h2-size); line-height: var(--fn-h2-line); font-weight: var(--fn-h2-weight); letter-spacing: var(--fn-h2-spacing); }
h3 { font-size: var(--fn-h3-size); line-height: var(--fn-h3-line); font-weight: var(--fn-h3-weight); letter-spacing: var(--fn-h3-spacing); }
h4 { font-size: var(--fn-h4-size); line-height: var(--fn-h4-line); font-weight: var(--fn-h4-weight); letter-spacing: var(--fn-h4-spacing); }
h5 { font-size: var(--fn-h5-size); line-height: var(--fn-h5-line); font-weight: var(--fn-h5-weight); letter-spacing: var(--fn-h5-spacing); }
h6 { font-size: var(--fn-h6-size); line-height: var(--fn-h6-line); font-weight: var(--fn-h6-weight); letter-spacing: var(--fn-h6-spacing); }

h1 a, h2 a, h3 a, h4 a, h5 a, h6 a {
  font-weight: inherit;
  color: var(--fn-color-theme);
}

h1 a:hover, h2 a:hover, h3 a:hover, h4 a:hover, h5 a:hover, h6 a:hover {
  color: var(--fn-color-theme);
  text-decoration: none;
}

p {
  margin: 0 0 var(--fn-paragraph-margin);
}

p a,
p a:visited {
  line-height: inherit;
}

em, i {
  font-style: italic;
}

b, strong, dt {
  font-weight: 700;
}

a,
a:focus,
a:visited {
  color: var(--fn-color-theme);
  text-decoration: none;
  outline: 0;
}

a:hover {
  color: var(--fn-color-accent-hover);
  text-decoration: underline;
}

@media only screen and (max-width: 1239px) {
  a[href^="tel"] {
    text-decoration: none;
  }
}

/* Code */
code, pre, q {
  font-family: var(--fn-font-mono);
  border: 1px solid #e8e8e8;
  background: var(--fn-color-white);
  border-radius: 3px;
}

code, q {
  padding: 2px 4px;
  margin: 0 2px;
  white-space: nowrap;
  color: var(--fn-color-code);
}

pre {
  display: block;
  padding: 21px 15px 20px;
  margin: 15px 0;
  line-height: 21px;
  white-space: pre-wrap;
}

code p, pre p {
  margin-bottom: 0;
}

/* Lists.
   Plain <ul> has no marker (reset). Lists inside text content get discs. */
ul {
  list-style: none outside;
}

ol {
  list-style: decimal;
}

.column_column ul,
.the_content_wrapper ul,
.post-excerpt ul,
.mfn-acc ul,
.icon_box ul,
ul.wp-block-list {
  list-style: disc outside;
  margin: 0 0 15px 30px;
}

.column_column ol,
.the_content_wrapper ol,
.post-excerpt ol,
.mfn-acc ol,
.icon_box ol,
ol.wp-block-list {
  margin: 0 0 15px 30px;
}

.column_column ul li, .column_column ol li,
.the_content_wrapper ul li, .the_content_wrapper ol li,
.post-excerpt ul li, .post-excerpt ol li,
.mfn-acc ul li, .mfn-acc ol li,
.icon_box ul li, .icon_box ol li,
.wp-block-list li {
  margin-bottom: 10px;
}

.column_column ul li ul, .column_column ol li ol,
.the_content_wrapper ul li ul, .the_content_wrapper ol li ol,
.post-excerpt ul li ul, .post-excerpt ol li ol,
.mfn-acc ul li ul, .mfn-acc ol li ol,
.icon_box ul li ul, .icon_box ol li ol,
.wp-block-list li ul, .wp-block-list li ol {
  margin-top: 10px;
  margin-bottom: 0;
}

.column_column ul, .column_column ol,
.the_content_wrapper ul, .the_content_wrapper ol {
  color: var(--fn-color-text);
}

/* Definition lists */
dl {
  margin: 0 0 30px;
}

dl > dt,
dl > dd {
  border-width: 1px 0 0;
  border-style: solid;
  border-color: var(--fn-color-border);
  padding: 8px 0;
  margin: 0;
}

dl > dt:first-of-type,
dl > dd:first-of-type {
  padding-top: 0;
  border-top-width: 0;
}

dl > dt {
  display: block;
  float: left;
  width: 100px;
}

dl > dd {
  margin-left: 110px;
}

dl > dd::after {
  content: "";
  display: block;
  clear: both;
}

/* Blockquote */
blockquote {
  display: block;
  position: relative;
  top: 15px;
  height: auto;
  margin: 0 0 35px 25px;
  font-family: var(--fn-font-body);
  font-size: var(--fn-blockquote-size);
  line-height: var(--fn-blockquote-line);
  color: var(--fn-color-text-quote);
}

blockquote a,
blockquote a:hover {
  color: var(--fn-color-text-quote);
}

/* Horizontal rules */
hr {
  display: block;
  clear: both;
  width: 100%;
  height: 1px;
  margin: 0 auto 15px;
  border: none;
  outline: none;
  background-color: var(--fn-color-border);
  color: var(--fn-color-border);
}

hr.no_line {
  background: none;
  color: transparent;
}

hr.hr_color,
.hr_color hr {
  background: var(--fn-color-theme);
  color: var(--fn-color-theme);
}

/* Tables (shadows are off: body.no-shadows) */
table {
  width: 100%;
  box-sizing: border-box;
  margin-bottom: 15px;
  border-collapse: collapse;
  border-spacing: 0;
  border-radius: 5px;
}

table td,
table th {
  padding: 10px;
  text-align: center;
  vertical-align: middle;
  border: 1px solid var(--fn-color-border);
}

table th {
  font-weight: 700;
  background: #f9f9f9;
  color: var(--fn-color-navy);
}

table tr:nth-child(2n) td {
  background: rgba(0, 0, 0, 0.01);
}

table.simple th {
  background: none;
}

table.simple td,
table.simple th {
  border-width: 0 0 1px;
}

table.simple tr:last-child td {
  border: none;
}

iframe {
  max-width: 100%;
}

/* --------------------------------------------------------------------------
   4. Buttons
   All colours/metrics come from the --mfn-button-* tokens so the imported
   per-item CSS (`.mcb-item-xxx .button{--mfn-button-bg:…}`) keeps working.
   -------------------------------------------------------------------------- */
button::-moz-focus-inner,
input::-moz-focus-inner {
  border: 0;
  padding: 0;
}

.button,
.wp-block-button__link,
button,
input[type="button"],
input[type="reset"],
input[type="submit"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--mfn-button-gap);
  position: relative;
  box-sizing: border-box;
  font-family: var(--mfn-button-font-family);
  font-size: var(--mfn-button-font-size);
  font-weight: var(--mfn-button-font-weight);
  font-style: var(--mfn-button-font-style);
  letter-spacing: var(--mfn-button-letter-spacing);
  line-height: 1.2;
  padding: var(--mfn-button-padding);
  border-width: var(--mfn-button-border-width);
  border-style: var(--mfn-button-border-style);
  border-radius: var(--mfn-button-border-radius);
  background-color: var(--mfn-button-bg);
  border-color: var(--mfn-button-border-color);
  color: var(--mfn-button-color);
  box-shadow: var(--mfn-button-box-shadow);
  outline: unset;
  text-decoration: none;
  cursor: pointer;
  overflow: hidden;
  transition:
    color var(--mfn-button-transition) ease-in-out,
    background-color var(--mfn-button-transition) ease-in-out,
    border-color var(--mfn-button-transition) ease-in-out;
}

.button i,
.wp-block-button__link i,
button i,
input[type="button"] i,
input[type="reset"] i,
input[type="submit"] i {
  color: var(--mfn-button-icon-color);
  transition: all var(--mfn-button-transition) ease-in-out;
}

.button:hover,
.button[aria-expanded="true"],
.wp-block-button__link:hover,
button:hover,
input[type="button"]:hover,
input[type="reset"]:hover {
  background-color: var(--mfn-button-bg-hover);
  border-color: var(--mfn-button-border-color-hover);
  color: var(--mfn-button-color-hover);
  text-decoration: none;
}

.button:hover i,
.wp-block-button__link:hover i,
button:hover i,
input[type="button"]:hover i,
input[type="reset"]:hover i {
  color: var(--mfn-button-icon-color-hover);
}

/* Theme-coloured button (and every submit input) */
.button_theme,
input[type="submit"] {
  background-color: var(--mfn-button-theme-bg);
  border-color: var(--mfn-button-theme-border-color);
  color: var(--mfn-button-theme-color);
  box-shadow: var(--mfn-button-theme-box-shadow);
}

.button_theme i,
input[type="submit"] i {
  color: var(--mfn-button-theme-icon-color);
}

.button_theme:hover,
input[type="submit"]:hover {
  background-color: var(--mfn-button-theme-bg-hover);
  border-color: var(--mfn-button-theme-border-color-hover);
  color: var(--mfn-button-theme-color-hover);
  text-decoration: none;
}

.button_theme:hover i,
input[type="submit"]:hover i {
  color: var(--mfn-button-theme-icon-color-hover);
}

/* Icon position: .button_left (default, icon first) / .button_right */
.button.button_right .button_icon,
button.button_right .button_icon {
  order: 1;
}

.button.button_full_width,
button.button_full_width,
input[type="submit"].button_full_width {
  width: 100%;
}

/* Size variants: button_size_2 is the default size */
.button_size_1 { transform: scale(0.9); }
.button_size_3 { transform: scale(1.1); }
.button_size_4 { transform: scale(1.2); }

.button.disabled,
.button:disabled,
.button[aria-disabled="true"],
button.disabled,
button:disabled,
button[aria-disabled="true"],
input[type="submit"]:disabled {
  cursor: not-allowed;
  opacity: 0.3;
}

/* Button element inside the builder */
.column_button .button {
  margin: 0 !important;  /* per-item CSS may set margins on .button */
  vertical-align: middle;
}

.gform_wrapper .button::after {
  content: unset;
}

/* --------------------------------------------------------------------------
   5. Forms
   -------------------------------------------------------------------------- */
fieldset, form {
  margin-bottom: 0;
}

label, legend {
  display: block;
  margin-bottom: 5px;
  font-weight: 500;
}

input[type="checkbox"],
input[type="checkbox"] ~ label {
  display: inline;
}

input[type="checkbox"] ~ label::before {
  content: " ";
}

input[type="date"],
input[type="email"],
input[type="number"],
input[type="password"],
input[type="search"],
input[type="tel"],
input[type="text"],
input[type="url"],
select,
textarea {
  display: block;
  width: 230px;
  max-width: 100%;
  margin: 0 0 20px;
  padding: 10px;
  box-sizing: border-box;
  font-family: var(--fn-font-body);
  font-size: 15px;
  color: var(--fn-color-input-text);
  background-color: var(--fn-color-white);
  border: 1px solid var(--fn-color-input-border);
  border-radius: 8px;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}

input[hidden],
select[hidden],
textarea[hidden] {
  display: none;
}

textarea {
  min-height: 60px;
  line-height: 20px;
}

input[type="date"]::-webkit-datetime-edit {
  font-size: 15px;
  line-height: 19px;
}

input[type="date"]::-webkit-calendar-picker-indicator {
  font-size: 80%;
}

::placeholder {
  color: var(--fn-color-input-text);
  opacity: 1;
}

input[type="date"]:focus,
input[type="email"]:focus,
input[type="number"]:focus,
input[type="password"]:focus,
input[type="search"]:focus,
input[type="tel"]:focus,
input[type="text"]:focus,
input[type="url"]:focus,
select:focus,
textarea:focus {
  color: var(--fn-color-input-focus);
  background-color: var(--fn-color-input-focus-bg);
  border-color: var(--fn-color-input-focus);
}

:focus::placeholder {
  color: var(--fn-color-input-focus);
}

/* Native select with our own chevron (the reference used a data-URI too) */
select {
  padding-right: 25px;
  background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20width%3D%2220%22%20height%3D%2220%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M5%206l5%205%205-5%202%201-7%207-7-7%202-1z%22%20fill%3D%22%23555%22%2F%3E%3C%2Fsvg%3E");
  background-repeat: no-repeat;
  background-position: right 5px top 55%;
}

select[multiple] {
  background-image: none;
}

/* Hidden submit buttons (header search forms) */
form input.display-none {
  display: none;
}

/* --------------------------------------------------------------------------
   6. WordPress content classes (block-library CSS is not enqueued)
   -------------------------------------------------------------------------- */
.alignleft {
  float: left;
  margin: 15px 15px 15px 0;
}

.alignright {
  float: right;
  margin: 15px 0 15px 15px;
}

.aligncenter {
  display: block;
  margin: 0 auto;
  text-align: center;
}

.aligncenter img {
  display: inline;
}

.aligncenter.image_frame {
  width: 100%;
}

.alignnone {
  float: none;
}

.alignwide {
  display: block;
  margin-left: auto;
  margin-right: auto;
}

.the_content_wrapper .wp-caption.aligncenter,
.the_content_wrapper .wp-caption.alignnone {
  clear: both;
}

.wp-caption-text {
  display: block;
  margin: 0;
  padding: 10px 0 5px;
  text-align: center;
  line-height: normal;
  background: var(--fn-color-caption-bg);
  color: var(--fn-color-caption-text);
}

.image_frame.no_border .wp-caption-text {
  padding: 10px 0;
}

/* Core blocks used in posts */
.wp-block-image {
  margin: 0 0 1em;
}

.wp-block-image img {
  max-width: 100%;
  height: auto;
  vertical-align: bottom;
  box-sizing: border-box;
}

.wp-block-image.aligncenter,
.wp-block-image .aligncenter {
  display: table;
  margin-left: auto;
  margin-right: auto;
}

.wp-block-image figcaption {
  margin-top: 0.5em;
  margin-bottom: 1em;
  font-size: 13px;
  text-align: center;
  color: var(--fn-color-text-muted);
}

.wp-block-heading {
  /* inherits h1–h6 styles; kept so the selector exists for per-post CSS */
  clear: both;
}

.wp-block-columns {
  display: flex;
  flex-wrap: wrap;
  align-items: normal;
  gap: 2em;
  margin-bottom: 1.75em;
  box-sizing: border-box;
}

.wp-block-column {
  flex: 1 1 0;
  min-width: 0;
  word-break: break-word;
  overflow-wrap: break-word;
}

@media (max-width: 781px) {
  .wp-block-columns:not(.is-not-stacked-on-mobile) > .wp-block-column {
    flex-basis: 100% !important; /* core uses inline flex-basis on columns */
  }
}

.wp-block-gallery {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin: 0 0 1em;
  list-style: none;
}

.wp-block-gallery > figure {
  flex: 1 1 calc(50% - 8px);
  margin: 0;
}

.wp-block-gallery img {
  width: 100%;
  height: auto;
  display: block;
}

.wp-block-table {
  margin: 0 0 1em;
  overflow-x: auto;
}

.wp-block-table table {
  margin-bottom: 0;
}

/* --------------------------------------------------------------------------
   7. Helpers
   -------------------------------------------------------------------------- */
.clearfix::before,
.clearfix::after {
  content: "\0020";
  display: block;
  height: 0;
  width: 0;
  overflow: hidden;
  visibility: hidden;
}

.clear,
.clearfix::after {
  clear: both;
}

/* Visibility helpers. The ranges are the reference's: the per-item CSS sets
   display:block on some of these elements, hence the !important. */
@media only screen and (min-width: 1441px) {
  .hide-desktop {
    display: none !important;
  }
}

@media only screen and (min-width: 960px) and (max-width: 1440px) {
  .hide-laptop {
    display: none !important;
  }
}

@media only screen and (min-width: 768px) and (max-width: 959px) {
  .hide-tablet {
    display: none !important;
  }
}

@media only screen and (max-width: 767px) {
  .hide-mobile {
    display: none !important;
  }
}

/* --------------------------------------------------------------------------
   8. Reveal on scroll (.animate + data-anim-type)
   Hidden only once JS has announced itself (html.js); JS adds `is-visible`.
   -------------------------------------------------------------------------- */
html.js .animate {
  opacity: 0;
}

html.js .animate.is-visible {
  animation: fn-reveal-fade var(--fn-reveal-duration) var(--fn-reveal-ease) both;
}

html.js .animate.is-visible[data-anim-type="fadeInLeft"]  { animation-name: fn-reveal-left; }
html.js .animate.is-visible[data-anim-type="fadeInRight"] { animation-name: fn-reveal-right; }
html.js .animate.is-visible[data-anim-type="fadeInUp"]    { animation-name: fn-reveal-up; }
html.js .animate.is-visible[data-anim-type="fadeInDown"]  { animation-name: fn-reveal-down; }

@keyframes fn-reveal-fade {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes fn-reveal-left {
  from { opacity: 0; transform: translateX(calc(var(--fn-reveal-offset) * -1)); }
  to   { opacity: 1; transform: translateX(0); }
}

@keyframes fn-reveal-right {
  from { opacity: 0; transform: translateX(var(--fn-reveal-offset)); }
  to   { opacity: 1; transform: translateX(0); }
}

@keyframes fn-reveal-up {
  from { opacity: 0; transform: translateY(var(--fn-reveal-offset)); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fn-reveal-down {
  from { opacity: 0; transform: translateY(calc(var(--fn-reveal-offset) * -1)); }
  to   { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  html.js .animate {
    opacity: 1;
  }
  html.js .animate.is-visible {
    animation: none;
  }
}

/* Inline SVG icons (header search, image zoom/link overlays) — the stroke style the markup used to carry */
svg .path { fill: none; stroke: #000; stroke-miterlimit: 10; stroke-width: 1.5px; }
.image_links svg .path { stroke: #333; }
