/* Shared base: reset, headers, footers, breadcrumbs, buttons, section headings — spec/v2/header.md, footer.md, form.md */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-jp);
  color: var(--color-navy);
  background: var(--color-white);
}

h1,
h2,
h3,
h4,
p,
ul,
ol,
dl,
dd,
figure {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ---------- Section heading (Title 46 / Description 32, centered) ---------- */
.sec-title {
  font-weight: 700;
  font-size: 46px;
  line-height: 1.35;
  letter-spacing: var(--ls-title);
  text-align: center;
  color: var(--color-navy);
}

.sec-desc {
  font-weight: 400;
  font-size: 32px;
  line-height: 1.9;
  text-align: center;
  color: var(--color-slate);
}

/* ---------- Primary action (orange button + arrow circle) ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 0 28px;
  border: 0;
  border-radius: var(--radius-button);
  background: var(--color-orange);
  color: var(--color-white);
  font-family: var(--font-jp);
  font-weight: 700;
  line-height: var(--lh-text);
  cursor: pointer;
  transition: filter 0.15s, transform 0.15s;
}

.btn:hover {
  filter: brightness(1.06);
}

.btn:focus-visible {
  outline: 3px solid rgba(26, 86, 160, 0.45);
  outline-offset: 3px;
}

.btn--xl {
  width: 450px;
  max-width: 100%;
  height: 100px;
  font-size: 30px;
  box-shadow: 0 10px 30px rgba(5, 43, 91, 0.0784);
}

.btn--navy {
  background: var(--color-navy);
}

.btn__arrow {
  display: flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1412);
}

/* ---------- LP header (Desktop header 1440x88) ---------- */
.site-header {
  position: relative;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 88px;
  padding: 0 88px;
  background: var(--color-white);
}

.brand {
  display: flex;
  align-items: center;
  gap: 9px;
}

.brand__logo {
  width: 213px;
  height: 46px;
}

.brand__u35 {
  font-weight: 700;
  font-size: 48px;
  line-height: 1.65;
  background: linear-gradient(90deg, #2daab2 0%, #1b7dc5 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.site-nav {
  display: flex;
  gap: 28px;
}

.site-nav a {
  font-family: var(--font-latin), var(--font-jp);
  font-size: 12px;
  line-height: var(--lh-text);
  color: var(--color-navy);
}

.site-nav a:hover {
  color: var(--color-orange);
}

.login-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 0 8px;
  font-weight: 500;
  font-size: 10px;
  line-height: 1;
  color: #000;
}

.login-link:hover {
  color: var(--color-orange);
}

.menu-btn {
  display: none;
}

/* ---------- Simple header (form pages: logo only) ---------- */
.simple-header {
  display: flex;
  align-items: center;
  height: 88px;
  padding: 0 88px;
  background: var(--color-white);
}

.simple-header .brand__logo {
  display: block;
}

/* ---------- Breadcrumbs (1440x40, gradient) ---------- */
.breadcrumbs {
  display: flex;
  align-items: center;
  gap: 15px;
  height: 40px;
  padding: 0 70px;
  background: var(--grad-brand);
  font-weight: 500;
  font-size: 12px;
  line-height: 24px;
  color: var(--color-white);
}

/* ---------- Footer links (shared) ---------- */
.footer-links {
  display: flex;
  flex-wrap: wrap;
  column-gap: 62px; /* visual gaps 64–69px in Figma (letter-spacing adds ~4px) */
  row-gap: 0;
}

.footer-links a {
  font-weight: 700;
  font-size: 16px;
  line-height: 29px;
  letter-spacing: 1.38px;
  color: var(--color-white);
}

.footer-links a:hover {
  text-decoration: underline;
}

/* LP footer (#00122C, 252h, centered links + copyright) */
.site-footer {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 116px 70px 38px; /* Figma total 252: links frame 81 + copyright 17 */
  background: var(--color-navy-dark);
  color: var(--color-white);
}

.site-footer__logo {
  position: absolute;
  top: 30px;
  left: 70px;
  width: 229px;
  height: 49px;
}

.site-footer .footer-links {
  justify-content: center;
  margin-right: 36px; /* Figma text box (740px) has trailing spaces → links sit 18px left of centre */
  padding: 26px;
}

.site-footer__copy {
  margin: -3px 12px 0 0;
  font-size: 16px;
  line-height: 17px;
  letter-spacing: 0.5px;
}

/* Form pages footer (#00122C, links / divider / logo / copyright) */
.page-footer {
  display: flex;
  flex-direction: column;
  gap: 48px;
  padding: 64px 88px 32px;
  background: var(--color-navy-dark);
}

.page-footer__divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.1216);
}

.page-footer__bottom {
  display: flex;
  flex-direction: column;
  gap: 48px; /* XD: logo row, then the copyright on its own row, right aligned (QA #9) */
}

.page-footer__copy {
  align-self: flex-end;
}

.page-footer__logo {
  width: 229px;
  height: 49px;
}

.page-footer__copy {
  font-family: var(--font-latin);
  font-size: 9px;
  line-height: var(--lh-text);
  color: #94a3b8;
}

/* ---------- Tablet (fluid, no design) ---------- */
@media (max-width: 1100px) {
  .site-header,
  .simple-header {
    padding: 0 40px;
  }

  .site-nav {
    gap: 20px;
  }

  .page-footer {
    padding-left: 40px;
    padding-right: 40px;
  }
}

/* ---------- Mobile (390 frames) ---------- */
@media (max-width: 767px) {
  .sec-title {
    font-size: 24px;
  }

  .sec-desc {
    font-size: 15px;
    line-height: 1.8;
  }

  .btn--xl {
    width: 100%;
    height: 64px;
    font-size: 18px;
  }

  .site-header {
    height: 64px;
    padding: 0 16px 0 20px;
  }

  .brand {
    gap: 6px;
  }

  .brand__logo {
    width: 121px;
    height: 26px;
  }

  .brand__u35 {
    font-size: 26px;
    line-height: 1.2;
  }

  .menu-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 0;
    border: 0;
    background: none;
    color: var(--color-navy);
    cursor: pointer;
  }

  .menu-btn__close {
    display: none;
  }

  .site-header.is-open .menu-btn__open {
    display: none;
  }

  .site-header.is-open .menu-btn__close {
    display: block;
  }

  .site-header__panel {
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    gap: 20px;
    padding: 20px 20px 28px;
    background: var(--color-white);
    box-shadow: 0 12px 24px rgba(5, 43, 91, 0.12);
  }

  .site-header.is-open .site-header__panel {
    display: flex;
  }

  .site-nav {
    flex-direction: column;
    gap: 0;
  }

  .site-nav a {
    padding: 14px 0;
    border-bottom: 1px solid var(--color-line);
    font-size: 15px;
  }

  .login-link {
    flex-direction: row;
    justify-content: center;
    gap: 8px;
    height: 48px;
    border: 1px solid var(--color-line);
    border-radius: 10px;
    font-size: 14px;
  }

  .simple-header {
    justify-content: center;
    height: 64px;
    padding: 0 20px;
  }

  .breadcrumbs {
    padding: 0 20px;
  }

  .footer-links {
    flex-direction: column;
  }

  .footer-links a {
    font-size: 12px;
  }

  .site-footer {
    align-items: flex-start;
    gap: 16px;
    padding: 24px 20px 28px;
  }

  .site-footer__logo {
    position: static;
    order: 2;
  }

  .site-footer .footer-links {
    margin-right: 0;
    padding: 0;
  }

  .site-footer__copy {
    margin: 0;
    order: 3;
    font-size: 11px;
    line-height: 1.6;
  }

  .page-footer {
    gap: 16px;
    padding: 24px 20px 28px;
  }

  .page-footer__bottom {
    gap: 16px;
  }

  .page-footer__copy {
    align-self: flex-start;
  }

  .page-footer__divider {
    background: #b8d0ec;
  }
}

@media (min-width: 768px) {
  .site-header__panel {
    display: contents;
  }
}
