japanese-conjugation-drill/conjugation/drill.css

581 lines
9.0 KiB
CSS
Raw Normal View History

body, input {
font-family: Amaranth, sans-serif;
2020-07-22 18:00:42 +00:00
background: #eee;
--other: #4A2067;
--neutral-dark: #441f00;
--incorrect: #992a2a;
--correct: #217b21;
--neutral: #995c2a;
--question-furigana: white;
--input-background: white;
--input-shadow: #888;
--input-color: white;
--shake-level: 6px;
}
/* #proceed svg {
2020-07-22 18:00:42 +00:00
display: inline-block;
width: 48px;
height: 48px;
}
2016-12-15 22:50:32 +00:00
#proceed button {
2020-07-22 18:00:42 +00:00
color: var(--input-color);
outline-width: 0;
2016-12-15 22:50:32 +00:00
border: none;
padding: 12px;
background: none;
} */
2016-12-15 22:50:32 +00:00
2016-11-22 01:59:30 +00:00
.questionOuter {
2020-07-22 18:00:42 +00:00
background: var(--other);
2016-11-22 01:59:30 +00:00
}
#question {
padding-top: 40px;
padding-bottom: 40px;
font-size: 20px;
text-shadow: 2px 2px 4px var(--neutral-dark);
color: white;
}
#questionFirstHalf,
#questionSecondHalf {
2016-11-22 01:59:30 +00:00
margin-left: auto;
margin-right: auto;
display: table;
}
#answer {
font-size: 16px;
}
#responseButton {
font-size: 16px;
line-height: 16px;
}
/* Responsive text size */
2020-08-07 01:05:59 +00:00
@media (max-width: 575px) {
.navbar-brand {
font-size: 1.15rem;
}
}
/* Small devices (landscape phones, 576px and up) */
@media (min-width: 576px) {
2020-08-07 01:05:59 +00:00
#question {
font-size: 32px;
}
#answer, .correct, .incorrect {
font-size: 24px;
}
#responseButton {
font-size: 24px;
line-height: 24px;
}
}
/* Medium devices (tablets, 768px and up) */
@media (min-width: 768px) {
2020-08-07 01:05:59 +00:00
#question {
font-size: 40px;
}
#answer, .correct, .incorrect {
font-size: 30px;
}
#responseButton {
font-size: 30px;
line-height: 30px;
}
}
/* Large devices (desktops, 992px and up) */
@media (min-width: 992px) {
2020-08-07 01:05:59 +00:00
#question {
font-size: 40px;
}
#answer, .correct, .incorrect {
font-size: 30px;
}
#responseButton {
font-size: 30px;
line-height: 30px;
}
}
/* Extra large devices (large desktops, 1200px and up) */
@media (min-width: 1200px) {
2020-08-07 01:05:59 +00:00
#question {
font-size: 40px;
}
#answer, .correct, .incorrect {
font-size: 30px;
}
#responseButton {
font-size: 30px;
line-height: 30px;
}
2016-11-22 01:59:30 +00:00
}
2020-07-22 18:00:42 +00:00
/*
2017-12-25 16:48:32 +00:00
#explanation {
width: 960px;
margin-left: auto;
margin-right: auto;
}
2020-07-22 18:00:42 +00:00
*/
2017-12-25 16:48:32 +00:00
2020-07-22 18:00:42 +00:00
#inputArea {
background: var(--input-background);
}
#inputArea, .correct, .incorrect {
box-shadow: 2px 2px 4px 0px var(--input-shadow);
width: calc(100vw - 32px);
margin-left: auto;
margin-right: auto;
margin-top: 16px;
margin-bottom: 16px;
2016-11-22 01:59:30 +00:00
}
#answer {
2020-07-22 18:00:42 +00:00
background: var(--input-background);
2016-11-22 01:59:30 +00:00
width: 100%;
border: 0;
padding-top: 12px;
padding-bottom: 12px;
text-align: center;
}
2020-07-22 18:00:42 +00:00
#answer, .correct, .incorrect {
height: 54px;
}
#answer:focus {
outline-width: 0;
}
/*
2016-11-22 01:59:30 +00:00
#message {
margin-top: 10px;
2016-11-22 01:59:30 +00:00
width: 100%;
}
#message > div {
padding-top: 4px;
padding-bottom: 4px;
text-align: center;
}
2020-07-22 18:00:42 +00:00
*/
2016-11-22 01:59:30 +00:00
.correct,
.incorrect {
padding-top: 12px;
padding-bottom: 12px;
text-align: center;
2020-07-22 18:00:42 +00:00
color: var(--input-color);
2016-11-22 01:59:30 +00:00
}
.correct {
background-color: var(--correct);
2016-11-22 01:59:30 +00:00
}
.incorrect {
background-color: var(--incorrect);
}
#responseButton {
border: none;
box-shadow: 2px 2px 4px 0px var(--input-shadow);
width: calc(100vw - 32px);
margin-left: auto;
margin-right: auto;
padding-top: 12px;
padding-bottom: 12px;
display: table;
color: var(--input-color);
2016-11-22 00:22:00 +00:00
}
2016-12-10 01:08:41 +00:00
2020-07-22 18:00:42 +00:00
/*
2016-12-10 01:08:41 +00:00
div#history,
div#explanation {
margin-left: auto;
margin-right: auto;
display: table;
}
table.syllabary {
border-collapse: collapse;
}
table.syllabary td {
padding: 12px;
font-size: 14px;
color: gray;
border: 1px solid gray;
text-align: center;
width: 32px;
height: 32px;
}
table.syllabary td div:first-child {
color: black;
font-size: 24px;
}
table.syllabary td.empty {
background: #eee;
}
2017-12-25 16:48:32 +00:00
table.word td {
font-size: 36px;
color: black;
text-align: center;
}
table.word td div:first-child {
margin: 0;
color: #aaa;
font-size: 18px;
font-weight: bold;
}
table.chart span.change,
table.word span.change {
color: #f06060;
}
2020-08-07 01:05:59 +00:00
*/
2017-12-25 16:48:32 +00:00
2016-12-10 01:08:41 +00:00
.answer-correct {
color: red;
}
.answer-wrong {
color: blue;
}
2020-08-07 01:05:59 +00:00
/*
2016-12-10 01:08:41 +00:00
div#history table {
border-collapse: collapse;
}
div#history table th,
div#history table td {
padding: 10px 16px 10px 16px;
2016-12-10 01:08:41 +00:00
border: 1px solid gray;
}:
div#history table th {
text-align: left;
}
2016-12-25 15:30:53 +00:00
div.options > * {
display: inline-block;
vertical-align: top;
margin: 20px;
}
div#splash > *,
div#scoreSection > * {
2016-12-25 15:30:53 +00:00
margin-left: auto;
margin-right: auto;
display: table;
margin-bottom: 12px;
2016-12-25 15:30:53 +00:00
}
2020-07-22 18:00:42 +00:00
*/
2016-12-25 15:30:53 +00:00
input#numQuestions {
width: 60px;
}
2016-12-25 15:51:49 +00:00
div.options ul {
list-style-type: none;
margin: 0;
padding-left: 16px;
}
2020-07-22 18:00:42 +00:00
2016-12-10 01:08:41 +00:00
/* Tooltip from http://jsfiddle.net/AndreaLigios/jtLbpy62/ */
[tooltip]:before {
/* needed - do not touch */
content: attr(tooltip);
position: absolute;
opacity: 0;
/* customizable */
transition: all 0.15s ease;
color: #333;
font-size: 12px;
}
[tooltip]:hover:before,
.furiganaAlways #question [tooltip]:before {
2016-12-10 01:08:41 +00:00
/* needed - do not touch */
opacity: 1;
/* customizable */
2017-12-26 17:34:46 +00:00
margin-top: -12px;
2016-12-10 01:08:41 +00:00
}
[tooltip]:not([tooltip-persistent]):before {
pointer-events: none;
}
2017-12-25 16:48:32 +00:00
2017-12-26 17:34:46 +00:00
/* Custom positions for furigana */
.tooltip-w1[tooltip]:before { font-size: 8px; margin-left: 4px; }
.tooltip-w2[tooltip]:before { font-size: 8px; margin-left: 0px; }
.tooltip-w3[tooltip]:before { font-size: 8px; margin-left: -4px; }
.tooltip-w1[tooltip]:hover:before,
.tooltip-w2[tooltip]:hover:before,
.tooltip-w3[tooltip]:hover:before { margin-top: -10px; }
2020-07-22 18:00:42 +00:00
#question .tooltip-w1[tooltip]:before { color: var(--question-furigana); font-size: 12px; margin-left: 14px; }
#question .tooltip-w2[tooltip]:before { color: var(--question-furigana); font-size: 12px; margin-left: 8px; }
#question .tooltip-w3[tooltip]:before { color: var(--question-furigana); font-size: 12px; margin-left: 2px; }
2017-12-26 17:34:46 +00:00
#question .tooltip-w1[tooltip]:hover:before, .furiganaAlways #question .tooltip-w1[tooltip]:before,
#question .tooltip-w2[tooltip]:hover:before, .furiganaAlways #question .tooltip-w2[tooltip]:before,
2020-07-22 18:00:42 +00:00
#question .tooltip-w3[tooltip]:hover:before, .furiganaAlways #question .tooltip-w3[tooltip]:before {
color: var(--question-furigana);
margin-top: -12px;
}
2017-12-26 17:34:46 +00:00
2020-07-22 18:00:42 +00:00
/*
2017-12-25 16:48:32 +00:00
div#explanation p span {
}
.highlight {
font-style: italic;
}
.horizontal-transform {
text-align: center;
}
.horizontal-transform > * {
display: inline-block;
vertical-align: middle;
}
.transform-arrow {
font-size: 32px;
color: #888;
margin: 16px;
}
div.conjugation-chart {
border: 2px solid gray;
border-radius: 32px;
padding: 24px;
background: #fff8f0;
margin-left: auto;
margin-right: auto;
display: table;
}
div.conjugation-chart h2 {
font-size: 28px;
}
div.conjugation-chart > * {
text-align: center;
}
table.chart + table.chart {
margin-left: 32px;
}
table.chart {
border-collapse: collapse;
}
table.chart td {
border: 1px solid gray;
padding-left: 16px;
padding-right: 16px;
background: white;
text-align: left;
}
table.chart td.break {
height: 1em;
border: 0;
background: inherit;
}
table.chart th {
border: 1px solid gray;
background: gray;
color: white;
}
table.chart td.title {
border: 0;
background: inherit;
font-size: 22px;
text-align: center;
}
div.horiz > * {
display: inline-block;
vertical-align: top;
}
.rules table.word td {
font-size: 24px;
color: black;
text-align: center;
}
.rules table.word td div:first-child {
margin: 0;
color: #aaa;
font-size: 12px;
}
.rules table.chart span.change {
color: black;
}
.rules table.word span.change {
color: #f06060;
}
.rules .transform-arrow {
font-size: 16px;
color: #888;
margin: 16px;
}
.brace {
fill: none;
fill-rule: evenodd;
stroke: #ccc;
stroke-width: 0.5px;
stroke-linecap: butt;
stroke-linejoin: miter;
stroke-opacity: 1;
}
.arrow {
margin-left: 16px;
margin-right: 16px;
}
2020-07-22 18:00:42 +00:00
*/
2017-12-25 16:48:32 +00:00
.tag {
display: inline-block;
border-radius: 3px;
background: orange;
padding-left: 6px;
padding-right: 6px;
padding-top: 2px;
padding-bottom: 2px;
}
2020-07-22 18:00:42 +00:00
/*
2017-12-25 16:48:32 +00:00
.options li {
height: 24px;
}
2020-07-22 18:00:42 +00:00
*/
2017-12-25 16:48:32 +00:00
.specials {
font-weight: bold;
margin-top: 10px;
margin-bottom: 10px;
}
2020-07-22 18:00:42 +00:00
h2, h4 {
font-weight: bold;
}
2020-08-07 01:05:59 +00:00
/* .options h4 {
} */
2020-07-22 18:00:42 +00:00
/*
2017-12-25 16:48:32 +00:00
.explain-answer-as-list li {
list-style-type: none;
}
.explain-answer-as-list {
padding-left: 24px;
}
.centre {
display: table;
margin: 0 auto;
}
2020-07-22 18:00:42 +00:00
*/
@media (max-width: 420px) {
#splash h2 {
font-size: 1.3em;
margin-bottom: 1.0em
}
}
@keyframes shake {
0% { transform: translate(0px, 0px); }
12.5% { transform: translate(calc(0px - var(--shake-level)), 0px); }
25% { transform: translate(var(--shake-level), 0px); }
37.5% { transform: translate(calc(0px - var(--shake-level)), 0px); }
50% { transform: translate(var(--shake-level), 0px); }
62.5% { transform: translate(calc(0px - var(--shake-level)), 0px); }
75% { transform: translate(var(--shake-level), 0px); }
87.5% { transform: translate(calc(0px - var(--shake-level)), 0px); }
100% { transform: translate(0px, 0px); }
}
2020-08-07 01:05:59 +00:00
.shake {
animation: shake 0.75s;
animation-iteration-count: 1;
2020-08-07 01:05:59 +00:00
}
dl.questionOptions {
display: table;
}
dl.questionOptions > div {
display: table-row;
}
dl.questionOptions dt {
font-weight: 400;
display: table-cell;
}
dl.questionOptions dd {
display: table-cell;
}