/*
 * Copyright 2020 Adobe. All rights reserred.
 * This file is licensed to you under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License. You may obtain a copy
 * of the License at http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software distributed under
 * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
 * OF ANY KIND, either express or implied. See the License for the specific language
 * governing permissions and limitations under the License.
 */

:root {
  /* colors */
  --background-color: white;
  --light-color: #f8f8f8;
  --dark-color: #505050;
  --text-color: #131313;
  --text-color-secondary: #1B1B1B;
  --link-color: #3b63fb;
  --link-hover-color: #1d3ecf;
  --link-color-secondary: #0190a0;
  --link-hover-color-secondary: #0190a0;

  /* fonts */
  --body-font-family: 'Red Hat Display', red-hat-display-fallback, sans-serif;
  --heading-font-family: 'Red Hat Display', red-hat-display-fallback, sans-serif;

  /* body sizes */
  --body-font-size-m: 22px;
  --body-font-size-s: 19px;
  --body-font-size-xs: 17px;

  /* heading sizes */
  --heading-font-size-xxl: 55px;
  --heading-font-size-xl: 44px;
  --heading-font-size-l: 34px;
  --heading-font-size-m: 27px;
  --heading-font-size-s: 24px;
  --heading-font-size-xs: 22px;

  /* nav height */
  --nav-height: 76px;
}

/* fallback fonts */
@font-face {
  font-family: red-hat-display-fallback;
  size-adjust: 100%;
  ascent-override: 102%;
  descent-override: 30%;
  line-gap-override: 0%;
  src: local('Arial');
}

@media (width >= 900px) {
  :root {
    /* body sizes */
    --body-font-size-m: 18px;
    --body-font-size-s: 16px;
    --body-font-size-xs: 14px;

    /* heading sizes */
    --heading-font-size-xxl: 45px;
    --heading-font-size-xl: 36px;
    --heading-font-size-l: 28px;
    --heading-font-size-m: 22px;
    --heading-font-size-s: 20px;
    --heading-font-size-xs: 18px;
  }
}

body {
  display: none;
  margin: 0;
  background-color: var(--background-color);
  color: var(--text-color);
  font-family: var(--body-font-family);
  font-size: var(--body-font-size-m);
  line-height: 1.6;
}

body.appear {
  display: block;
}

body.loader-curtain-active header,
body.loader-curtain-active footer,
body.loader-curtain-active .marquesina-global-container {
  visibility: hidden;
}

/* Main stays painted (behind the loader's fixed overlay) so the browser
   counts its background-image for LCP immediately, instead of waiting
   until the loader dismisses.  The loader's position:fixed + z-index:9999
   + solid background already hides main visually from the user. */

/* Critical loader positioning — must be in render-blocking CSS so the loader
   overlays everything from the first frame, before cms-loader.css loads. */
.section.cms-loader-container {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  max-width: 100%;
  height: 100%;
  z-index: 9999;
  display: none;
  padding: 0 !important;
  margin: 0 !important;
  background-color: var(--color-gray-50);
}

/* Center loader content vertically and horizontally before cms-loader.css loads.
   aem.js wraps the block in .cms-loader-wrapper — it needs height to pass through. */
.section.cms-loader-container .cms-loader-wrapper {
  height: 100%;
  width: 100%;
}

.section.cms-loader-container .cms-loader {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 32px;
  height: 100%;
  width: 100%;
}

.section.cms-loader-container .cms-loader > div:first-child,
.section.cms-loader-container .cms-loader > div:first-child img,
.section.cms-loader-container .cms-loader > div:first-child picture {
  width: 100px;
  max-width: 100px;
  height: auto;
}

header {
  height: var(--nav-height);
  position: relative;
  z-index: 100;
}

header .header,
footer .footer {
  visibility: hidden;
}

header .header[data-block-status="loaded"],
footer .footer[data-block-status="loaded"] {
  visibility: visible;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin-top: 0.8em;
  margin-bottom: 0.25em;
  font-family: var(--heading-font-family);
  font-weight: 600;
  line-height: 1.25;
  scroll-margin: 40px;
}

h1 { font-size: var(--heading-font-size-xxl); }
h2 { font-size: var(--heading-font-size-xl); }
h3 { font-size: var(--heading-font-size-l); }
h4 { font-size: var(--heading-font-size-m); }
h5 { font-size: var(--heading-font-size-s); }
h6 { font-size: var(--heading-font-size-xs); }

/* H2 - Figma Design System Override (heading/H600) */
h2 {
  margin-top: 0;
  margin-bottom: 0;
  font-family: var(--family-red-hat-display, 'Red Hat Display');
  font-size: var(--size-x-large, 24px);
  font-style: normal;
  font-weight: 700;
  line-height: normal;
  letter-spacing: var(--letter-spacing-normal, 0);
  color: var(--text-color-secondary);
}

/* context-h1: production utility — h2 styled as h1 visual size */
.section.text-center h2 {
  font-size: var(--heading-font-size-xl);
  line-height: 1.25;
}

p,
dl,
ol,
ul,
pre,
blockquote {
  margin-top: 0.8em;
  margin-bottom: 0.25em;
}

code,
pre {
  font-size: var(--body-font-size-s);
}

pre {
  padding: 16px;
  border-radius: 8px;
  background-color: var(--light-color);
  overflow-x: auto;
  white-space: pre;
}

input,
textarea,
select,
button {
  font: inherit;
}

/* links */
a:any-link {
  /* color: var(--link-color);
  text-decoration: none;
  overflow-wrap: break-word; */
}

main > .section {
  max-width: 1248px;
  margin: auto;
  padding: 32px var(--main-section-div-padding, 16px);
}

main > .section:first-of-type {
  margin-top: 0;
}

/* section metadata */
main .section.light,
main .section.highlight {
  background-color: var(--light-color);
  margin: 0;
  padding: 40px 0;
}

main .section.center-content {
  display: flex;
  justify-content: center;
  align-items: center;
}

main .section.center-content > div {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
}

/* TODO: remove style, is only for client meet 17-12 - START */
.section.center-content:has(.default-content-wrapper) {
    padding: 0;
}
@media (max-width: 1247px) {
    .section.center-content:has(.default-content-wrapper) {
        padding-inline: var(--main-section-div-padding, 16px);
    }
}
/* TODO: remove style, is only for client meet 17-12 - END */

.section.layout-1-2-992 > div {
  display: flex;
  flex-direction: column;
}

main div.section.padding-title {
  padding: 0 16px;
  h1,h2,h3,h4,h5,h6 {
    margin: 0;
  }
}

.section.padding-bottom-40 {
  padding-bottom: 40px;
}
.section.no-padding-top {
  padding-top: 0;
}

.section.no-padding-y {
  padding-top: 0;
  padding-bottom: 0;
}

/* Desktop >= 992px */
@media (min-width: 992px) {
  .section.layout-1-2-992 {
    display: grid;
    grid-template-columns: minmax(280px, 1fr) minmax(320px, 1fr);
    grid-auto-rows: auto;
    gap: 24px;
    align-items: start;
  }

  /* first direct child div -> left column, span 2 rows */
  .section.layout-1-2-992 > div:first-child {
    grid-column: 1;
    grid-row: 1 / 3;
  }

  /* all other direct child divs -> right column, starting from row 1 */
  .section.layout-1-2-992 > div:nth-child(2) {
    grid-column: 2;
    grid-row: 1;
  }

  .section.layout-1-2-992 > div:nth-child(3) {
    grid-column: 2;
    grid-row: 2;
  }

  .section.layout-1-2-992 > div:nth-child(4) {
    grid-column: 2;
    grid-row: 3;
  }

  .section.layout-1-2-992 > div:nth-child(n+5) {
    grid-column: 2;
  }
}

/* Tablet and desktop media queries */
@media (width >= 480px) and (width <= 1247px) {
    :root {
        --main-section-div-padding: 32px;
    }

    main > .section > div {
        box-sizing: content-box;
    }
}

@media (width >= 1248px) {
    :root {
        --main-section-div-padding: 0;
    }
}
