/**
 * AinaviCE shared design system
 *
 * This file is loaded after every page stylesheet. It owns the visual rules
 * for shared navigation and the site's heading rhythm.
 */

:root {
  --ainavi-container: min(1120px, calc(100vw - 72px));
  --ainavi-heading-xl: clamp(36px, 5vw, 64px);
  --ainavi-heading-lg: clamp(28px, 3.6vw, 46px);
  --ainavi-heading-md: clamp(20px, 2.4vw, 26px);
  --ainavi-heading-leading: 1.28;
  --ainavi-section-gap: clamp(64px, 8vw, 112px);
  --ainavi-heading-gap: clamp(32px, 4vw, 52px);
  --ainavi-blue: #1454c8;
  --ainavi-navy: #07182d;
}

/* Shared navigation must never inherit article-link decoration. */
.site-header a,
.site-footer a {
  text-decoration: none !important;
  text-underline-offset: initial;
}

.site-header {
  width: 100%;
}

.header-inner,
.footer-main {
  margin-right: auto;
  margin-left: auto;
}

.site-header .primary-menu > li > a,
.site-footer .footer-nav a {
  line-height: 1.5;
}

/* One heading scale across the top, service and article templates. */
.page-hero h1 {
  font-size: var(--ainavi-heading-xl);
  line-height: 1.18;
  letter-spacing: -.035em;
}

.site-main :is(
  .section-title,
  .service-section__head h2,
  .about-section h2,
  .news-section h2,
  .company-section h2,
  .ec-section__head h2
) {
  font-size: var(--ainavi-heading-lg);
  line-height: var(--ainavi-heading-leading);
  letter-spacing: -.035em;
  font-weight: 800;
}

.site-main :is(
  .service-section__head,
  .ec-section__head,
  .section-head
) {
  margin-bottom: var(--ainavi-heading-gap);
}

.entry-content > section > h2,
.tips-single__content h2 {
  font-size: var(--ainavi-heading-md);
  line-height: 1.5;
  letter-spacing: -.02em;
  font-weight: 800;
}

.section-label,
.service-section__label,
.ec-section__label,
.inquiry-section__label {
  line-height: 1.4;
  letter-spacing: .16em;
  font-weight: 800;
}

@media (max-width: 640px) {
  :root {
    --ainavi-container: min(100vw - 28px, 520px);
    --ainavi-heading-gap: 30px;
  }
}
