:root {
  color-scheme: light;
  --ink: #281a13;
  --muted: #6f6056;
  --paper: #fffaf2;
  --paper-strong: #fffefb;
  --line: rgba(92, 62, 38, 0.15);
  --brown: #6f3617;
  --gold: #d9a053;
  --glow: #f0bd58;
  --night: #12110f;
  --night-soft: #1c1814;
  --radius: 28px;
  font-family: "Hiragino Sans", "Yu Gothic", YuGothic, system-ui, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 92% 5%, rgba(226, 167, 82, 0.18), transparent 30rem),
    var(--paper);
  font-size: 16px;
  line-height: 1.8;
}

a { color: inherit; }

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

.site-header {
  position: sticky;
  z-index: 10;
  top: 0;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 250, 242, 0.9);
  backdrop-filter: blur(16px);
}

.header-inner,
.page-shell,
.footer-inner {
  width: min(1120px, calc(100% - 40px));
  margin-inline: auto;
}

.header-inner {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.brand img { width: 184px; height: 61px; object-fit: contain; object-position: left center; }

.nav { display: flex; align-items: center; gap: 24px; }
.nav a { color: var(--muted); font-weight: 700; text-decoration: none; }
.nav a:hover, .nav a:focus-visible { color: var(--brown); }

.hero {
  min-height: 700px;
  display: grid;
  grid-template-columns: 1.04fr 0.96fr;
  align-items: center;
  gap: 72px;
  padding: 86px 0 92px;
}

.eyebrow {
  margin: 0 0 18px;
  color: var(--brown);
  font-size: 0.86rem;
  font-weight: 900;
  letter-spacing: 0.16em;
}

h1, h2, h3, p { margin-top: 0; }

h1 {
  margin-bottom: 24px;
  font-family: "Hiragino Mincho ProN", "Yu Mincho", YuMincho, serif;
  font-size: clamp(2.8rem, 7vw, 5.8rem);
  font-weight: 700;
  letter-spacing: -0.055em;
  line-height: 1.08;
}

.hero-copy {
  max-width: 37rem;
  margin-bottom: 34px;
  color: var(--muted);
  font-size: clamp(1.05rem, 2vw, 1.25rem);
}

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

.button {
  font: inherit;
  min-height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 22px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--brown);
  color: white;
  font-weight: 800;
  text-decoration: none;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.button:hover { transform: translateY(-2px); box-shadow: 0 10px 26px rgba(73, 39, 17, 0.2); }
.button.secondary { border-color: var(--line); background: var(--paper-strong); color: var(--ink); }

.app-visual {
  position: relative;
  isolation: isolate;
  display: grid;
  place-items: center;
}

.app-visual::before {
  content: "";
  position: absolute;
  z-index: -1;
  width: 82%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(240, 189, 88, 0.55), rgba(240, 189, 88, 0) 68%);
  filter: blur(18px);
}

.app-icon {
  width: min(440px, 82vw);
  border-radius: 25%;
  box-shadow: 0 38px 80px rgba(70, 37, 17, 0.22), 0 8px 24px rgba(70, 37, 17, 0.15);
}

.section { padding: 96px 0; }
.section.dark { color: #fff8ef; background: var(--night); }
.section-heading { max-width: 720px; margin-bottom: 42px; }
.section h2 { margin-bottom: 16px; font-size: clamp(2rem, 4vw, 3.25rem); letter-spacing: -0.035em; line-height: 1.25; }
.section-heading p { color: var(--muted); font-size: 1.08rem; }
.dark .section-heading p { color: #bfb3a9; }

.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.feature-card {
  min-height: 260px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 254, 251, 0.78);
}
.feature-card .number { color: var(--gold); font-size: 0.82rem; font-weight: 900; letter-spacing: 0.12em; }
.feature-card h3 { margin: 34px 0 12px; font-size: 1.35rem; }
.feature-card p { margin-bottom: 0; color: var(--muted); }

.map-story {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 64px;
  align-items: center;
}

.light-field {
  min-height: 470px;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 40px;
  background:
    radial-gradient(circle at 64% 38%, rgba(249, 200, 96, 0.95) 0 3px, rgba(249, 200, 96, 0.44) 5px 26px, transparent 88px),
    radial-gradient(circle at 43% 62%, rgba(249, 200, 96, 0.9) 0 3px, rgba(249, 200, 96, 0.35) 5px 22px, transparent 76px),
    radial-gradient(circle at 73% 72%, rgba(249, 200, 96, 0.85) 0 3px, rgba(249, 200, 96, 0.3) 5px 19px, transparent 64px),
    linear-gradient(145deg, #24201b, #0f0f0e);
}

.light-field::after {
  content: "あなたの記憶が、地図の光になる";
  position: absolute;
  inset: auto 30px 28px;
  color: rgba(255,255,255,0.76);
  font-family: "Hiragino Mincho ProN", "Yu Mincho", serif;
  font-size: 1rem;
  letter-spacing: 0.08em;
}

.story-list { display: grid; gap: 24px; }
.story-item { padding-bottom: 22px; border-bottom: 1px solid rgba(255,255,255,0.12); }
.story-item:last-child { border-bottom: 0; }
.story-item h3 { margin-bottom: 6px; }
.story-item p { margin-bottom: 0; color: #bfb3a9; }

.plan-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.plan-card { padding: 30px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper-strong); }
.plan-card.featured { border-color: rgba(111, 54, 23, 0.46); box-shadow: inset 0 4px 0 var(--gold); }
.plan-name { color: var(--brown); font-weight: 900; }
.price { margin: 12px 0 22px; font-size: 2.15rem; font-weight: 900; letter-spacing: -0.04em; }
.price small { font-size: 0.9rem; color: var(--muted); }
.plan-card ul { margin: 0; padding-left: 1.2rem; color: var(--muted); }

.note { margin-top: 24px; color: var(--muted); font-size: 0.9rem; }

[hidden] { display: none !important; }
.contact-shell { max-width: 860px; padding-bottom: 80px; }
.contact-card { margin: 24px 0; padding: clamp(20px,4vw,36px); background: var(--paper-strong); border: 1px solid var(--line); border-radius: var(--radius); }
.contact-card h2 { font-size: 1.45rem; margin: 20px 0; }
.contact-card p { color: var(--muted); }
.contact-form { display: grid; gap: 12px; }
.contact-form label { font-weight: 700; }
.contact-form input, .contact-form textarea { width: 100%; padding: 13px 16px; font: inherit; color: var(--ink); border: 1px solid #ac998a; border-radius: 12px; background: white; }
.contact-form textarea { resize: vertical; min-height: 120px; }
.contact-form .button { justify-self: start; }
button { font: inherit; cursor: pointer; }
button:disabled { opacity: .55; cursor: wait; }
button:disabled:hover { transform: none; box-shadow: none; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
.contact-toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 14px; margin: 20px 0; }
.contact-toolbar h2 { margin: 0; }
.ticket-list, .message-list { display: grid; gap: 14px; }
.ticket-link { display: grid; gap: 6px; padding: 20px; width: 100%; text-align: left; color: var(--ink); border: 1px solid var(--line); border-radius: 16px; background: var(--paper-strong); overflow-wrap: anywhere; }
.ticket-link span { font-size: .9rem; color: var(--muted); }
.contact-pagination { margin: 24px 0; }
.support-message { border: 1px solid var(--line); border-radius: 16px; padding: 20px; }
.support-message.operator { border-left: 4px solid var(--brown); background: #fff7e9; }
.message-body { white-space: pre-wrap; overflow-wrap: anywhere; }
.contact-feedback { padding: 12px 0; margin-bottom: 8px; min-height: 2.5rem; overflow-wrap: anywhere; }
.contact-feedback.error { color: #9b2929; font-weight: 700; }

.page-hero { padding: 76px 0 40px; }
.page-hero h1 { font-size: clamp(2.5rem, 6vw, 4.5rem); }
.prose { max-width: 800px; padding-bottom: 96px; }
.prose h2 { margin-top: 48px; font-size: 1.5rem; }
.prose h3 { margin-top: 30px; font-size: 1.1rem; }
.prose p, .prose li { color: var(--muted); }
.prose li + li { margin-top: 8px; }

.draft-banner {
  margin-bottom: 34px;
  padding: 18px 20px;
  border: 1px solid #d89c3d;
  border-radius: 16px;
  background: #fff2d9;
  color: #5f3611;
  font-weight: 700;
}

.invite-card {
  max-width: 660px;
  margin: 72px auto 100px;
  padding: clamp(26px, 6vw, 56px);
  border: 1px solid var(--line);
  border-radius: 34px;
  background: var(--paper-strong);
  text-align: center;
  box-shadow: 0 24px 70px rgba(75, 45, 25, 0.12);
}
.invite-card .app-icon { width: 112px; margin: 0 auto 24px; }
.invite-code { margin: 24px 0; padding: 14px; border-radius: 14px; background: #f4eadc; font: 900 1.35rem ui-monospace, monospace; letter-spacing: 0.12em; }
.invite-status { min-height: 1.8em; color: var(--muted); }

.site-footer { border-top: 1px solid var(--line); padding: 36px 0; background: var(--paper-strong); }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; color: var(--muted); }
.footer-links { display: flex; flex-wrap: wrap; gap: 18px; }
.footer-links a { text-decoration: none; }

@media (max-width: 860px) {
  .nav a:not(.nav-primary) { display: none; }
  .hero { min-height: auto; grid-template-columns: 1fr; gap: 46px; padding-top: 56px; }
  .hero-content { text-align: center; }
  .hero-copy { margin-inline: auto; }
  .actions { justify-content: center; }
  .feature-grid, .plan-grid { grid-template-columns: 1fr; }
  .map-story { grid-template-columns: 1fr; }
  .light-field { min-height: 360px; }
}

@media (max-width: 560px) {
  .header-inner, .page-shell, .footer-inner { width: min(100% - 28px, 1120px); }
  .brand img { width: 146px; height: 52px; }
  .hero { padding: 44px 0 64px; }
  .section { padding: 70px 0; }
  .feature-card { min-height: 0; }
  .footer-inner { align-items: flex-start; flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}
