/* =========================================
   layout.css
   ヘッダー / フッター / モバイルナビ
   ========================================= */

/* ---------- Header ---------- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  transition: background var(--dur) var(--ease),
    border-color var(--dur) var(--ease),
    backdrop-filter var(--dur) var(--ease);
}

.site-header.is-scrolled {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--color-border);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-en);
  font-weight: 700;
  font-size: 20px;
  letter-spacing: -0.01em;
  color: var(--color-text);
}

.brand__mark {
  width: 28px;
  height: 28px;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.brand__mark svg {
  width: 100%;
  height: 100%;
}

.nav {
  display: flex;
  align-items: center;
  gap: 36px;
}

.nav__list {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav__link {
  font-size: 14px;
  font-weight: 500;
  color: var(--color-text-soft);
  position: relative;
}

.nav__link:hover {
  color: var(--color-accent);
}

.nav__cta {
  padding: 10px 20px;
  font-size: 13px;
}

.nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
}

.nav-toggle__bars {
  position: relative;
  width: 20px;
  height: 14px;
}

.nav-toggle__bars span {
  position: absolute;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--color-text);
  border-radius: 2px;
  transition: transform var(--dur) var(--ease), opacity var(--dur) var(--ease), top var(--dur) var(--ease);
}

.nav-toggle__bars span:nth-child(1) {
  top: 0;
}
.nav-toggle__bars span:nth-child(2) {
  top: 6px;
}
.nav-toggle__bars span:nth-child(3) {
  top: 12px;
}

.nav-toggle.is-open .nav-toggle__bars span:nth-child(1) {
  top: 6px;
  transform: rotate(45deg);
}
.nav-toggle.is-open .nav-toggle__bars span:nth-child(2) {
  opacity: 0;
}
.nav-toggle.is-open .nav-toggle__bars span:nth-child(3) {
  top: 6px;
  transform: rotate(-45deg);
}

/* ---------- Mobile Nav ---------- */
@media (max-width: 880px) {
  .nav-toggle {
    display: inline-flex;
  }

  .nav {
    position: fixed;
    inset: 72px 0 0 0;
    background: #fff;
    flex-direction: column;
    justify-content: flex-start;
    align-items: stretch;
    padding: 32px 24px;
    gap: 0;
    transform: translateY(-110%);
    transition: transform var(--dur) var(--ease);
    border-bottom: 1px solid var(--color-border);
  }

  .nav.is-open {
    transform: translateY(0);
  }

  .nav__list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }

  .nav__list li {
    border-bottom: 1px solid var(--color-border);
  }

  .nav__link {
    display: block;
    padding: 18px 4px;
    font-size: 16px;
    color: var(--color-text);
  }

  .nav__cta {
    margin-top: 24px;
    align-self: flex-start;
  }
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--color-bg-dark);
  color: var(--color-text-on-dark);
  padding: 80px 0 32px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 56px;
}

.footer-brand .brand {
  color: #fff;
  margin-bottom: 16px;
}

.footer-brand p {
  font-size: 14px;
  color: rgba(245, 245, 245, 0.6);
  line-height: 1.9;
  max-width: 360px;
}

.footer-col h4 {
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(245, 245, 245, 0.5);
  font-weight: 600;
  margin-bottom: 18px;
}

.footer-col ul li {
  margin-bottom: 12px;
}

.footer-col ul li a {
  font-size: 14px;
  color: rgba(245, 245, 245, 0.85);
}

.footer-col ul li a:hover {
  color: var(--color-accent);
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 24px;
  border-top: 1px solid rgba(245, 245, 245, 0.1);
  font-size: 12px;
  color: rgba(245, 245, 245, 0.5);
}

.footer-bottom__links {
  display: flex;
  gap: 20px;
}

@media (max-width: 760px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 16px;
    align-items: flex-start;
  }
}
