@import url('https://itproger.com/css/main-font.css');

:root {
    --body-bg: #E8F9FF;
    --keyboard-bg: #F7FBFF;
    --key-bg: #FFFFFF;
    --key-border: #CBCBCB;
    --key-radius: 8px;
    --shadow-light: rgba(0, 0, 0, 0.1);
    --highlight-primary: #FDD835;
    --highlight-secondary: #64B5F6;
    --text-color: #333;
}
* { box-sizing: border-box; }
body {
    margin: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-top: 160px;
    background-color: var(--body-bg);
	
	font-family:Montserrat,sans-serif;
	font-weight:300;
	font-size:1rem;

	overflow-anchor:auto;
	scroll-behavior:smooth;
	font-size-adjust:100%;
	-webkit-font-size-adjust:100%;
	-ms-font-size-adjust:100%;
	-webkit-text-size-adjust:none;
	
    color: var(--text-color);
}
.sub_link:hover {text-decoration: none}
#back-btn {
    position: fixed;
    top: 16px;
    left: 16px;
    background: var(--highlight-secondary);
    color: #fff;
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 0.9rem;
    transition: opacity 0.2s;
}
#back-btn:hover { opacity: 0.8; }
#instruction {
    font-size: 1.2rem;
    margin-bottom: 16px;
}
#word-display { font-size: 2.5rem; margin-bottom: 16px; }
#timer { font-size: 1.2rem; margin-bottom: 24px; display: none; }
#message { font-size: 1.3rem; margin-top: 20px; }
#next-btn {
    margin-top: 16px;
    padding: 8px 16px;
    font-size: 1rem;
    cursor: pointer;
    border: none;
    border-radius: 4px;
    background: var(--highlight-primary);
    color: #fff;
    transition: opacity 0.2s;
}
#next-btn:hover { opacity: 0.8; }
.keyboard {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 16px;
    background: var(--keyboard-bg);
    border-radius: 16px;
    box-shadow: 0 8px 16px var(--shadow-light);
}
.row { display: flex; gap: 6px; }
.key {
    height: 50px;
    width: 50px;
    background: var(--key-bg);
    border: 1px solid var(--key-border);
    border-radius: var(--key-radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    user-select: none;
    transition: background 0.2s, transform 0.1s;
}
.key:active { transform: translateY(2px); }
.key.pressed {
    background: var(--highlight-primary);
    border-color: var(--highlight-primary);
    color: #fff;
}
.key.initial-system {
    background: var(--highlight-secondary);
    border-color: var(--highlight-secondary);
    color: #fff;
}
.key.wide { width: 80px; }
.key.extra-wide { width: 120px; }
.correct { color: green; }
.error { color: red; }