* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html,
body {
  width: 100%;
  height: 100%;
  min-height: 100%;
  margin: 0;
  overflow: hidden;
}

body {
  min-height: 100dvh;
  color: #4b372d;
  font-family: system-ui, -apple-system, "Noto Sans JP", sans-serif;
  background: linear-gradient(#fff7df, #ffe8b0);
}

.home-shell {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100dvh;
  padding:
    max(8px, env(safe-area-inset-top, 0px))
    max(8px, env(safe-area-inset-right, 0px))
    max(8px, env(safe-area-inset-bottom, 0px))
    max(8px, env(safe-area-inset-left, 0px));
}

.home-card {
  display: flex;
  flex-direction: column;
  width: min(100%, 760px);
  max-height: 100%;
  padding: clamp(10px, 2vw, 18px);
  text-align: center;
  background: #fff;
  border: clamp(4px, 1vw, 6px) solid #ffbd3e;
  border-radius: clamp(22px, 4vw, 32px);
  box-shadow: 0 8px 0 #e59a13;
}

.home-card p {
  margin: 0 0 clamp(8px, 1.4vh, 14px);
  font-size: clamp(12px, 2.7vw, 15px);
  font-weight: 800;
}

.game-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(10px, 2vw, 16px);
  width: 100%;
}

.game-choice {
  display: flex;
  min-width: 0;
  padding: 0;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  color: #4b372d;
  text-decoration: none;
  background: transparent;
  border: 0;
  box-shadow: none;
  transition: transform 0.15s ease;
}

.game-choice-wide {
  grid-column: 1 / -1;
  width: min(48%, 320px);
  justify-self: center;
}

.game-choice:active {
  transform: translateY(3px) scale(.98);
}

.game-choice span:last-child {
  max-width: 100%;
  margin-top: 8px;
  font-size: clamp(10px, 2.4vw, 14px);
  font-weight: 800;
  line-height: 1.25;
  text-wrap: balance;
}

@media (max-height: 720px) {
  .home-card {
    padding: 8px;
  }

  .home-card p {
    margin-bottom: 6px;
    font-size: 11px;
  }

  .game-grid {
    gap: 8px;
  }

  .game-choice span:last-child {
    margin-top: 5px;
    font-size: 9px;
  }
}
