/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html,
body {
    height: 100%;
    overflow: hidden;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: #000;
    color: #fff;
    touch-action: manipulation;
}

body {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
    min-height: 100vh;
}

/* Text display area */
#text-display {
    text-align: center;
    transition: font-size 0.15s ease-in-out;
    outline: none;
    min-height: 0px;
}

/* Hidden textarea for input */
#text-input {
    position: absolute;
    opacity: 0;
    height: 0;
    width: 0;
    overflow: hidden;
}

#github-btn {
    position: fixed;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    background-color: #4b4b4b;
    color: white;
    border-radius: 4px;
    border: none;
    cursor: pointer;
    bottom: 20px;
    left: 20px;
    z-index: 10;
    text-decoration: none;
}

#fullscreen-btn {
    position: fixed;
    width: 20px;
    height: 20px;
    background-color: #4b4b4b;
    color: white;
    border-radius: 4px;
    padding: 2px;
    border: none;
    cursor: pointer;
    top: 20px;
    right: 20px;
    z-index: 10;
    line-height: 1;
    font-weight: bold;
}

:fullscreen #fullscreen-btn,
:-webkit-full-screen #fullscreen-btn,
:-moz-full-screen #fullscreen-btn,
:-ms-fullscreen #fullscreen-btn,
:fullscreen #github-btn,
:-webkit-full-screen #github-btn,
:-moz-full-screen #github-btn,
:-ms-fullscreen #github-btn {
    display: none;
}

.text {
    font-style: normal;
    white-space: pre;
    word-break: keep-all;
    overflow-wrap: normal;
    width: min-content;
    height: min-content;
    line-height: 1;
}

.place {
    opacity: 0.5;
    font-style: italic;
}