body{
  margin:0;
  padding:20px 20px 180px 20px;
  background:#f3f4f6;
  font-family:sans-serif;
}

.container{
  max-width:1100px;
  margin:auto;
}

h1{
  text-align:center;
  margin-bottom:30px;
}

.topBar{
  margin-bottom:20px;
}

select{
  width:100%;
  padding:14px;
  border:none;
  border-radius:12px;
  font-size:16px;
}

.controls{
  display:flex;
  gap:10px;
  margin-bottom:20px;
}

button{
  flex:1;
  padding:14px;
  border:none;
  border-radius:12px;
  background:#2563eb;
  color:white;
  font-size:18px;
  cursor:pointer;
}

button:hover{
  opacity:0.9;
}

#showAnswerButton{
  background:#dc2626;
}

.card{
  background:white;
  padding:25px;
  border-radius:14px;
  margin-bottom:20px;
  box-shadow:0 2px 8px rgba(0,0,0,0.08);
}

.question{
  margin-bottom:45px;
}

.jp{
  font-size:18px;
  margin-bottom:12px;
  color:#374151;
  line-height:1.8;
}

.en{
  font-size:26px;
  line-height:2.8;
}

.blank{
  display:inline-flex;
  align-items:center;
  justify-content:center;

  min-width:130px;
  min-height:52px;

  border-bottom:3px solid #111827;

  margin:0 6px;

  background:#f9fafb;

  vertical-align:middle;

  transition:0.15s;

  border-radius:8px;
}

.blank:hover{
  background:#e0f2fe;
}

.word{
  display:inline-flex;
  align-items:center;
  justify-content:center;

  padding:12px 18px;

  background:#dbeafe;

  border-radius:12px;

  margin:6px;

  cursor:pointer;

  font-size:20px;

  user-select:none;

  transition:0.15s;
}

.word:hover{
  transform:scale(1.05);
}

.word.selected{
  background:#2563eb;
  color:white;
  transform:scale(1.08);
}

.word.used{
  opacity:0.35;
}

.correct{
  background:#dcfce7 !important;
}

.wrong{
  background:#fee2e2 !important;
}

.answer{
  color:#dc2626;
  font-weight:bold;
}

#resultArea{
  text-align:center;
  font-size:30px;
  font-weight:bold;
  margin:20px 0 120px 0;
}


/* 固定単語リスト */

.wordBankWrapper{

  position:fixed;

  left:0;
  right:0;
  bottom:0;

  background:white;

  border-top:2px solid #d1d5db;

  box-shadow:0 -2px 10px rgba(0,0,0,0.08);

  z-index:999;

}

.wordBankHeader{

  padding:10px 16px;

  font-size:18px;
  font-weight:bold;

  border-bottom:1px solid #e5e7eb;

  background:#f9fafb;
}

#wordBank{

  display:flex;
  flex-wrap:wrap;

  align-content:flex-start;

  overflow-y:auto;

  max-height:140px;

  padding:10px;
}


/* スマホ */

@media screen and (max-width:700px){

  body{
    padding:14px 14px 200px 14px;
  }

  .controls{
    flex-direction:column;
  }

  .en{
    font-size:20px;
    line-height:2.6;
  }

  .jp{
    font-size:16px;
  }

  .word{
    font-size:17px;
    padding:10px 14px;
  }

  .blank{
    min-width:100px;
    min-height:46px;
  }

  #wordBank{
    max-height:170px;
  }

}