/* ---------------------------------------------------------------------------
   Reset + base typography - light corporate theme
   --------------------------------------------------------------------------- */

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-sans);
  font-weight: var(--fw-regular);
  font-size: var(--fs-base);
  line-height: var(--lh-normal);
  letter-spacing: var(--ls-normal);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

body.aps-menu-open { overflow: hidden; }

img, svg, video { max-width: 100%; height: auto; display: block; }

/* Body links run at 17px, which is small text - so they take the ink, not the
   brand orange. Footer links set their own colour and are unaffected. */
a {
  color: var(--color-orange-ink);
  text-decoration: none;
  transition: color var(--t-base) var(--ease);
}
a:hover { color: var(--color-orange-ink-dark); }

:focus-visible {
  outline: 2px solid var(--color-orange);
  outline-offset: 3px;
}

/* --- headings: navy and confident. Thin weights disappear on white. --- */
h1, h2, h3, h4, h5, h6 {
  margin: 0 0 var(--space-4);
  color: var(--color-heading);
  font-family: var(--font-sans);
  line-height: var(--lh-tight);
  letter-spacing: var(--ls-tight);
}

h1 {
  font-size: var(--fs-3xl);
  font-weight: var(--fw-display);
  letter-spacing: var(--ls-display);
  line-height: var(--lh-display);
}
h2 {
  font-size: var(--fs-2xl);
  font-weight: var(--fw-heading);
  letter-spacing: var(--ls-display);
}
h3 { font-size: var(--fs-xl);  font-weight: var(--fw-heading); }
h4 { font-size: var(--fs-lg);  font-weight: var(--fw-heading-sm); }
h5 { font-size: var(--fs-md);  font-weight: var(--fw-heading-sm); }
h6 {
  font-size: var(--fs-base);
  font-weight: var(--fw-semibold);
  letter-spacing: var(--ls-wide);
  text-transform: uppercase;
}

p { margin: 0 0 var(--space-4); }
p:last-child { margin-bottom: 0; }

small { font-size: var(--fs-xs); }

ul, ol { margin: 0 0 var(--space-4); padding-inline-start: 1.25rem; }

hr {
  border: 0;
  border-top: 1px solid var(--color-border);
  margin: var(--space-7) 0;
}

::selection {
  background: var(--color-orange);
  color: #fff;
}

/* --- section title: navy word + orange word + orange rule --- */
.aps-title { margin-bottom: var(--space-6); }
.aps-title__text {
  font-size: var(--fs-2xl);
  font-weight: var(--fw-heading);
  letter-spacing: var(--ls-display);
  line-height: var(--lh-tight);
  color: var(--color-heading);
}
/* The accent word carries the same weight as the lead - contrast comes from
   colour here, and a second weight change makes the pair look accidental. */
.aps-title__accent { font-weight: inherit; }
.aps-title__accent { color: var(--color-orange); }
.aps-title__rule {
  display: block;
  width: 56px;
  height: 3px;
  margin-top: var(--space-3);
  border-radius: 2px;
  background: var(--color-orange);
}

/* --- layout helpers --- */
.aps-container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--container-pad);
}

.aps-section { padding-block: var(--space-9); position: relative; }

/* --header-h-real is measured from the live header by app.js, so the offset is
   exact in both languages and after the web fonts land. The static tokens stay
   as the no-JS fallback. */
.aps-site-main { min-height: 60vh; padding-top: var(--header-h-real, var(--header-h)); }
@media (max-width: 900px) {
  .aps-site-main { padding-top: var(--header-h-real, var(--header-h-mobile)); }
}

.screen-reader-text {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  inset-inline-start: -9999px;
  top: 0;
  z-index: 1100;
  padding: var(--space-3) var(--space-5);
  background: var(--color-orange);
  color: #fff;
}
.skip-link:focus { inset-inline-start: 0; }

/* --- buttons: orange primary, navy outline secondary --- */
.aps-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-5);
  border: 1px solid var(--color-navy);
  border-radius: var(--radius-pill);
  background: transparent;
  color: var(--color-navy);
  font-family: inherit;
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  letter-spacing: var(--ls-wide);
  cursor: pointer;
  transition: border-color var(--t-base) var(--ease),
              background   var(--t-base) var(--ease),
              color        var(--t-base) var(--ease),
              box-shadow   var(--t-base) var(--ease);
}
.aps-btn:hover {
  border-color: var(--color-navy-dark);
  background: var(--color-navy);
  color: #fff;
}
.aps-btn--primary {
  border-color: var(--color-orange);
  background: var(--color-orange);
  color: #fff;
  box-shadow: var(--shadow-sm);
}
.aps-btn--primary:hover {
  border-color: var(--color-orange-dark);
  background: var(--color-orange-dark);
  color: #fff;
  box-shadow: var(--shadow-md);
}

/* --- cards: white, soft shadow, hairline border, orange on hover --- */
.aps-card {
  padding: var(--space-6);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  background: var(--color-bg);
  box-shadow: var(--shadow);
  transition: border-color var(--t-slow) var(--ease),
              box-shadow   var(--t-slow) var(--ease),
              transform    var(--t-slow) var(--ease);
}
.aps-card:hover {
  border-color: var(--color-orange);
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

/* --- scroll reveal: fade + slide-up, driven by app.js --- */
[data-reveal] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity var(--t-slower) var(--ease),
              transform var(--t-slower) var(--ease);
}
[data-reveal].is-visible { opacity: 1; transform: none; }

.no-js [data-reveal] { opacity: 1; transform: none; }

/* --- editor content coming from Elementor / the_content --- */
.aps-entry-content > *:last-child { margin-bottom: 0; }
.aps-entry-content a { color: var(--color-orange-ink); }
.aps-entry-content a:hover { color: var(--color-orange-ink-dark); }

/* A plain page renders its title and its body as two stacked .aps-section
   blocks, so the gap under the title was being paid for twice. */
.aps-page > .aps-section + .aps-entry-content.aps-section { padding-block-start: 0; }
.aps-page > .aps-section > .aps-title { margin-bottom: 0; }
/* ...and the band that follows the intro brings its own top padding. */
.aps-entry-content--intro.aps-section { padding-block-end: 0; }

/* Headings inside body copy sit below the page title in the hierarchy - at the
   raw h2 size they compete with it. Scoped to the plain-page wrapper so
   Elementor layouts, which share .aps-entry-content, keep their own sizes. */
.aps-entry-content.aps-section h2,
.aps-entry-content.aps-section h3 {
  margin: var(--space-6) 0 var(--space-2);
  color: var(--color-navy);
  font-size: var(--fs-lg);
  font-weight: var(--fw-heading-sm);
}
.aps-entry-content.aps-section h3 { font-size: var(--fs-md); }
html[dir="rtl"] .aps-entry-content.aps-section h2,
html[dir="rtl"] .aps-entry-content.aps-section h3 { letter-spacing: 0; line-height: 1.35; }
.aps-entry-content.aps-section p { margin-bottom: var(--space-4); line-height: var(--lh-loose); }
