:root {
  --green: #315d25;
  --deep: #173a18;
  --cream: #f5f2e8;
  --panel: 320px;
  --header: 64px;
}
.splash {
  position: fixed;
  z-index: 9999;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  color: #fff;
  background: radial-gradient(circle at 50% 45%, #152219 0, #050706 45%, #000 78%);
  opacity: 1;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}
.splash:before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: 35%;
  background: linear-gradient(90deg, transparent, #9ed6a811, transparent);
  transform: translateX(-250%);
  animation: splash-light 2.7s ease-in-out 0.2s both;
}
.is-embedded .splash {
  display: none;
}
.splash.is-leaving {
  visibility: hidden;
  opacity: 0;
}
.splash-copy {
  position: relative;
  text-align: center;
}
.splash-copy:before,
.splash-copy:after {
  content: "";
  position: absolute;
  left: 50%;
  width: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, #83c892, transparent);
  transform: translateX(-50%);
  animation: splash-line 1.2s ease 0.25s forwards;
}
.splash-copy:before {
  top: -28px;
}
.splash-copy:after {
  bottom: -30px;
  animation-delay: 1.65s;
}
.splash-copy span {
  display: block;
  margin-bottom: 13px;
  color: #9ed6a8;
  font-family: Georgia, serif;
  font-size: 18px;
  letter-spacing: 0.18em;
}
.splash-copy > span {
  opacity: 0;
  filter: blur(5px);
  transform: translateY(10px);
  animation: splash-brand 0.8s ease 0.15s forwards;
}
.splash-copy h1 {
  margin: 0;
  font-size: clamp(24px, 4.2vw, 48px);
  line-height: 1.45;
  letter-spacing: 0.05em;
}
.splash-copy [data-reveal] > i {
  display: inline-block;
  opacity: 0;
  filter: blur(8px);
  font-style: normal;
  transform: translate3d(-13px, 22px, 0) scale(0.96);
  animation: splash-character 0.48s cubic-bezier(0.18, 0.8, 0.24, 1) var(--delay) forwards;
}
.splash-copy p {
  margin: 14px 0 0;
  color: #dce8df;
  font-size: clamp(12px, 1.5vw, 17px);
  font-weight: 700;
  letter-spacing: 0.08em;
}
@keyframes splash-brand {
  to {
    opacity: 1;
    filter: blur(0);
    transform: translateY(0);
  }
}
@keyframes splash-character {
  to {
    opacity: 1;
    filter: blur(0);
    transform: translate3d(0, 0, 0) scale(1);
  }
}
@keyframes splash-line {
  to {
    width: min(680px, 92vw);
  }
}
@keyframes splash-light {
  45%,
  65% {
    transform: translateX(95vw);
  }
  100% {
    transform: translateX(260vw);
  }
}
@media (prefers-reduced-motion: reduce) {
  .splash-copy {
    transform: none;
  }
  .splash-copy > span,
  .splash-copy [data-reveal] > i {
    opacity: 1;
    filter: none;
    transform: none;
    animation: none;
  }
}
* {
  box-sizing: border-box;
}
html,
body {
  width: 100%;
  height: 100%;
  margin: 0;
  color: #172119;
  font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", "Yu Gothic", Meiryo,
    sans-serif;
  background: #d8eaf4;
}
button,
a {
  font: inherit;
}
button {
  cursor: pointer;
}
.topbar {
  height: var(--header);
  display: grid;
  grid-template-columns: 230px 1fr 230px;
  align-items: center;
  padding: 0 14px;
  background: #fff;
  box-shadow: 0 2px 12px #0002;
  position: relative;
  z-index: 30;
}
.brand {
  display: flex;
  gap: 7px;
  align-items: center;
  color: var(--green);
  text-decoration: none;
}
.brand-mark {
  font-size: 34px;
  line-height: 1;
}
.brand b {
  display: block;
  font-family: Georgia, serif;
  font-size: 22px;
}
.brand small {
  display: block;
  font-size: 7px;
  letter-spacing: 0.1em;
}
.title {
  text-align: center;
}
.title h1 {
  font-size: 16px;
  margin: 0;
}
.title p {
  font-size: 10px;
  margin: 3px 0 0;
  font-weight: 700;
}
.header-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}
.header-actions button {
  border: 1px solid #9bad94;
  border-radius: 18px;
  background: #fff;
  color: #315d25;
  padding: 8px 11px;
  font-size: 11px;
  font-weight: 800;
}
.header-actions button:first-child {
  background: var(--green);
  color: #fff;
}
.header-actions b {
  display: inline-grid;
  place-items: center;
  width: 17px;
  height: 17px;
  border-radius: 50%;
  background: #fff;
  color: var(--green);
}
.app-shell {
  height: calc(100% - var(--header));
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  overflow: hidden;
}
.app-shell.detail-open {
  grid-template-columns: minmax(0, 1fr) var(--panel);
}
.map-area {
  position: relative;
  display: grid;
  grid-template-columns: 182px minmax(0, 1fr);
  min-width: 0;
  overflow: hidden;
  background: url("park-background.jpg") center / cover no-repeat;
}
.viewport {
  position: relative;
  grid-column: 2;
  min-width: 0;
  height: 100%;
  overflow: hidden;
  touch-action: none;
  cursor: grab;
  background: url("park-background.jpg") center / cover no-repeat;
}
.viewport.dragging {
  cursor: grabbing;
}
.park {
  position: absolute;
  left: 0;
  top: 0;
  width: 1362px;
  height: 1155px;
  transform-origin: 0 0;
  will-change: transform;
  background: url("park-background.jpg") center / 100% 100% no-repeat;
}
.park:after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  box-shadow: inset 0 0 45px #16351b22;
}
.house-card {
  position: absolute;
  width: 250px;
  height: 265px;
  border: 0;
  background: none;
  padding: 0;
  z-index: 2;
  color: #102215;
  text-align: center;
}
.house-card:before {
  content: "";
  position: absolute;
  left: 18%;
  right: 18%;
  bottom: 27px;
  height: 9px;
  border-radius: 50%;
  background: #263e2555;
  filter: blur(7px);
}
.house-card .label {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  font-weight: 800;
  font-size: 12px;
  line-height: 1.2;
  text-shadow: 0 1px 2px #fff;
}
.house-card .num {
  display: inline-grid;
  place-items: center;
  margin-right: 6px;
  width: 21px;
  height: 21px;
  border-radius: 50%;
  background: #174e1b;
  color: #fff;
  font-size: 11px;
}
.house-card .product {
  display: block;
  font-size: 11px;
  margin-top: 2px;
}
.house-card img {
  position: absolute;
  width: 100%;
  height: 195px;
  left: 0;
  bottom: 15px;
  object-fit: contain;
  filter: drop-shadow(0 7px 5px #0004);
  transition: 0.18s;
}
.house-card:hover img,
.house-card:focus-visible img {
  transform: scale(1.08);
  filter: drop-shadow(0 10px 8px #0006);
}
.house-card.selected img {
  transform: scale(1.11);
  filter: drop-shadow(0 0 4px #fff) drop-shadow(0 0 10px #315d25);
}
.house-card.chosen:after {
  content: "選択中 ✓";
  position: absolute;
  right: 12px;
  bottom: 34px;
  z-index: 3;
  padding: 5px 9px;
  color: #fff;
  background: #237a3d;
  border: 2px solid #fff;
  border-radius: 999px;
  box-shadow: 0 4px 12px #0004;
  font-size: 10px;
  font-weight: 900;
}
.house-card.selected .label {
  color: #173f18;
}
.map-card {
  position: absolute;
  z-index: 6;
  left: 12px;
  top: 12px;
  width: 112px;
  padding: 9px;
  border-radius: 10px;
  background: #27332edb;
  color: #fff;
  box-shadow: 0 4px 12px #0004;
  text-align: center;
  font-size: 10px;
}
.side-controls {
  position: relative;
  grid-column: 1;
  grid-row: 1;
  z-index: 8;
  top: auto;
  left: auto;
  display: flex;
  flex-direction: column;
  gap: 9px;
  width: 100%;
  height: 100%;
  max-height: 100%;
  padding: 12px;
  overflow-y: auto;
  background: #16271f99;
  border-right: 1px solid #ffffff55;
  box-shadow: 5px 0 18px #0003;
  backdrop-filter: blur(6px);
  scrollbar-width: none;
}
.side-controls::-webkit-scrollbar {
  display: none;
}
.side-controls .map-card {
  position: static;
  width: 100%;
  padding: 12px;
  font-size: 12px;
}
.side-controls .selection-tray {
  position: static;
  width: 100%;
  padding: 10px;
}
.selection-header {
  display: block;
  width: 100%;
  padding: 0;
  color: #fff;
  background: none;
  border: 0;
  text-align: left;
}
.selection-header strong,
.selection-header small {
  display: block;
}
.side-nav {
  display: grid;
  gap: 6px;
  padding: 9px;
  background: #26322ee8;
  border: 1px solid #ffffff44;
  border-radius: 13px;
  box-shadow: 0 5px 16px #0004;
  backdrop-filter: blur(8px);
}
.side-nav a,
.side-nav button {
  display: flex;
  min-height: 35px;
  align-items: center;
  justify-content: center;
  padding: 7px 8px;
  color: #fff;
  background: #ffffff10;
  border: 1px solid #ffffff22;
  border-radius: 9px;
  font-size: 10px;
  font-weight: 800;
  text-align: center;
  text-decoration: none;
}
.side-nav .next-diagnosis {
  background: linear-gradient(135deg, #2c8a45, #15542b);
  border-color: #78b984;
  box-shadow: 0 4px 13px #0b311c88;
}
.side-nav .next-diagnosis b {
  margin-left: 5px;
  padding: 2px 6px;
  color: #15542b;
  background: #fff;
  border-radius: 10px;
}
.side-nav .next-diagnosis:disabled {
  cursor: not-allowed;
  opacity: 0.52;
  box-shadow: none;
}
.selection-tray {
  position: absolute;
  z-index: 7;
  top: 12px;
  right: 12px;
  width: 225px;
  padding: 10px;
  color: #fff;
  background: #27332ee8;
  border: 1px solid #ffffff44;
  border-radius: 12px;
  box-shadow: 0 5px 16px #0004;
  backdrop-filter: blur(8px);
}
.selection-tray > div:first-child {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.selection-tray strong {
  font-size: 15px;
  line-height: 1.25;
}
.selection-tray small {
  font-size: 10px;
  line-height: 1.45;
  color: #dbe8dc;
}
.selection-thumbs {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 70px;
  margin-top: 7px;
}
.selection-thumbs span {
  align-self: center;
  font-size: 11px;
  line-height: 1.4;
  color: #dbe8dc;
}
.selection-thumb {
  position: relative;
  flex: none;
  width: 100%;
  height: auto;
  aspect-ratio: 2 / 1;
  overflow: hidden;
  padding: 0;
  border: 2px solid #fff;
  border-radius: 7px;
  background: linear-gradient(#c7e9f8, #a5c487);
}
.selection-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  image-rendering: auto;
  transform: translateZ(0);
}
.mini-map {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 5px;
  margin-top: 7px;
  padding: 8px;
  background: linear-gradient(#bfe5fa, #9bb57c);
  border-radius: 6px;
}
.mini-dot {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 1px solid #fff;
  background: #174e1b;
  color: #fff;
  font-size: 10px;
  font-weight: 900;
}
.mini-dot.active {
  background: #f1b91c;
  color: #172119;
}
.zoom-tools {
  position: absolute;
  z-index: 6;
  left: 180px;
  bottom: 18px;
  width: 42px;
  overflow: hidden;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 4px 12px #0003;
  text-align: center;
}
.side-controls .zoom-tools {
  position: static;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  width: 100%;
  border-radius: 12px;
}
.side-controls .zoom-tools button,
.side-controls .zoom-tools output {
  width: auto;
  height: 36px;
}
.side-controls .zoom-tools output {
  border: 0;
  border-inline: 1px solid #ddd;
}
.zoom-tools button,
.zoom-tools output {
  display: grid;
  place-items: center;
  width: 42px;
  height: 40px;
  border: 0;
  background: #fff;
}
.focus-action {
  position: absolute;
  z-index: 9;
  left: calc(182px + (100% - 182px) / 2);
  bottom: 18px;
  transform: translateX(-50%);
  min-width: 280px;
  padding: 9px 18px;
  color: #fff;
  background: #26322eee;
  border: 1px solid #ffffff55;
  border-radius: 22px;
  box-shadow: 0 8px 24px #0005;
  backdrop-filter: blur(8px);
}
.focus-action[hidden] {
  display: none;
}
.focus-action span,
.focus-action b {
  display: block;
}
.focus-action span {
  overflow: hidden;
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.focus-action b {
  margin-top: 2px;
  color: #b7edc0;
  font-size: 12px;
}
.zoom-tools button {
  font-size: 22px;
}
.zoom-tools output {
  font-size: 9px;
  border-block: 1px solid #ddd;
}
.detail-panel {
  background: #fff;
  overflow: auto;
  box-shadow: -5px 0 18px #0003;
  z-index: 20;
}
.detail-panel[hidden] {
  display: none;
}
.panel-head {
  height: 35px;
  padding: 0 10px;
  background: #29332f;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
}
.panel-head button {
  border: 0;
  background: none;
  color: #fff;
  font-size: 10px;
}
.hero {
  height: 155px;
  background: linear-gradient(#bce3f8, #e9f4ec 64%, #95b679 65%);
  position: relative;
  overflow: hidden;
}
.hero img {
  width: 100%;
  height: 145px;
  object-fit: contain;
  filter: drop-shadow(0 7px 5px #0005);
}
.dots {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 8px;
  text-align: center;
}
.dots i {
  display: inline-block;
  width: 5px;
  height: 5px;
  margin: 0 5px;
  border-radius: 50%;
  background: #ffffff99;
}
.dots i:first-child {
  background: #fff;
}
.detail-body {
  padding: 13px 15px 90px;
}
.maker-line {
  display: flex;
  align-items: center;
  gap: 9px;
}
.maker-line span {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-weight: 900;
}
.maker-line p {
  font-size: 13px;
  font-weight: 800;
  margin: 0;
}
.detail-body h2 {
  font-size: 22px;
  margin: 2px 0 8px;
}
.summary {
  font-size: 11px;
  line-height: 1.65;
  color: #475049;
}
.tags {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
  margin: 10px 0;
}
.tags span {
  padding: 5px 7px;
  border-radius: 14px;
  background: #eef1ed;
  font-size: 9px;
  font-weight: 700;
}
.specs {
  margin: 13px 0;
}
.specs div {
  padding: 8px 0;
  border-bottom: 1px solid #e5e7e4;
}
.specs dt {
  font-size: 9px;
  color: #788078;
}
.specs dd {
  margin: 2px 0 0;
  font-weight: 800;
  font-size: 13px;
}
.notice {
  font-size: 8px;
  line-height: 1.5;
  color: #777;
}
.outline-btn,
.primary-btn,
.land-btn {
  width: 100%;
  height: 38px;
  margin-top: 8px;
  border-radius: 20px;
  font-weight: 800;
  font-size: 11px;
}
.outline-btn {
  border: 1px solid var(--green);
  background: #fff;
  color: var(--green);
}
.primary-btn {
  border: 0;
  background: var(--green);
  color: #fff;
}
.primary-btn.active {
  background: #8b6c19;
}
.primary-btn:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}
.select-building-btn {
  min-height: 58px;
  height: auto;
  margin-top: 14px;
  padding: 12px 18px;
  border-radius: 16px;
  box-shadow: 0 8px 22px #17471f42;
  font-size: 15px;
  letter-spacing: 0.03em;
}
.select-building-btn b {
  margin-left: 5px;
  font-size: 17px;
}
.land-btn {
  border: 0;
  background: #e8f1e2;
  color: var(--green);
}
.bottom-nav {
  position: fixed;
  z-index: 40;
  left: 50%;
  bottom: 12px;
  transform: translateX(-50%);
  height: 43px;
  display: flex;
  align-items: center;
  padding: 0 15px;
  border-radius: 24px;
  background: #26322ee8;
  box-shadow: 0 5px 18px #0005;
  white-space: nowrap;
}
.bottom-nav a,
.bottom-nav button {
  border: 0;
  background: none;
  color: #fff;
  text-decoration: none;
  padding: 0 15px;
  font-size: 11px;
}
.bottom-nav .next-diagnosis {
  min-width: 190px;
  margin: 0 8px;
  padding: 9px 18px;
  color: #fff;
  background: linear-gradient(135deg, #2c8a45, #15542b);
  border-radius: 20px;
  box-shadow: 0 5px 16px #0b311c88;
  font-size: 12px;
  font-weight: 900;
}
.bottom-nav .next-diagnosis b {
  margin-left: 7px;
  padding: 2px 7px;
  color: #15542b;
  background: #fff;
  border-radius: 10px;
}
.bottom-nav .next-diagnosis:disabled {
  cursor: not-allowed;
  opacity: 0.55;
  box-shadow: none;
}
.bottom-nav i {
  width: 1px;
  height: 20px;
  background: #ffffff44;
}
.mobile-detail {
  display: none;
}
.mobile-detail[hidden] {
  display: none;
}
dialog {
  width: min(500px, calc(100% - 28px));
  border: 0;
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 18px 60px #0007;
}
dialog::backdrop {
  background: #112014aa;
  backdrop-filter: blur(3px);
}
dialog h2 {
  margin: 0 0 18px;
  color: var(--green);
}
dialog li {
  margin: 9px 0;
}
.dialog-close {
  position: absolute;
  right: 12px;
  top: 12px;
  border: 0;
  background: none;
  font-size: 20px;
}
.favorite-list {
  display: grid;
  gap: 8px;
}
.favorite-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px;
  border: 1px solid #ddd;
  border-radius: 10px;
}
.favorite-item img {
  width: 85px;
  height: 60px;
  object-fit: contain;
  background: #d8eff9;
}
.favorite-item b {
  display: block;
}
.favorite-item button {
  margin-left: auto;
  border: 0;
  background: #eee;
  border-radius: 15px;
  padding: 5px 8px;
}
.building-dialog {
  width: min(850px, calc(100% - 28px));
}
.building-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}
.building-grid button {
  border: 1px solid #ddd;
  border-radius: 10px;
  background: #fff;
  padding: 6px;
  text-align: left;
}
.building-grid img {
  width: 100%;
  height: 90px;
  object-fit: contain;
  background: linear-gradient(#cae9f8, #eef5e7);
}
.building-grid b,
.building-grid small {
  display: block;
}
.building-grid small {
  color: #667;
  font-size: 9px;
  margin-bottom: 3px;
}
@media (max-width: 780px) {
  :root {
    --header: 56px;
  }
  .topbar {
    grid-template-columns: 145px 1fr;
    padding: 0 8px;
  }
  .brand b {
    font-size: 18px;
  }
  .title h1 {
    font-size: 12px;
  }
  .title p {
    font-size: 8px;
  }
  .header-actions {
    display: none;
  }
  .app-shell {
    display: block;
  }
  .map-area {
    grid-template-columns: 145px minmax(0, 1fr);
    height: 100%;
  }
  .side-controls {
    top: auto;
    left: auto;
    width: 100%;
    height: 100%;
    gap: 6px;
    max-height: 100%;
    padding: 8px;
  }
  .side-controls .map-card {
    padding: 8px;
    font-size: 10px;
  }
  .side-controls .selection-tray,
  .side-nav {
    padding: 7px;
  }
  .side-nav {
    gap: 4px;
  }
  .side-nav a,
  .side-nav button {
    min-height: 31px;
    padding: 5px;
    font-size: 9px;
  }
  .mini-map {
    gap: 3px;
    padding: 6px;
  }
  .mini-dot {
    width: 20px;
    height: 20px;
    font-size: 8px;
  }
  .side-controls .zoom-tools {
    left: auto;
    bottom: auto;
  }
  .detail-panel {
    position: fixed;
    z-index: 50;
    left: 0;
    right: 0;
    bottom: 0;
    height: 76%;
    border-radius: 18px 18px 0 0;
    transform: translateY(105%);
    transition: 0.25s;
  }
  .selection-tray {
    top: 9px;
    right: 9px;
    width: 168px;
    padding: 8px;
  }
  .selection-tray > div:first-child {
    display: block;
  }
  .selection-tray small {
    display: block;
    margin-top: 3px;
    font-size: 9px;
  }
  .selection-thumb {
    width: 100%;
    height: auto;
  }
  .focus-action {
    left: calc(145px + (100% - 145px) / 2);
    bottom: 10px;
    min-width: min(240px, calc(100% - 165px));
    padding: 8px 12px;
  }
  .detail-panel.open {
    transform: translateY(0);
  }
  .mobile-detail {
    display: block;
    position: absolute;
    z-index: 8;
    right: 10px;
    bottom: 72px;
    border: 0;
    border-radius: 20px;
    background: var(--green);
    color: #fff;
    padding: 10px 14px;
    font-weight: 800;
  }
  .bottom-nav {
    bottom: 8px;
    width: calc(100% - 16px);
    justify-content: center;
    padding: 0 3px;
  }
  .bottom-nav a,
  .bottom-nav button {
    padding: 0 8px;
    font-size: 9px;
  }
  .bottom-nav .next-diagnosis {
    min-width: 0;
    flex: 1;
    margin: 0 3px;
    padding: 9px 7px;
    font-size: 9px;
  }
  .building-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
