:root {
  --bg: #f3f1ec;
  --paper: #fbfaf7;
  --text: #151515;
  --muted: #4a4a4a;
  --line: #1f1f1f;
  --accent: #cf3828;
  --container: 1120px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  color: var(--text);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.3), transparent 28%),
    url("./assets/grid-overlay.svg"),
    repeating-linear-gradient(90deg, transparent, transparent 138px, rgba(0, 0, 0, 0.03) 139px, rgba(0, 0, 0, 0.03) 140px),
    var(--bg);
  background-size:
    auto,
    240px 240px,
    auto,
    auto;
  animation: driftGrid 26s linear infinite;
  font-family: "Zen Kaku Gothic New", "Hiragino Sans", "Yu Gothic", sans-serif;
  line-height: 1.7;
  letter-spacing: 0.02em;
}

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

.container {
  width: min(var(--container), 100% - 48px);
  margin: 0 auto;
}

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

.skip-link {
  position: absolute;
  left: 12px;
  top: 10px;
  transform: translateY(-180%);
  border: 1px solid var(--line);
  background: var(--paper);
  padding: 8px 12px;
  z-index: 99;
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(243, 241, 236, 0.92);
  border-bottom: 1px solid transparent;
  backdrop-filter: blur(8px);
}

.site-header.is-scrolled {
  border-bottom-color: var(--line);
}

.header-inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 74px;
}

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

.brand-logo {
  display: block;
  width: auto;
  height: 46px;
  object-fit: contain;
}

.brand-company {
  font-family: "Barlow Condensed", "Zen Kaku Gothic New", sans-serif;
  font-size: 25px;
  font-weight: 700;
  letter-spacing: 0.03em;
  line-height: 1;
  white-space: nowrap;
}

.site-nav {
  display: none;
  gap: 6px;
  position: absolute;
  z-index: 41;
  top: 73px;
  right: 0;
  min-width: 240px;
  border: 1px solid var(--line);
  background: var(--paper);
  padding: 10px;
  flex-direction: column;
}

.site-nav a {
  border: 1px solid var(--line);
  padding: 9px 11px;
  font-size: 13px;
  background: #f4f1e9;
}

.site-nav a:hover {
  background: #ece8df;
}

.nav-toggle {
  display: inline-block;
  background: transparent;
  border: 1px solid var(--line);
  width: 42px;
  height: 38px;
  padding: 0;
  cursor: pointer;
}

.nav-toggle-lines {
  display: block;
  width: 18px;
  height: 2px;
  margin: 0 auto;
  background: var(--line);
  position: relative;
}

.nav-toggle-lines::before,
.nav-toggle-lines::after {
  content: "";
  position: absolute;
  left: 0;
  width: 18px;
  height: 2px;
  background: var(--line);
}

.nav-toggle-lines::before {
  top: -6px;
}

.nav-toggle-lines::after {
  top: 6px;
}

.nav-open .nav-toggle-lines {
  background: transparent;
}

.nav-open .nav-toggle-lines::before {
  top: 0;
  transform: rotate(45deg);
}

.nav-open .nav-toggle-lines::after {
  top: 0;
  transform: rotate(-45deg);
}

.nav-open .site-nav {
  display: flex;
}

section {
  scroll-margin-top: 84px;
}

.hero {
  padding: 96px 0 86px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  border: 1px solid var(--line);
  background: var(--paper);
  padding: 36px;
}

.hero-copy {
  display: grid;
  gap: 18px;
  max-width: 880px;
}

.hero-label {
  margin: 0;
  font-family: "Barlow Condensed", sans-serif;
  font-size: 16px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
}

.hero-title {
  margin: 0;
  font-family: "Barlow Condensed", sans-serif;
  font-size: clamp(56px, 10.4vw, 132px);
  line-height: 0.94;
  letter-spacing: 0.02em;
  animation: headlineIn 900ms cubic-bezier(0.22, 1, 0.36, 1) 100ms both;
}

.hero-lead {
  margin: 0;
  max-width: 56ch;
  font-size: 15px;
  color: var(--muted);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 186px;
  padding: 12px 16px;
  border: 1px solid var(--line);
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: transform 240ms ease, box-shadow 240ms ease, background-color 240ms ease;
}

.btn.solid {
  background: var(--accent);
  color: #f6f6f6;
}

.btn.solid:hover {
  background: var(--accent);
  box-shadow: 0 12px 24px rgba(207, 56, 40, 0.25);
  transform: translateY(-2px);
}

.btn.line:hover {
  background: #ece8df;
  transform: translateY(-2px);
}

.hero-panel {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.hero-panel span {
  display: grid;
  place-items: center;
  min-height: 66px;
  border: 1px solid var(--line);
  font-family: "Barlow Condensed", sans-serif;
  font-size: 28px;
  letter-spacing: 0.05em;
  transition: transform 280ms ease, background-color 280ms ease;
}

.hero-panel span:hover {
  transform: translateY(-3px);
  background: #efebe3;
}

.hero-visual-wrap {
  width: 100%;
}

.hero-visual {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  min-height: 0;
  object-fit: cover;
  border: 1px solid var(--line);
  animation: visualFloat 12s ease-in-out infinite;
}

.section {
  padding: 82px 0;
}

.section-head {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 22px;
  align-items: end;
  margin-bottom: 22px;
}

.section-index {
  margin: 0;
  font-family: "Barlow Condensed", sans-serif;
  font-size: clamp(56px, 9vw, 92px);
  line-height: 0.8;
  color: var(--accent);
}

.section-head h2 {
  margin: 0;
  font-size: clamp(30px, 5vw, 56px);
  line-height: 1;
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

.service-card {
  border: 1px solid var(--line);
  background: var(--paper);
  padding: 26px;
  transform: translateY(0);
  transition: transform 300ms ease, box-shadow 300ms ease, border-color 300ms ease;
}

.service-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.1);
  border-color: rgba(207, 56, 40, 0.75);
}

.service-card h3 {
  margin: 0 0 10px;
  font-size: 26px;
  line-height: 1.2;
}

.service-image {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 7 / 5;
  object-fit: cover;
  border: 1px solid var(--line);
  margin-bottom: 16px;
  transition: transform 420ms ease;
}

.service-card:hover .service-image {
  transform: scale(1.02);
}

.service-card p {
  margin: 0;
  color: var(--muted);
}

.company {
  background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.28) 38%, transparent);
}

.section-visual {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--line);
  margin-bottom: 22px;
}

.profile {
  margin: 0;
  border-top: 1px solid var(--line);
}

.profile-row {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 14px;
  border-bottom: 1px solid var(--line);
  padding: 16px 8px;
}

.profile-row dt {
  font-weight: 700;
}

.profile-row dd {
  margin: 0;
}

.profile-row a {
  text-decoration: underline;
}

.contact-box {
  border: 1px solid var(--line);
  background: var(--text);
  color: #f7f7f7;
  padding: 36px;
  display: grid;
  gap: 12px;
  position: relative;
  overflow: hidden;
}

.contact-box::after {
  content: "";
  position: absolute;
  right: -48px;
  top: -48px;
  width: 170px;
  height: 170px;
  border: 1px solid rgba(255, 255, 255, 0.45);
  transform: rotate(22deg);
}

.contact-visual {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--line);
  margin-bottom: 14px;
}

.contact-box h2 {
  margin: 0;
  font-size: clamp(30px, 5vw, 56px);
  line-height: 1;
}

.contact-box .section-index {
  color: #ff8a79;
}

.contact-form {
  display: grid;
  gap: 12px;
  margin-top: 8px;
}

.form-row {
  display: grid;
  gap: 6px;
}

.form-row label {
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.75);
}

.form-row input,
.form-row select,
.form-row textarea {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.45);
  background: rgba(21, 21, 21, 0.85);
  color: #f7f7f7;
  padding: 10px 12px;
  font-size: 14px;
  font-family: inherit;
  letter-spacing: 0.02em;
}

.form-row input::placeholder,
.form-row textarea::placeholder {
  color: rgba(255, 255, 255, 0.45);
}

.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
  outline: none;
  border-color: #ff8a79;
  box-shadow: 0 0 0 2px rgba(255, 138, 121, 0.2);
}

.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 4px;
}

.contact-box .btn.line {
  color: #f7f7f7;
  border-color: rgba(255, 255, 255, 0.7);
}

.contact-box .btn.line:hover {
  background: rgba(255, 255, 255, 0.12);
}

.contact-note {
  margin: 0;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.65);
}

.site-footer {
  border-top: 1px solid var(--line);
  padding: 18px 0 28px;
}

.footer-inner {
  font-size: 12px;
}

.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 700ms ease, transform 700ms ease;
}

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

.delay-1 {
  transition-delay: 120ms;
}

.delay-2 {
  transition-delay: 220ms;
}

@keyframes driftGrid {
  0% {
    background-position:
      0 0,
      0 0,
      0 0,
      0 0;
  }
  100% {
    background-position:
      0 0,
      120px 80px,
      0 0,
      0 0;
  }
}

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

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

@media (max-width: 900px) {
  .hero {
    padding: 74px 0 64px;
  }

  .hero-grid {
    padding: 24px;
  }

  .hero-copy {
    gap: 14px;
  }

  .section {
    padding: 62px 0;
  }

  .service-grid {
    grid-template-columns: 1fr;
  }

  .profile-row {
    grid-template-columns: 1fr;
    gap: 3px;
    padding: 14px 6px;
  }
}

@media (max-width: 640px) {
  .container {
    width: min(var(--container), 100% - 30px);
  }

  .brand-logo {
    height: 40px;
  }

  .brand-company {
    font-size: 24px;
  }

  .hero-title {
    font-size: clamp(44px, 17vw, 82px);
    line-height: 0.93;
  }

  .hero-panel {
    grid-template-columns: 1fr;
  }

  .section-head {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .contact-box {
    padding: 24px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}
