/*
 * Site-wide styles, loaded on every page.
 * Sections: fonts, global, header, navigation, footer.
 * Page-specific styles live in their own files (front-page.css, about.css, ...).
 */

/* ==========================================================================
   Fonts (self-hosted Archivo variable font, weights 100–700)
   ========================================================================== */

/* latin-ext */
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 100 700;
  font-stretch: 100%;
  font-display: swap;
  src: url("../fonts/archivo-latin-ext.woff2") format("woff2");
  unicode-range:
    U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304,
    U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB,
    U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* latin */
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 100 700;
  font-stretch: 100%;
  font-display: swap;
  src: url("../fonts/archivo-latin.woff2") format("woff2");
  unicode-range:
    U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
    U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212,
    U+2215, U+FEFF, U+FFFD;
}

/* ==========================================================================
   Global
   ========================================================================== */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Archivo", sans-serif;
  line-height: 1.6;
  color: #000000;
  background-color: #fff;
}

a {
  text-decoration: none;
}

.bottom-bar-fill {
  display: none;
}

@keyframes image-shimmer {
  from {
    background-position: 100% 0;
  }
  to {
    background-position: 0% 0;
  }
}

.is-img-loading {
  background-color: #f2f2f2;
  background-image: linear-gradient(
    90deg,
    #f2f2f2 33.33%,
    #f9f9f9 50%,
    #f2f2f2 66.67%
  );
  background-size: 300% 100%;
  animation: image-shimmer 1.8s linear infinite;
}

.is-ios-safari .bottom-bar-fill {
  display: block;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 10px;
  margin: 0;
  background: #fff;
  z-index: 2000;
  pointer-events: none;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  line-height: 1.2;
  margin-bottom: 0.5em;
}

h1,
.hero-title {
  line-height: 1.2;
}

h1.hero-title {
  font-size: 2.4vw;
  margin: 0;
  font-weight: 400;
  max-width: 26ch;
}

p.hero-title {
  font-size: 1.4vw;
  max-width: 60ch;
  margin-top: 0.5rem;
}

h2 {
  font-size: 1.875rem;
  font-weight: 400;
}

h3 {
  font-size: 1.625rem;
  font-weight: 400;
}

.site-content {
  padding: 0;
}

.post {
  margin-bottom: 2rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid #ddd;
}

.post-title {
  margin-bottom: 0.5rem;
}

.post-meta {
  font-size: 0.875rem;
  color: #666;
  margin-bottom: 1rem;
}

.post-content {
  line-height: 1.8;
}

.post-content img {
  max-width: 100%;
  height: auto;
  display: block;
}

.widget {
  margin-bottom: 2rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid #ddd;
}

.widget-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.widget ul {
  list-style: none;
}

.widget ul li {
  margin-bottom: 0.5rem;
}

.partners-grid,
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.project-card {
  border: 1px solid #ddd;
  padding: 1.5rem;
  border-radius: 4px;
  transition: box-shadow 0.3s;
}

.project-card:hover {
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.partner-image,
.project-image {
  margin-bottom: 1rem;
  overflow: hidden;
  border-radius: 4px;
}

.partner-image img,
.project-image img {
  width: 100%;
  height: auto;
  display: block;
}

.partner-excerpt,
.project-excerpt {
  font-size: 0.95rem;
  color: #555;
}

.navigation {
  display: flex;
  justify-content: space-between;
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid #ddd;
}

.nav-previous,
.nav-next {
  flex: 1;
}

.nav-previous {
  text-align: left;
}

.nav-next {
  text-align: right;
}

@media (min-width: 1024px) {
  section,
  main {
    padding-left: calc(22% + 2rem);
    padding-top: 3.375rem;
    padding-right: 2rem;
    padding-bottom: 3.375rem;
  }
}

@media (max-width: 1023px) {
  section {
    padding-top: 4rem !important;
    padding-left: 1.5rem !important;
    padding-right: 1.5rem !important;
    padding-bottom: 4rem;
  }

  main > section:first-of-type {
    padding-top: 6rem !important;
  }

  h1.hero-title {
    font-size: 24px;
  }

  p.hero-title {
    font-size: 16px;
  }
}

/* ==========================================================================
   Header
   ========================================================================== */

.pas-name {
  font-size: 1.25rem;
  line-height: 1.15;
  transition: color 0.3s ease;
}

.pas-name__title {
  font-weight: 500;
}

.pas-name__established {
  font-weight: 200;
  display: block;
}

.mobile-header-branding {
  display: none;
}

@media (max-width: 1023px) {
  .mobile-header-branding {
    display: block;
    position: absolute;
    top: 1.5rem;
    left: 1.5rem;
    z-index: 1001;
    width: auto;
  }

  .mobile-header-branding .pas-name {
    font-size: 1rem;
    line-height: 1.15;
  }

  .mobile-header-branding .pas-name__title {
    font-weight: 500;
  }

  .mobile-header-branding .pas-name__established {
    font-weight: 200;
    display: block;
  }

  .mobile-header-branding.menu-active {
    position: fixed;
  }
}

/* ==========================================================================
   Navigation
   ========================================================================== */

.sidebar-navigation {
  position: fixed;
  left: 0;
  top: 0;
  max-width: 340px;
  width: 22%;
  height: 100vh;
  background-color: transparent;
  border-right: 1px solid white;
  padding: 3.375rem 3rem;
  z-index: 1000;
  overflow-y: auto;
  display: none;
  pointer-events: none;
}

.sidebar-navigation a {
  pointer-events: auto;
}

@media (min-width: 1024px) {
  body.post-type-archive-press .sidebar-navigation,
  body.post-type-archive-projects .sidebar-navigation {
    border-right-color: #b3b3b3;
  }
}

.sidebar-navigation__bg-image {
  display: none;
}

.sidebar-navigation.show {
  display: flex;
}

.sidebar-nav-inner {
  display: flex;
  flex-direction: column;
}

.nav-menu-sidebar {
  display: flex;
  flex-direction: column;
  align-items: start;
  list-style: none;
  margin: 0;
  padding: 0;
}

.sidebar-nav-inner a {
  display: inline-block;
  transition:
    transform 0.2s ease,
    color 0.3s ease;
  font-size: 1.25rem;
  line-height: 1.4;
  text-decoration: none;
  transform-origin: left;
  color: #717171;
}

.sidebar-nav-inner a:hover {
  transform: scale(1.05);
}

.sidebar-nav-inner .current-menu-item > a,
.sidebar-nav-inner .current-menu-ancestor > a,
.sidebar-nav-inner .current_page_item > a {
  color: #000000;
}

.pas-partner {
  font-size: 0.75rem;
  transition: color 0.3s ease;
}

.pas-partner__name {
  font-weight: 600;
  display: inline-block;
  margin-right: 0.25rem;
}

.pas-partner__role {
  font-weight: 200;
}

.pas-legal {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.75rem;
  font-size: 0.75rem;
  font-weight: 200;
  transition: color 0.3s ease;
}

.pas-legal a {
  color: inherit;
  transition: opacity 0.2s ease;
}

.pas-legal a:hover {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.sidebar-footer {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  gap: 0.75rem;
  margin-top: auto;
}

.social-icons {
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

.social-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 24px;
  color: #000000;
  transition:
    transform 0.2s ease,
    opacity 0.2s ease,
    color 0.3s ease;
  opacity: 0.7;
}

.social-icon:nth-child(2) {
  width: 26px;
}

.social-icon:hover {
  opacity: 1;
  transform: scale(1.1);
}

.social-icon svg {
  width: 100%;
  height: 100%;
}

.social-icon svg [stroke] {
  transition: stroke 0.3s ease;
}

.social-icon svg [fill]:not([fill="none"]) {
  transition: fill 0.3s ease;
}

.mobile-menu-toggle {
  display: none;
  position: fixed;
  top: 1.5rem;
  right: 1.5rem;
  z-index: 2000;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  flex-direction: column;
  gap: 6px;
}

.mobile-menu-toggle span {
  width: 24px;
  height: 2px;
  background-color: #000000;
  display: block;
  transition: all 0.3s ease;
  transform-origin: center;
}

.mobile-menu-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translateY(11px);
}

.mobile-menu-toggle.active span:nth-child(2) {
  opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translateY(-11px);
}

@media (min-width: 1024px) {
  .sidebar-navigation {
    display: flex;
    flex-direction: column;
  }

  .sidebar-nav-inner.on-dark a,
  .sidebar-nav-inner.on-dark .current-menu-item > a,
  .sidebar-nav-inner.on-dark .current-menu-ancestor > a,
  .sidebar-nav-inner.on-dark .current_page_item > a {
    color: #fff;
  }

  .sidebar-footer.on-dark .pas-name,
  .sidebar-footer.on-dark .pas-partner,
  .sidebar-footer.on-dark .pas-legal {
    color: #fff;
  }

  .sidebar-footer.on-dark .social-icon {
    color: #fff;
  }

  .sidebar-footer.on-dark .social-icon svg [stroke] {
    stroke: #fff;
  }

  .sidebar-footer.on-dark .social-icon svg [fill]:not([fill="none"]) {
    fill: #fff;
  }
}

@media (min-width: 1024px) and (max-width: 1300px) {
  .sidebar-navigation .sidebar-footer .pas-partners {
    display: none;
  }
}

@media (max-width: 1023px) {
  .mobile-menu-toggle {
    display: flex;
  }

  .sidebar-navigation {
    position: fixed;
    width: 100%;
    height: 100%;
    inset: 0;
    max-width: none;
    background-color: white;
    --blue-x: 0%;
    --blue-y: 10%;
    --orange-x: 130%;
    --orange-y: 0%;
    --gold-x: 50%;
    --gold-y: 100%;
    filter: saturate(1.4);
    background-image:
      radial-gradient(
        ellipse 800px 1000px at var(--blue-x) var(--blue-y),
        #b5d0e9 0%,
        #b5d0e9 25%,
        transparent 55%
      ),
      radial-gradient(
        ellipse 600px 2000px at var(--orange-x) var(--orange-y),
        #fb8845 0%,
        transparent 100%
      ),
      radial-gradient(
        ellipse 1000px 2000px at var(--gold-x) var(--gold-y),
        #fdcd84 0%,
        #fdcd84 80%,
        transparent 100%
      );
    padding: 0;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    border-right: none;
    pointer-events: none;
    overflow-y: auto;
    opacity: 0;
    transition: opacity 0.3s ease;
  }

  .sidebar-navigation__bg-image {
    display: block;
    position: absolute;
    inset: 0;
    z-index: -1;
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
  }

  .sidebar-navigation.show {
    opacity: 1;
    pointer-events: all;
  }

  .sidebar-navigation.show a {
    pointer-events: all;
  }

  .sidebar-nav-inner {
    padding: 8rem 1.5rem 2rem 1.5rem;
    flex: none;
  }

  .nav-menu-sidebar {
    gap: 0;
  }

  .sidebar-nav-inner a {
    position: relative;
    padding-top: 0.375rem;
    padding-bottom: 0.375rem;
    pointer-events: none;
  }

  .sidebar-footer a {
    pointer-events: none;
  }

  .sidebar-nav-inner a::after {
    content: "";
    position: absolute;
    height: 1px;
    width: calc(100vw - 3rem);
    bottom: 0;
    left: 0;
    right: 0;
    background-color: #fff;
  }

  .sidebar-nav-inner a:hover {
    transform: scale(1.05);
  }

  .sidebar-footer {
    display: none;
  }

  .sidebar-navigation .sidebar-footer {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-top: 2rem;
    padding: 0 1.5rem 2rem;
    position: static;
    width: 100%;
    max-width: none;
  }

  .sidebar-navigation .sidebar-footer .pas-name {
    display: none;
  }

  .sidebar-navigation .sidebar-footer .pas-partners,
  .sidebar-navigation .sidebar-footer .pas-legal {
    display: none;
  }

  .sidebar-navigation .sidebar-footer .social-icons {
    display: flex;
    gap: 1.5rem;
    align-items: center;
  }
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
  display: none;
}

@media (max-width: 1023px) {
  .site-footer {
    display: block;
    background-color: #fff;
    padding: 2rem 1.5rem;
    border-top: 1px solid #ddd;
  }

  .mobile-footer-sidebar {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
  }

  .mobile-footer-sidebar .pas-partners {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
  }

  .mobile-footer-sidebar .social-icons {
    display: flex;
    gap: 1rem;
    align-items: center;
  }

  .mobile-footer-sidebar .social-icon {
    width: 20px;
    height: 20px;
  }

  .mobile-footer-sidebar .social-icon:nth-child(2) {
    width: 24px;
  }
}

@media (min-width: 1024px) {
  .site-footer {
    display: none;
  }
}
