:root {
  --ink: #0c1a22;
  --ink-soft: #16303d;
  --paper: #f3f0e8;
  --paper-2: #e8e4d8;
  --teal: #0f8f8a;
  --teal-deep: #0a6d6a;
  --sand: #d9c4a0;
  --line: rgba(12, 26, 34, 0.12);
  --text: #1a2b33;
  --muted: #5a6b73;
  --white: #fffdf8;
  --radius: 2px;
  --font-display: "Shippori Mincho", "Hiragino Mincho ProN", serif;
  --font-sans: "IBM Plex Sans JP", "Hiragino Sans", sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background: var(--paper);
  font-family: var(--font-sans);
  font-weight: 400;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}

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

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

.wrap {
  width: min(1100px, calc(100% - 2.5rem));
  margin-inline: auto;
}

.wrap--narrow {
  width: min(720px, calc(100% - 2.5rem));
}

/* Header */
.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 0.9rem 1.5rem;
  background: color-mix(in srgb, var(--ink) 88%, transparent);
  backdrop-filter: blur(10px);
  color: var(--white);
  border-bottom: 1px solid rgba(255, 253, 248, 0.08);
}

.site-header__brand {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.site-header__brand span {
  color: var(--sand);
  margin-left: 0.15em;
}

.site-header__nav {
  display: none;
  gap: 1.25rem;
  margin-left: auto;
  font-size: 0.85rem;
}

.site-header__nav a {
  opacity: 0.78;
  transition: opacity 0.2s var(--ease);
}

.site-header__nav a:hover {
  opacity: 1;
}

.site-header__cta {
  margin-left: auto;
  padding: 0.45rem 0.9rem;
  border: 1px solid rgba(255, 253, 248, 0.35);
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  transition: background 0.2s var(--ease), color 0.2s var(--ease);
}

.site-header__cta:hover {
  background: var(--white);
  color: var(--ink);
}

@media (min-width: 880px) {
  .site-header__nav {
    display: flex;
  }

  .site-header__cta {
    margin-left: 0;
  }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3rem;
  padding: 0.75rem 1.4rem;
  border: 1px solid transparent;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: transform 0.2s var(--ease), background 0.2s var(--ease), color 0.2s var(--ease), border-color 0.2s var(--ease);
}

.btn:hover {
  transform: translateY(-1px);
}

.btn--primary {
  background: var(--teal);
  color: var(--white);
}

.btn--primary:hover {
  background: var(--teal-deep);
}

.btn--ghost {
  border-color: rgba(255, 253, 248, 0.45);
  color: var(--white);
  background: transparent;
}

.btn--ghost:hover {
  background: rgba(255, 253, 248, 0.1);
}

.btn--block {
  width: 100%;
}

/* Hero */
.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  align-items: end;
  overflow: hidden;
  color: var(--white);
  background: var(--ink);
}

.hero__plane {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 55% at 75% 35%, rgba(15, 143, 138, 0.28), transparent 60%),
    radial-gradient(ellipse 50% 40% at 15% 80%, rgba(217, 196, 160, 0.12), transparent 55%),
    linear-gradient(160deg, #071218 0%, #0c1a22 45%, #123040 100%);
}

.hero__plane::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 253, 248, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 253, 248, 0.04) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.55), transparent 85%);
  animation: gridDrift 28s linear infinite;
}

@keyframes gridDrift {
  from { background-position: 0 0; }
  to { background-position: 64px 64px; }
}

.hero__content {
  position: relative;
  z-index: 2;
  width: min(1100px, calc(100% - 2.5rem));
  margin: 0 auto;
  padding: 7.5rem 0 3.5rem;
}

.hero__label {
  margin: 0 0 0.75rem;
  font-size: 0.82rem;
  letter-spacing: 0.18em;
  color: var(--sand);
  opacity: 0;
  animation: riseIn 0.9s var(--ease) 0.15s forwards;
}

.hero__brand {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 9vw, 5.6rem);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: 0.06em;
  opacity: 0;
  animation: riseIn 1s var(--ease) 0.28s forwards;
}

.hero__brand span {
  color: var(--sand);
  margin-left: 0.12em;
}

.hero__lead {
  margin: 1.25rem 0 0;
  max-width: 22em;
  font-size: clamp(1.05rem, 2.4vw, 1.35rem);
  font-weight: 500;
  line-height: 1.7;
  opacity: 0;
  animation: riseIn 1s var(--ease) 0.42s forwards;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2rem;
  opacity: 0;
  animation: riseIn 1s var(--ease) 0.55s forwards;
}

.hero__visual {
  position: absolute;
  right: -4%;
  bottom: 8%;
  width: min(58vw, 640px);
  opacity: 0.55;
  pointer-events: none;
  z-index: 1;
  animation: floatSoft 7s ease-in-out infinite;
}

@keyframes riseIn {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes floatSoft {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

@media (max-width: 879px) {
  .hero__visual {
    width: 78vw;
    opacity: 0.28;
    bottom: 18%;
  }

  .hero__content {
    padding-bottom: 5rem;
  }
}

/* Sections */
.section {
  padding: clamp(4.5rem, 9vw, 7rem) 0;
}

.section__eyebrow {
  margin: 0 0 0.75rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  color: var(--teal);
}

.section__title {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 4vw, 2.45rem);
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: 0.04em;
  color: var(--ink);
}

.section__lead {
  margin: 1rem 0 0;
  color: var(--muted);
  font-size: 1.02rem;
}

.section__lead--tight {
  margin: -1.25rem 0 1.75rem;
}

.section__head {
  margin-bottom: 2.5rem;
}

.section__cta {
  margin-top: 2rem;
}

/* Check */
.section--check {
  background:
    linear-gradient(180deg, rgba(15, 143, 138, 0.06), transparent 30%),
    var(--paper);
}

.check-list {
  display: grid;
  gap: 0.75rem;
}

.check-item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1rem;
  align-items: center;
  padding: 1.1rem 1.2rem;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
  transition: background 0.2s var(--ease);
}

.check-item:hover {
  background: rgba(15, 143, 138, 0.05);
}

.check-item input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.check-item__box {
  width: 1.35rem;
  height: 1.35rem;
  border: 1.5px solid rgba(12, 26, 34, 0.35);
  background: var(--white);
  transition: background 0.2s var(--ease), border-color 0.2s var(--ease);
}

.check-item input:checked + .check-item__box {
  background: var(--teal);
  border-color: var(--teal);
  box-shadow: inset 0 0 0 2px var(--white);
}

.check-item__text {
  font-size: 1.02rem;
  font-weight: 500;
}

.check-result {
  margin: 2rem 0 0;
  padding: 1.25rem 1.4rem;
  background: var(--ink);
  color: var(--white);
  line-height: 1.7;
}

.check-result strong {
  color: var(--sand);
  font-size: 1.4rem;
  margin-right: 0.15em;
}

/* Message */
.section--message {
  background: var(--ink);
  color: var(--white);
}

.section--message .section__title,
.section--message .section__eyebrow {
  color: var(--sand);
}

.message-body {
  display: grid;
  gap: 1.25rem;
  font-size: 1.05rem;
  line-height: 2;
}

.message-body p {
  margin: 0;
}

.message-body__close {
  margin-top: 0.5rem;
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--sand);
}

/* Service */
.service-flow {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 880px) {
  .service-flow {
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
  }
}

.service-flow__item {
  padding-top: 1.25rem;
  border-top: 2px solid var(--ink);
}

.service-flow__num {
  display: block;
  font-family: var(--font-display);
  font-size: 0.9rem;
  letter-spacing: 0.12em;
  color: var(--teal);
  margin-bottom: 0.75rem;
}

.service-flow__title {
  margin: 0 0 0.75rem;
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
}

.service-flow__text {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

/* Rebuild cases */
.section--ba {
  background:
    linear-gradient(135deg, var(--paper-2), var(--paper) 45%, rgba(15, 143, 138, 0.08));
}

.case-feature {
  display: grid;
  gap: 2rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid var(--line);
}

.case-feature__visual {
  display: grid;
  gap: 1.25rem;
  align-items: center;
}

@media (min-width: 880px) {
  .case-feature {
    grid-template-columns: minmax(0, 1.7fr) minmax(260px, 0.8fr);
    align-items: center;
  }

  .case-feature__visual {
    grid-template-columns: 1fr auto 1fr;
    gap: 0.9rem;
  }
}

.ba-panel {
  margin: 0;
}

.ba-panel figcaption {
  margin-bottom: 0.65rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: var(--muted);
}

.ba-panel--after figcaption {
  color: var(--teal);
}

.ba-panel img {
  width: 100%;
  min-height: 180px;
  object-fit: cover;
  border: 1px solid var(--line);
  background: var(--white);
}

.ba-panel__note {
  margin: 0.7rem 0 0;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.6;
}

.ba-arrow {
  display: none;
  color: var(--teal);
  animation: pulseArrow 1.8s ease-in-out infinite;
}

@media (min-width: 880px) {
  .ba-arrow {
    display: block;
  }
}

@keyframes pulseArrow {
  0%, 100% { transform: translateX(0); opacity: 0.55; }
  50% { transform: translateX(6px); opacity: 1; }
}

.case-feature__meta,
.case-card__num {
  margin: 0 0 0.65rem;
  color: var(--teal);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.16em;
}

.case-feature__body h3,
.case-card h3 {
  margin: 0;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 2.5vw, 1.7rem);
  font-weight: 600;
  line-height: 1.55;
}

.case-points {
  display: grid;
  gap: 0;
  margin: 1.4rem 0 0;
}

.case-points div {
  display: grid;
  grid-template-columns: 4.5rem 1fr;
  gap: 0.75rem;
  padding: 0.7rem 0;
  border-top: 1px solid var(--line);
}

.case-points dt {
  color: var(--teal);
  font-size: 0.8rem;
  font-weight: 700;
}

.case-points dd {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.case-grid {
  display: grid;
  gap: 1.5rem;
  margin-top: 2.5rem;
}

@media (min-width: 760px) {
  .case-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.case-card {
  padding: 1.6rem;
  background: rgba(255, 253, 248, 0.72);
  border: 1px solid var(--line);
}

.case-card__type {
  margin: -0.3rem 0 0.85rem;
  color: var(--muted);
  font-size: 0.82rem;
}

.case-card__change {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 0.6rem;
  align-items: center;
  margin: 1.25rem 0;
  padding: 0.85rem;
  background: rgba(15, 143, 138, 0.07);
  font-size: 0.82rem;
  text-align: center;
}

.case-card__change b {
  color: var(--teal);
  font-size: 1.1rem;
}

.case-card > p:last-child {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.case-note,
.voice-note {
  margin: 1rem 0 0;
  color: var(--muted);
  font-size: 0.75rem;
}

/* Voice */
.section--voice {
  background: var(--white);
}

.voice-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 880px) {
  .voice-list {
    grid-template-columns: repeat(3, 1fr);
  }
}

.voice-item {
  position: relative;
  min-height: 280px;
  padding: 2rem 1.6rem 1.5rem;
  background: var(--paper);
  border-top: 3px solid var(--teal);
}

.voice-item__mark {
  display: block;
  height: 2.4rem;
  color: var(--sand);
  font-family: Georgia, serif;
  font-size: 4rem;
  line-height: 1;
}

.voice-item__quote {
  margin: 0.5rem 0 0;
  font-size: 0.98rem;
  line-height: 1.85;
}

.voice-item__meta {
  margin: 1.25rem 0 0;
  font-size: 0.82rem;
  color: var(--muted);
  letter-spacing: 0.04em;
}

.voice-item__meta span {
  display: inline-block;
  margin-right: 0.6rem;
  padding-right: 0.6rem;
  color: var(--teal-deep);
  border-right: 1px solid var(--line);
  font-weight: 600;
}

/* Contact */
.section--contact {
  background: var(--ink-soft);
  color: var(--white);
}

.section--contact .section__title {
  color: var(--white);
}

.section--contact .section__lead {
  color: rgba(255, 253, 248, 0.72);
}

.contact-form {
  display: grid;
  gap: 1rem;
  margin-top: 0.5rem;
}

.field {
  display: grid;
  gap: 0.4rem;
}

.field__label {
  font-size: 0.82rem;
  letter-spacing: 0.06em;
  color: rgba(255, 253, 248, 0.7);
}

.field input,
.field textarea {
  width: 100%;
  padding: 0.85rem 0.95rem;
  border: 1px solid rgba(255, 253, 248, 0.22);
  background: rgba(7, 18, 24, 0.45);
  color: var(--white);
  font: inherit;
  border-radius: var(--radius);
}

.field input:focus,
.field textarea:focus {
  outline: 2px solid var(--teal);
  outline-offset: 1px;
}

.field input::placeholder,
.field textarea::placeholder {
  color: rgba(255, 253, 248, 0.35);
}

.contact-form__note {
  margin: 0.25rem 0 0;
  font-size: 0.8rem;
  color: rgba(255, 253, 248, 0.5);
}

/* Footer */
.site-footer {
  background: var(--ink);
  color: rgba(255, 253, 248, 0.65);
  padding: 2.5rem 0;
}

.site-footer__inner {
  display: grid;
  gap: 0.35rem;
}

.site-footer__brand {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.2rem;
  color: var(--white);
}

.site-footer__brand span {
  color: var(--sand);
  margin-left: 0.12em;
}

.site-footer__copy,
.site-footer__legal {
  margin: 0;
  font-size: 0.82rem;
}

/* Reveal on scroll */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}
