/* =========================================
  Base Styles
  reset.css の上に積む前提
========================================= */

/* ---- Root (色・フォント・余白基準) ---- */
:root {
  --ink: #243b3e;
  --muted: #627376;
  --line: #dce5e4;
  --color-accent-text: #087887;
  --font-base: "Inter", "Noto Sans JP", "Yu Gothic UI",
    "Helvetica Neue", Arial, "Hiragino Sans",
    "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;

  --color-bk: #4b4737;
  --color-w: #ffffff;

  --color1: #2cafc3;
  --color2: #068a8f;
  --color3: #d6f3f7;
  --color4: #cccccc;

  --color-border: #dfe7ea;
  --shadow-common: 0 1px 2px rgba(0, 0, 0, .25);

  --fs-base: 16px;
  --lh-base: 1.7;
  --space: 1rem;
}

/* Reserve the scrollbar gutter even while the loading screen locks scrolling. */
html {
  scrollbar-gutter: stable;
}

/* ---- Body ---- */
body {
  font-weight: 500;
  font-family: var(--font-base);
  font-size: var(--fs-base);
  line-height: var(--lh-base);
  color: var(--color-bk);
  background: var(--color-w);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ---- Heading ---- */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: 0.01em;
}

h1,
h2,
h3 {
  font-family: "Noto Serif JP", serif;
  letter-spacing: 0.05em;
}

h1 {
  font-size: 2.6rem;
  font-weight: 600;
}

h2 {
  font-size: 2rem;
  font-weight: 500;
}

h3 {
  font-size: 1.4rem;
}

/* ---- Paragraph ---- */
p {
  margin-bottom: 2rem;
  letter-spacing: 0.01em;
}

/* ---- Link ---- */
a {
  transition: color .2s ease, opacity .2s ease;
}

/* ---- Header ---- */
/* ---- footer ---- */
footer>div {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  width: 100%;
  padding: 3rem;
  font-size: 1vw;
  color: var(--color-bk);
}

footer nav {
  margin: 2rem 0;
}

footer p {
  margin-top: .5rem;
  margin-bottom: 0;
  font-size: .9vw;
  text-align: right;
}

.footer-copy {
  margin-top: 1rem;
}

.footer-copy small {
  padding: .1rem .2rem;
  background: #95b0b5;
  color: var(--color-w);
}

/* ロゴ */
.logo {
  display: flex;
  align-items: center;
  gap: .75rem;
}

.logo svg {
  width: auto;
  transition: height .3s ease, opacity .3s ease, transform .3s ease;
}

.logo-mark,
.logo-name {
  display: block;
}

.logo-mark {
  height: 48px;
  aspect-ratio: 1/1;
  background: url("../img/logo-mark.svg") no-repeat center/contain;
  /* マークの基準 */
}

.logo-name {
  height: 22px;
  aspect-ratio: 9/1;
  background: url("../img/logo-name.svg") no-repeat center/contain;
  /* ネームの基準（マークに対して自然な比率） */
}

/* ナビ */
nav ul {
  display: flex;
  gap: 1.5rem;
}

/* リスト・カード */
ul.point-list {
  font-size: 1.3vw;
  font-weight: 400;
}

.point-list li {
  position: relative;
  display: flex;
  align-items: center;
  width: fit-content;
  margin-bottom: 1rem;
}

ul.point-list2 {
  font-size: 1.3vw;
  font-weight: 400;
}

.point-list2 li {
  display: flex;
  align-items: flex-start;
  margin: 0 0 1rem 0;
}

.point-list2 li strong {
  position: relative;
  width: fit-content;
  margin-bottom: 1rem;
}

.point-list li::before {
  content: "";
  display: block;
  width: 1.4vw;
  aspect-ratio: 1/1;
  margin: 0 .5rem 0 0;
  background: var(--color1);
  -webkit-mask: url("../img/img-mask-hex.svg") no-repeat center / contain;
  mask: url("../img/img-mask-hex.svg") no-repeat center / contain;
  transform: rotate(30deg);
}

.point-list li::after,
.point-list2 li strong::after {
  content: "";
  position: absolute;
  right: -0.2em;
  bottom: 0.2em;
  height: 0.6em;
  background: rgba(255, 255, 0, 0.4);
  z-index: -1;
}

.point-list li::after {
  width: calc(100% - 1.4vw);
}

.point-list2 strong::after {
  width: 100%;
}

.card-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  padding: 0;
  margin: 0;
}

.card-list li {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2rem;
  background: rgba(0, 0, 0, .05);
  border-radius: 6px;
}

.card-list li:hover {
  background: var(--color1);
  color: var(--color-w);
  cursor: pointer;
}

.card-list img {
  width: 80%;
  border-radius: 50%;
}

.card-list p {
  margin-top: 2rem;
  margin-bottom: 0;
  font-size: 1.2vw;
  text-align: center;
}


main {
  width: 100%;
}

main h2 {
  margin: 0 0 2rem 0;
  font-size: 2.4vw;
}

main h3 {
  margin: 4rem 0 2rem 0;
  font-size: 1.6vw;
}

main p {
  font-size: 1.4vw;
}

main p.annot {
  width: fit-content;
  margin: 2rem 0 0 0;
  padding: .25rem .5rem;
  font-size: 1vw;
  border-radius: 4px;
  background: var(--color1);
  color: var(--color-w);
}

main p.note {
  margin-top: 1rem;
  margin-bottom: 0;
  color: #666666;
  font-size: 1.2vw;
}

main>section {
  position: relative;
  padding: 3.5rem;
  z-index: 1;
}

.company-info dl>div {
  display: grid;
  grid-template-columns: 25% 75%;
  margin: 1rem 0;
}

/* Shared footer presentation for the home and interior templates. */
:is(#home, body.page) footer>div {
  padding: 50px 6% 30px;
  font-size: 12px;
}

:is(#home, body.page) footer nav ul {
  flex-wrap: wrap;
}

:is(#home, body.page) footer p {
  font-size: 11px;
}

:is(#home, body.page) .footer-copy small {
  background: none;
  color: var(--muted);
}

#fixed-contact {
  position: fixed;
  inset: auto 0 0;
  z-index: 9998;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 32px;
  padding: 14px 80px calc(14px + env(safe-area-inset-bottom));
  background: rgb(255 255 255 / 96%);
  border-top: 1px solid var(--line);
  box-shadow: 0 -4px 20px rgb(36 59 62 / 8%);
  opacity: 0;
  visibility: hidden;
  transform: translateY(100%);
  transition: transform .3s ease, opacity .3s ease, visibility .3s;
}

#fixed-contact.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

:is(#fixed-contact, .mobile-nav-contact) .tel {
  text-align: center;
}

:is(#fixed-contact, .mobile-nav-contact) .tel-lead {
  display: block;
  margin-bottom: 3px;
  color: var(--color-accent-text);
  font-size: 12px;
  font-weight: 700;
}

:is(#fixed-contact, .mobile-nav-contact) .tel p {
  margin: 0;
  font-size: 24px;
  line-height: 1;
}

:is(#fixed-contact, .mobile-nav-contact) .tel a {
  display: inline-flex;
  align-items: center;
  gap: .2em;
  white-space: nowrap;
  color: var(--ink);
}

:is(#fixed-contact, .mobile-nav-contact) .tel a::before {
  content: "";
  flex-shrink: 0;
  width: 1.1em;
  aspect-ratio: 1/1;
  background-color: var(--color2);
  -webkit-mask: url("../img/icon/icon-phone-forwarded.svg") no-repeat center / contain;
  mask: url("../img/icon/icon-phone-forwarded.svg") no-repeat center / contain;
}

:is(#fixed-contact, .mobile-nav-contact) small {
  font-size: 11px;
}

:is(#fixed-contact, .mobile-nav-contact) .bn-line {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px 8px;
  background: #06c755;
  border-radius: 6px;
  color: var(--color-w);
  font-size: 14px;
  font-weight: 700;
  transition: background-color .25s ease, transform .25s ease, box-shadow .25s ease;
}

:is(#fixed-contact, .mobile-nav-contact) .bn-line::before {
  content: "";
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  background: url("../img/icon-line.png") no-repeat center / contain;
}

:is(#fixed-contact, .mobile-nav-contact) .bn-line:is(:hover, :focus-visible) {
  background-color: #05ad49;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgb(6 199 85 / 22%);
}

:is(#fixed-contact, .mobile-nav-contact) .bn-line[aria-disabled="true"] {
  cursor: default;
}

body.has-fixed-contact footer {
  padding-bottom: var(--fixed-contact-height, 100px);
}

body.fixed-contact-visible .back-to-top {
  bottom: calc(var(--fixed-contact-height, 100px) + 16px);
}

@media (max-width: 768px) {
  #fixed-contact {
    gap: 12px;
    padding: 12px 14px calc(12px + env(safe-area-inset-bottom));
  }

  :is(#fixed-contact, .mobile-nav-contact) .tel {
    flex-shrink: 0;
  }

  :is(#fixed-contact, .mobile-nav-contact) .tel p {
    font-size: 19px;
  }

  :is(#fixed-contact, .mobile-nav-contact) small {
    font-size: 9px;
  }

  :is(#fixed-contact, .mobile-nav-contact) .bn-line {
    gap: 6px;
    padding: 12px;
    font-size: 12px;
    text-align: center;
  }

  :is(#fixed-contact, .mobile-nav-contact) .bn-line br {
    display: none;
  }

  :is(#fixed-contact, .mobile-nav-contact) .bn-line::before {
    width: 26px;
    height: 26px;
  }

  :is(#fixed-contact, .mobile-nav-contact) .tel-lead {
    font-size: 10px;
  }
}

@media (prefers-reduced-motion: reduce) {
  #fixed-contact {
    transition: none;
  }

  :is(#fixed-contact, .mobile-nav-contact) .bn-line {
    transition: none;
  }

  :is(#fixed-contact, .mobile-nav-contact) .bn-line:is(:hover, :focus-visible) {
    transform: none;
  }
}

@media (max-width: 768px) {
  :is(#home, body.page) footer>div {
    align-items: flex-start;
  }

  :is(#home, body.page) footer nav ul {
    gap: 12px 20px;
  }

  :is(#home, body.page) footer p {
    text-align: left;
  }
}


/* Shared back-to-top control. */
a[data-tel-href]:not([href]) {
  cursor: text;
}

.back-to-top {
  position: fixed;
  right: max(20px, env(safe-area-inset-right));
  bottom: max(20px, env(safe-area-inset-bottom));
  z-index: 9997;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  padding: 0;
  border: 1px solid var(--color-w);
  border-radius: 50%;
  background: var(--color1);
  color: var(--color-w);
  box-shadow: 0 3px 14px rgb(36 59 62 / 18%);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(10px);
  transition: opacity .25s ease, transform .25s ease, background-color .25s ease, visibility .25s;
}

.back-to-top.is-visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.back-to-top::before {
  content: "";
  width: 22px;
  height: 22px;
  background: currentColor;
  -webkit-mask: url("../img/icon/arrow-right.svg") no-repeat center / contain;
  mask: url("../img/icon/arrow-right.svg") no-repeat center / contain;
  transform: rotate(-90deg);
  transition: transform .25s ease;
}

.back-to-top:is(:hover, :focus-visible) {
  background: var(--color-accent-text);
}

.back-to-top:is(:hover, :focus-visible)::before {
  transform: translateY(-2px) rotate(-90deg);
}

.back-to-top:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {

  .back-to-top,
  .back-to-top::before {
    transition: none;
  }
}

/* Decorative link arrows: local Material Symbols SVG, no font dependency. */
.link-arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  vertical-align: middle;
}

.link-arrow::before {
  content: "";
  display: block;
  width: 1em;
  height: 1em;
  background-color: var(--color1);
  -webkit-mask: url("../img/icon/arrow_forward.svg") no-repeat center / contain;
  mask: url("../img/icon/arrow_forward.svg") no-repeat center / contain;
}

/* Shared primary link button. */
.primary-button {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  width: fit-content;
  margin-top: 30px;
  padding: 18px 24px;
  background: var(--color1);
  color: var(--color-w);
  font-size: 13px;
  transition: background-color .2s ease, color .2s ease;
}

.primary-button::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: linear-gradient(var(--color1), var(--color1)),
    linear-gradient(var(--color1), var(--color1)),
    linear-gradient(var(--color1), var(--color1)),
    linear-gradient(var(--color1), var(--color1));
  background-position: left top, right top, right bottom, left bottom;
  background-repeat: no-repeat;
  background-size: 0 1px, 1px 0, 0 1px, 1px 0;
}

.primary-button:hover::after,
.primary-button:focus-visible::after {
  animation: primary-button-border .65s linear forwards;
}

@keyframes primary-button-border {
  0% {
    background-size: 0 1px, 1px 0, 0 1px, 1px 0;
  }

  35% {
    background-size: 100% 1px, 1px 0, 0 1px, 1px 0;
  }

  50% {
    background-size: 100% 1px, 1px 100%, 0 1px, 1px 0;
  }

  85% {
    background-size: 100% 1px, 1px 100%, 100% 1px, 1px 0;
  }

  100% {
    background-size: 100% 1px, 1px 100%, 100% 1px, 1px 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .primary-button {
    transition: none;
  }

  .primary-button:hover::after,
  .primary-button:focus-visible::after {
    animation: none;
    background-size: 100% 1px, 1px 100%, 100% 1px, 1px 100%;
  }
}

.primary-button:hover,
.primary-button:focus-visible {
  background: var(--color-w);
  color: var(--color1);
}

.primary-button .link-arrow {
  background: none;
  font-size: 22px;
}

.primary-button .link-arrow::before {
  background-color: currentColor;
}

:is(.primary-button, .button-light) .link-arrow::before {
  transform: translateX(0);
  transition: transform .2s ease;
}

:is(.primary-button, .button-light):hover .link-arrow::before,
:is(.primary-button, .button-light):focus-visible .link-arrow::before {
  transform: translateX(2px);
}

@media (prefers-reduced-motion: reduce) {
  :is(.primary-button, .button-light) .link-arrow::before {
    transition: none;
  }
}

.button-light:is(:hover, :focus-visible) .link-arrow::before {
  background-color: var(--color-w);
}