/*
 * Copyright 2020 Adobe. All rights reserved.
 * 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.
 */

.eds-content-styles {
  --static-color-white: #fff;
  --static-color-black: #000;
  --primary-color: #036;
  --secondary-color: #1B824F;
  --neutral-color-light: #F1F1F1;
  --neutral-color-medium: #D9D9D9;
  --neutral-color-dark: #080808;
  --sony-blue: rgb(0 51 102 / 100%);
  --sony-purple: #61358C;

  /* colors */
  --link-color: #2F5EDE;
  --background-color: var(--static-color-white);
  --overlay-background-color: var(--neutral-color-light);
  --highlight-background-color: var(--neutral-color-medium);
  --text-color: var(--neutral-color-dark);

  /* D2 colors */
  --light-gray-1: #F7F7F7;
  --light-gray-2: #E8E8E8;
  --sony-dark-gray: #63666A;
  --sony-light-gray: #B1B3B3;

  /* borders */
  --border-medium: 1px solid var(--neutral-color-medium);
  --border-primary: 1px solid var(--primary-color);

  /* fonts */
  --body-font-family: sst-roman, sst-roman-fallback, 'Arial', 'Helvetica', 'Helvetica Neue', sans-serif;
  --heading-font-family: sst-light, sst-roman-fallback, 'Arial', 'Helvetica', 'Helvetica Neue', sans-serif;
  --fixed-font-family: 'Roboto Mono', menlo, consolas, 'Liberation Mono', monospace;
  --quote-font-family: 'Times New Roman', serif;
  --luma-icons-font-family: 'luma-icons';

  /* body sizes */
  --body-font-size-l: 18px;
  --body-font-size-m: 16px;
  --body-font-size-s: 14px;
  --body-font-size-xs: 12px;
  --body-font-size-xxs: 10px;

  /* heading sizes */
  --heading-font-size-xxl: 52px;

  /* 20px; */
  --heading-font-size-xl: 40px;

  /* 16px; */
  --heading-font-size-l: 36px;

  /* 14px; */
  --heading-font-size-m: 26px;

  /* 12px; */
  --heading-font-size-s: 20px;

  /* 12px; */
  --heading-font-size-xs: 18px;

  /* 12px; */

  /* layout sizes */
  --layout-size-xxs: 4px;
  --layout-size-xs: 8px;
  --layout-size-s: 12px;
  --layout-size-m: 16px;
  --layout-size-l: 20px;
  --layout-size-xl: 24px;
  --layout-size-xxl: 48px;

  /* shared card tokens */
  --card-border: 1px solid rgb(232 232 232 / 100%);
  --card-shadow: 0 5px 36px 0 rgb(0 0 0 / 5%);
  --card-shadow-hover: 0 10px 40px rgb(0 0 0 / 12%);
  --card-radius: 0;
  --card-padding: 30px;
  --card-gap: 10px;
  --card-eyebrow-size: 14px;
  --card-eyebrow-line: 16px;
  --card-eyebrow-color: #63666A;
  --card-title-size: 18px;
  --card-title-line: 22px;
  --card-body-size: 16px;
  --card-body-line: 24px;
  --card-link-size: 16px;
  --card-link-line: 24px;
  --card-link-color: #2F5EDE;
  --card-link-gap: 4px;
  --card-link-arrow-offset: 1px;

  /* nav height */
  --nav-height: 116px;

  /* breadcrumbs height */
  --breadcrumbs-height: 30px;
  --footer-spacing: 120px;

  /* section margins */
  --section-margins: 40px;
  --row-gap: 20px;
  --column-gap: 20px;
  --content-width: 960px;

  /* max content width for wide/desktop (homepage & preview blocks) */
  --container-max-width: 1440px;
  --section-max-width: 1376px;

  /* horizontal paddings for containers */

  /* Desktop: 32px outer margin (via calc) + 38px inner padding = 70px total */

  /* Mobile/Tablet: 0px outer margin + 38px inner padding = 38px total */
  --container-outer-margin: 32px;
  --container-padding-desktop: 38px;
  --container-padding-mobile: 38px;
}

@media (width < 768px) {
  .eds-content-styles {
    /* heading sizes */
    --heading-font-size-xxl: 40px;
    --heading-font-size-xl: 32px;
    --heading-font-size-l: 30px;
    --heading-font-size-m: 22px;
    --heading-font-size-s: 20px;
    --heading-font-size-xs: 18px;
  }
}

.eds-content-styles [hidden] {
  display: none !important;
}

html {
  height: 100%;
  scroll-behavior: smooth;
}

body.eds-content-styles {
  height: 100%;
  font-size: var(--body-font-size-s);
  margin: 0;
  font-family: var(--body-font-family);
  line-height: 1.5;
  color: var(--text-color);
  background-color: var(--background-color);
  overflow-x: hidden;
  overflow-x: clip;
  display: none;
}

body.eds-content-styles main {
  padding-bottom: var(--footer-spacing);
}

body.appear.eds-content-styles {
  display: block;
}

body.eds-content-styles>.page-wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100%;
}

body:not(.eds-content-styles)>.page-wrapper>.page-wrapper {
  flex: 1;
}

.eds-content-styles header,
header.eds-content-styles {
  height: var(--nav-height);
}

.eds-content-styles h1,
.eds-content-styles h2,
.eds-content-styles h3,
.eds-content-styles h4,
.eds-content-styles h5,
.eds-content-styles h6 {
  font-family: var(--heading-font-family);
  font-weight: 600;
  line-height: 1.25;
  margin-top: 1em;
  margin-bottom: .5em;
  scroll-margin: calc(var(--nav-height) + 1em);
}

.eds-content-styles h1 {
  font-family: sst-light, sst-roman-fallback, Arial, Helvetica, 'Helvetica Neue', sans-serif;
  font-size: var(--heading-font-size-xxl);
  margin: var(--layout-size-xxs) 0 var(--layout-size-xs) 0;
  font-weight: 300;
  padding-bottom: 12px;
  position: relative;
  display: inline-block;
}


.eds-content-styles h2 {
  font-family: sst-medium, sst-roman-fallback, Arial, Helvetica, 'Helvetica Neue', sans-serif;
  font-size: var(--heading-font-size-xl);
  font-weight: 500;
}

.eds-content-styles h3 {
  font-family: sst-medium, sst-roman-fallback, Arial, Helvetica, 'Helvetica Neue', sans-serif;
  font-size: var(--heading-font-size-l);
  font-weight: 500;
}

.eds-content-styles h4 {
  font-family: sst-bold, sst-roman-fallback, Arial, Helvetica, 'Helvetica Neue', sans-serif;
  font-size: var(--heading-font-size-m);
  font-weight: 700;
}

.eds-content-styles h5 {
  font-family: sst-bold, sst-roman-fallback, Arial, Helvetica, 'Helvetica Neue', sans-serif;
  font-size: var(--heading-font-size-s);
  font-weight: 700;
}

.eds-content-styles h6 {
  font-family: sst-bold, sst-roman-fallback, Arial, Helvetica, 'Helvetica Neue', sans-serif;
  font-size: var(--heading-font-size-xs);
  font-weight: 700;
}

.eds-content-styles h7,
.eds-content-styles .h7 {
  font-family: sst-bold, sst-roman-fallback, Arial, Helvetica, 'Helvetica Neue', sans-serif;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.25;
  margin-top: 1em;
  margin-bottom: .5em;
  display: block;
  scroll-margin: calc(var(--nav-height) + 1em);
}

.eds-content-styles .p1,
.eds-content-styles p.p1 {
  font-family: sst-roman, sst-roman-fallback, Arial, Helvetica, 'Helvetica Neue', sans-serif;
  font-size: var(--body-font-size-m);
}

.eds-content-styles .p1 strong,
.eds-content-styles p.p1 strong {
  font-family: sst-bold, sst-roman-fallback, Arial, Helvetica, 'Helvetica Neue', sans-serif;
  font-size: var(--body-font-size-m);
  font-weight: 700;
}

.eds-content-styles .p2,
.eds-content-styles p.p2 {
  font-family: sst-roman, sst-roman-fallback, Arial, Helvetica, 'Helvetica Neue', sans-serif;
  font-size: var(--body-font-size-s);
}

.eds-content-styles .p3,
.eds-content-styles p.p3 {
  font-family: sst-roman, sst-roman-fallback, Arial, Helvetica, 'Helvetica Neue', sans-serif;
  font-size: var(--body-font-size-xs);
}

.eds-content-styles p,
.eds-content-styles dl,
.eds-content-styles ol,
.eds-content-styles ul,
.eds-content-styles pre,
.eds-content-styles blockquote {
  margin-top: 1em;
  margin-bottom: 1em;
}

.eds-content-styles hr {
  margin-top: 1.5em;
  margin-bottom: 1.5em;
  border: 0;
  border-bottom: var(--border-medium);
}

/* links */
.eds-content-styles a {
  color: var(--link-color);
  text-decoration: none;
}

.eds-content-styles a:hover {
  text-decoration: underline;
  color: var(--static-color-black);
}

/* download-links section styling */
.eds-content-styles .download-links ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
}

.eds-content-styles .download-links li {
  margin: 0;
}

.eds-content-styles .download-links a {
  color: #1a73e8;
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.eds-content-styles .download-links a::after {
  content: '';
  display: inline-block;
  width: 20px;
  height: 20px;
  background-image: url('/icons/button-download.svg');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

.eds-content-styles .download-links a:hover {
  color: #0d5bb5;
  text-decoration: none;
}

/* buttons */
.eds-content-styles a.button:any-link,
.eds-content-styles button {
  height: 34px;
  font-family: var(--body-font-family);
  display: inline-flex;
  gap: var(--layout-size-xs);
  align-items: center;
  box-sizing: border-box;
  text-decoration: none;
  border: none;
  padding: 5px 15px;
  text-align: center;
  font-size: var(--body-font-size-m);
  font-style: normal;
  font-weight: 500;
  cursor: pointer;
  color: var(--static-color-white);
  background-color: var(--link-color);
  margin: var(--layout-size-m) 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  border-radius: 0;
}

.eds-content-styles a.button:any-link:hover,
.eds-content-styles button:hover {
  background-color: var(--static-color-black);
}

.eds-content-styles button:not(.primary) {
  box-shadow: none;
}

.eds-content-styles .button-large a.button,
.eds-content-styles .button-large button {
  height: 43px;
}

.eds-content-styles a.button.primary:hover,
.eds-content-styles a.button.primary:focus,
.eds-content-styles button.primary:hover:not(.ds-widgets button),
.eds-content-styles button.primary:focus:not(.ds-widgets button) {
  background-color: var(--link-color);
}

.eds-content-styles a.button.secondary,
.eds-content-styles button.secondary {
  background-color: var(--static-color-white);
  color: var(--link-color);
  border: 1px solid var(--link-color);
}

.eds-content-styles a.button.secondary:hover,
.eds-content-styles button.secondary:hover {
  color: var(--static-color-black);
  border: 1px solid var(--static-color-black);
  background-color: #fff;
}

.eds-content-styles a.button[disabled],
.eds-content-styles button[disabled] {
  opacity: .5;
  pointer-events: none;
}

.eds-content-styles a.button span.icon {
  width: 17px;
  height: auto;
}

.eds-content-styles .button-large a.button span.icon {
  width: 30px;
}

.eds-content-styles a.button.icon-button {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 33px;
  padding: 0;
  justify-content: center;
}

/* forms */
.eds-content-styles input {
  font-family: var(--body-font-family);
  font-size: var(--body-font-size-m);
}

.eds-content-styles main input {
  font-size: var(--body-font-size-m);
  width: 100%;
  max-width: 50rem;
  display: block;
  margin-bottom: 1rem;
  padding: 0.75rem 0.6rem;
  border-radius: 0.25rem;
  box-sizing: border-box;
  border: 1px solid var(--text-color);
  color: var(--text-color);
  background-color: var(--background-color);
}

.eds-content-styles main input:hover {
  border: 1px solid var(--text-color);
}

.eds-content-styles main input[type="radio"],
.eds-content-styles main input[type="checkbox"] {
  accent-color: var(--primary-color);
}

.eds-content-styles main select {
  appearance: none;
  background: var(--static-color-white) url("../icons/select-bg.svg") no-repeat 100% 45%;
  border: 1px solid #ccc;
  height: var(--layout-size-xxl);
  border-radius: 1px;
  font-family: var(--body-font-family);
  font-size: var(--body-font-size-s);
  line-height: 1.4286;
  padding: 5px 25px 4px 10px;
}

.eds-content-styles main blockquote {
  font-style: italic;
  margin: 3rem;
  text-indent: -1rem;
  hanging-punctuation: first;
}

.eds-content-styles main blockquote p::before {
  content: "“";
  line-height: 0;
}

.eds-content-styles main blockquote p::after {
  content: "”";
  line-height: 0;
}

.eds-content-styles main img {
  max-width: 100%;
  width: auto;
  height: auto;
}

.eds-content-styles .icon {
  display: inline-block;
  height: 24px;
  width: 24px;
}

.eds-content-styles .icon img {
  height: 100%;
  width: 100%;
}

/* Standard width for all sections - can be overridden by specific blocks */

/* Excludes home page which needs full width */

/* Mobile: full width with padding */
body.eds-content-styles:not(.home) main>.section:not(.hero-container)>div {
  max-width: 100%;
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--container-padding-mobile);
  padding-right: var(--container-padding-mobile);
  box-sizing: border-box;
}

/* Desktop: match hero structure with outer margins + inner padding */
@media (width >=768px) {
  body.eds-content-styles:not(.home) main>.section:not(.hero-container)>div {
    width: calc(100% - (var(--container-outer-margin) * 2));
    max-width: var(--section-max-width);
    padding-left: var(--container-padding-desktop);
    padding-right: var(--container-padding-desktop);
  }
}

/* Ensure accordion content stays within section bounds */
.eds-content-styles main>.section .accordion {
  max-width: 100%;
  box-sizing: border-box;
}

.eds-content-styles main>.section.no-border {
  border-top: none;
  border-bottom: none;
}

.eds-content-styles main>.section.no-spacing {
  padding: 0;
}

.eds-content-styles main>.section:first-child {
  padding-top: 0;
}

.eds-content-styles main>.section:last-child {
  padding-bottom: 0;
  border-style: none;
}

/* Full-bleed section background image */
body.eds-content-styles main>.section.section-background {
  position: relative;
  z-index: 0;
  isolation: isolate;
}

body.eds-content-styles main>.breadcrumbs-container {
  position: relative;
  z-index: 1;
  background: transparent;
}

body.eds-content-styles main>.section.section-background::before {
  content: '';
  position: absolute;
  inset: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100vw;
  max-width: 100vw;
  background-image: var(--section-bg-image);
  background-size: var(--section-bg-size, cover);
  background-position: var(--section-bg-position, center);
  background-repeat: no-repeat;
  pointer-events: none;
  z-index: -1;
}

body.eds-content-styles main>.breadcrumbs-container+.section.section-background::before {
  top: calc(-1 * (var(--breadcrumbs-height) + var(--section-bg-bleed, 0px)));
  height: min(1000px, calc(100% + var(--breadcrumbs-height) + var(--section-bg-bleed, 0px)));
}

body.eds-content-styles main>.section.section-background::before {
  top: calc(-1 * var(--section-bg-bleed, 0px));
  height: min(1000px, calc(100% + var(--section-bg-bleed, 0px)));
}

body.eds-content-styles main>.section.section-background.section-background-last::before {
  height: min(1000px, calc(100% + var(--footer-spacing) + var(--section-bg-bleed, 0px)));
}

@media (width <= 768px) {
  body.eds-content-styles main>.section.section-background::before {
    background-image: var(--section-bg-image-mobile, var(--section-bg-image));
  }
}

/** resources section */
.eds-content-styles main>.section.resources ul {
  margin-top: var(--layout-size-xs);
  padding-inline-start: 0;
  list-style: none;
  font-size: var(--body-font-size-xs);
  border-bottom: var(--border-medium);
}

.eds-content-styles main>.section.resources ul>li {
  margin-bottom: 1em;
}

.eds-content-styles main>.section.resources ul>li a {
  font-size: var(--body-font-size-s);
}

.eds-content-styles main>.section.resources ul>li>ul {
  padding-inline-start: 30px;
  border-bottom: none;
}

/* overlay container */
.eds-content-styles .loading-overlay {
  display: flex;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgb(0 0 0 / 35%);
  z-index: 100;
  justify-content: center;
  align-items: center;
}

.eds-content-styles .loading-overlay>img {
  width: 75px;
  height: 75px;
}

/* main view */

.eds-content-styles main>.breadcrumbs-container {
  min-height: var(--breadcrumbs-height);
  padding: unset;
  border: unset;
}


/* Page hero - shared template hero banner */

/* Hidden until nav loads to prevent flash before top navigation */
.simple-header {
  display: none;
}

/* FOUC prevention: hide Magento-served page wrapper until EDS nav has loaded.
   Targets pages that get conditional EDS overrides (cart, checkout, account-create, order-success). */
body:is(.checkout-cart-index, .customer-account-create, .customer-account-createpassword, .checkout_index_index, .checkout-onepage-success) .page-wrapper {
  opacity: 0;
  transition: opacity 0.15s;
}

body.nav-loaded:is(.checkout-cart-index, .customer-account-create, .customer-account-createpassword, .checkout_index_index, .checkout-onepage-success) .page-wrapper {
  opacity: 1;
}

body.nav-loaded .simple-header {
  display: block;
  width: 100%;
  max-width: 100%;
  margin: 0 auto 10px;
  padding: 45px var(--container-padding-mobile);
  box-sizing: border-box;
  background-color: #f2f2f2;
  box-shadow: 0 0 0 100vmax #f2f2f2;
  clip-path: inset(0 -100vmax);
}

.simple-header-title {
  margin: 0 0 10px;
  font-size: 34px;
  line-height: 1.2;
  font-weight: 300;
  font-family: sst-light, sst-roman-fallback, Arial, Helvetica, 'Helvetica Neue', sans-serif;
}

.simple-header-title::after {
  content: none;
  display: none;
}

.simple-header-date {
  margin: 0;
  font-size: 26px;
  line-height: 30px;
}

.simple-header-date strong {
  font-family: sst-bold, sans-serif;
  font-weight: 700;
  color: #333;
}

.simple-header-date span {
  font-family: sst-light, sans-serif;
  font-weight: 300;
}

.eds-content-styles .simple-header .simple-header-date {
  font-size: 26px;
  line-height: 30px;
}

@media (width >= 768px) {
  body.nav-loaded .simple-header {
    width: calc(100% - (var(--container-outer-margin) * 2));
    max-width: var(--section-max-width);
    padding: 45px var(--container-padding-desktop);
  }
}

@media (width >= 1440px) {
  .simple-header-title {
    font-size: 52px;
    font-family: sst-light, sst-roman-fallback, Arial, Helvetica, 'Helvetica Neue', sans-serif;
  }

  body.nav-loaded .simple-header {
    padding-top: 45px;
    padding-bottom: 45px;
    margin-bottom: 10px;
  }
}

.eds-content-styles main .block.shadow img {
  box-shadow: 4px 4px 8px #dbdbdb;
}

.eds-content-styles main .centered-section {
  margin-bottom: var(--layout-size-xxl);
  max-width: var(--section-max-width);
  width: 100%;
  margin-left: auto;
  margin-right: auto;
}

/* home */
body.eds-content-styles.home .section.carousel-container {
  padding: unset;
}

body.eds-content-styles.home .section.articles-preview-container.events-preview-container {
  padding: unset;
}

body.eds-content-styles.home .section.articles-preview-container.events-preview-container>div {
  padding: var(--layout-size-m) var(--layout-size-l);
}

body.eds-content-styles.home .section.articles-preview-container.events-preview-container>div:nth-child(even) {
  background-color: var(--overlay-background-color);
}

body.eds-content-styles.home .section.articles-preview-container.events-preview-container h3 {
  margin-top: unset;
}

/* end home */

/* Banner status message */
main div.status-message {
  display: flex;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  align-items: center;
  min-height: 62px;
  margin: 0 auto var(--row-gap);
  padding: 0 20px 0 0;
  font-size: 13px;
}

/* Banner inserted directly under <main> (e.g., Magento mage messages via delayed.js) */
main > div.status-message {
  max-width: calc(100% - (var(--container-padding-mobile) * 2));
}

main div.status-message::before {
  font-size: 24px;
  font-family: var(--luma-icons-font-family);
  line-height: 24px;
  content: '\e61f';
  vertical-align: middle;
  text-align: center;
  position: relative;
  top: 1px;
  flex: 0 0 45px;
}

main div.status-message.success {
  background-color: #edfae5;
  color: #006400;
}

main div.status-message.success::before {
  content: '\e60e';
  color: #006400;
}

main div.status-message.warning {
  background-color: #fde6de;
  color: var(--static-color-black);
}

main div.status-message.warning::before {
  content: '\e602';
  color: #f15a24;
}

main div.status-message.error {
  background-color: #fae5e5;
  color: #e02b27;
}

main div.status-message.error::before {
  content: '\e61f';
  color: #b30000;
}


main div.status-message span {
  hyphens: auto;
}

@media (width >=768px) {
  main div.status-message {
    min-height: 42px;
  }

  main > div.status-message {
    max-width: calc(var(--section-max-width) - (var(--container-padding-desktop) * 2));
  }
}

/* breakpoints */
@media (width >=768px) {
  .eds-content-styles {
    --nav-height: 105px;
  }

  body.eds-content-styles.home main {
    background-color: var(--overlay-background-color);
  }

  body.eds-content-styles.home .section.articles-preview-container.events-preview-container {
    max-width: var(--container-max-width);
    margin: 0 auto;
    display: grid;
    grid-template:
      'articles-preview-wrapper articles-preview-wrapper events-preview-wrapper' auto / 1fr 1fr 1fr;
    grid-column-gap: var(--layout-size-l);
    background-color: var(--overlay-background-color);
    padding-bottom: calc(var(--layout-size-xl) * 2);
  }

  body.eds-content-styles.home .section.articles-preview-container.events-preview-container>.articles-preview-wrapper {
    grid-area: articles-preview-wrapper;
  }

  body.eds-content-styles.home .section.articles-preview-container.events-preview-container>.events-preview-wrapper {
    grid-area: events-preview-wrapper;
    position: relative;
  }

  body.eds-content-styles.home .section.articles-preview-container.events-preview-container>.events-preview-wrapper .see-all {
    position: absolute;
    bottom: var(--layout-size-m);
    right: var(--layout-size-l);
  }

  body.eds-content-styles.home .section.articles-preview-container.events-preview-container>div {
    padding: var(--layout-size-m) var(--layout-size-l);
    background-color: var(--static-color-white);
    border-top: 4px solid #06a3e4;
    margin-top: calc(var(--layout-size-xl) * -1);
    z-index: 2;
  }

  body.eds-content-styles.home .section.articles-preview-container.events-preview-container>div:nth-child(even) {
    background-color: var(--static-color-white);
  }
}

/* non eds content styles / commerce styles */
footer.page-footer {
  display: none;
}

body #skip-nav {
  color: var(--static-color-white);
  background-color: var(--sony-blue);
  text-decoration: none;
  padding: 12px 24px;
  display: block;
  position: absolute;
  margin: 20px;
  z-index: 1000;
  top: -200%;
  left: 50%;
  transform: translate(-50%, 0);
  transition: top 0.3s;
}

body #skip-nav:focus {
  top: 10%;
}

