@font-face {
    font-display: swap;
    font-family: "Good Dog";
    src: url("/assets/fonts/gooddog.otf");
}
@font-face {
    font-display: swap;
    font-family: "Good Dog Cool";
    src: url("/assets/fonts/gooddogcool.otf");
}
@font-face {
    font-display: swap;
    font-family: "Good Dog Bones";
    src: url("/assets/fonts/gooddogbones.otf");
}
@font-face {
    font-display: swap;
    font-family: "Good Dog New";
    src: url("/assets/fonts/gooddognew.ttf");
}

body {
    font-family: var(--sitefont, "Good Dog");
    position: relative; z-index: 1;
    display: flex; justify-content: center;
    min-height: 100vh; min-width: 100vw;
    overflow-y: visible !important; overflow-x: hidden !important;
    user-select: none; padding: 0; margin: 0;
    -webkit-user-drag: none;

    background-color: #e9a856;
    --bg: url("/assets/images/bgs/original.avif");
    background-image: var(--bg), url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' style='background:%239a2' viewBox='0 0 2048 1154'%3E%3Cpath fill='%23d94' d='M0-4h2048v500c-25 2-41-10-66-8q-42-1-83 4c-18-1-42-7-63-10-21-13-47-2-71-16-28 8-56 2-84-5-26-7-62 1-90-7-28 5-52-14-80-7-24-1-40 11-64 4-41 7-83 4-125 12-26 10-54 9-81 5-24 9-51 5-75 16-27 3-56 15-82 4-36 1-74-2-108 7-36 8-75 7-111 17-24 9-48 9-72 8q-57 1-116 6c-33 9-71 7-108 8-22 14-43-2-66-2q-48 5-93-6c-23-3-54-4-81-6-30-4-59 6-89-4-36-7-71-19-109-17-23-3-44-12-68-11-20-6-69 16-63-16z'/%3E%3Cpath fill='%2356a' d='M538 786q38-5 64 18c29 9 53 20 84 23 50 5 92 23 140 30q80 21 159 34c60 21 126 20 186 42q60 8 119 23c39 12 82 5 121 20 42 15 87 24 132 13 44-10 88-26 134-26 31-1 56-15 88-18 39-8 75-11 113-25 56-10 114-19 176-29v271l-572 1-1476-1V914c65-8 128-30 192-41 42-15 90-16 135-30q43-18 88-29'/%3E%3Cpath fill='%23fff' d='M540 783c23-1 44-1 60 16 31 10 56 21 88 25 49 4 90 24 139 29q79 22 160 35c60 21 126 20 185 42q60 9 120 23c39 12 81 5 120 20 42 15 88 24 132 13 44-10 88-26 135-26 30-1 56-15 87-18 38-9 73-9 109-24 57-11 115-17 169-36 14 16-35 17-49 24q-68 3-132 24c-22 6-44 7-63 14-36 14-78 9-115 21-26-1-45 20-70 20-24 4-50 3-72 14l-57 1c-28 4-51-13-80-17-20-5-40 4-57-12-49-18-104-12-152-30-21-6-49-7-72-16-38-16-80-14-120-20-40-14-82-18-122-32-41 1-78-20-120-20-27-11-58-9-83-20-27-4-51-24-79-29-27-8-59-20-89-5-57 8-103 45-161 46-38 13-80 10-117 26-32 0-62 14-94 18-42 11-85 22-129 23-26 4 39-12 34-10 35-5 67-20 103-21q92-23 183-43c43-15 98-12 142-35 23-6 44-16 67-20'/%3E%3Cpath fill='%23fff' d='M1481 445c70-5 138 15 208 14 68 6 137 10 203 25 40-4 79 6 119 6 22 2 57 11 14 8-30-11-68-4-102-6-20 7-40 3-62-2-21-1-40-13-59-12-22 2-41-15-62-4-37-1-66-15-103-13-26 2-49-5-75-3-24-15-54-7-81-5-17 8-44-1-66 4-35 7-74 1-109 14-22 7-44 2-65 1-24 9-51 4-75 16-27 3-56 14-82 4-36 1-74-3-108 7-34 7-69 6-103 15-25 6-50 15-76 8l-101 6c-23 1-44 9-67 9-30 1-60-3-88 8-36-18-79-1-115-13-26-5-56-4-84-8q-42-2-82 0c-43-7-85-23-129-21-21-3-41-12-63-11-21-5-61 10-68-8l91 5q161 26 325 35l134 9q32-12 64-6c92-2 183-18 275-23 41-7 85-9 123-16 37 0 73-5 110-5 111-35 229-20 343-37z'/%3E%3C/svg%3E");
    background-position: center center;
    background-repeat: no-repeat; background-size: cover;
    background-attachment: fixed;

    cursor: url("/assets/images/cursors/idle.cur"), default !important;
}
body:active, body:focus, body:focus-within, body:target, body:active * {
    cursor: url("/assets/images/cursors/active.cur"), default !important;
}
:any-link {
    color: #8feeff; text-decoration: none !important;
    cursor: url("/assets/images/cursors/link.cur"), default !important;
}
* {
    cursor: inherit !important;
    scrollbar-width: none; scrollbar-color: #ffffff #ffffff;
}
*::-webkit-scrollbar {width: 0px}

p {margin: 0}

/*//////////////////////////////////////////////////////////////////////*/

.page {
    display: flex; flex-direction: column;
    align-items: center;
    width: min(100vw, 700px); min-height: 90vh;
    color: white; font-size: 1em;
    -webkit-text-stroke: 0.175em black;
    text-shadow: 0 0.15em 0 black;
    paint-order: stroke fill;
}

.title {
    font-size: 2em;
    -webkit-text-stroke: 0.15em black;
    text-shadow: 0 0.15em 0 black;
    paint-order: stroke fill;
}

.tiny {
    position: fixed; bottom: 0.3em; width: 90%;
    text-align: center;
    color: rgb(223, 223, 223); font-size: 0.5em;
    -webkit-text-stroke: 0.175em black;
    text-shadow: 0 0.15em 0 black;
    paint-order: stroke fill;
}

/*//////////////////////////////////////////////////////////////////////*/

.sbutton {
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    cursor: pointer; background: none;
    border: none; padding: 0;
    position: relative;
}
.sbutton img {height: 4em}

.sbutton span {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    color: #fff; font-size: 1.5em;
    -webkit-text-stroke: 0.15em black;
    text-shadow: 0 0.15em 0 black;
    paint-order: stroke fill;
    pointer-events: none;
    white-space: nowrap; user-select: none;
}

/*//////////////////////////////////////////////////////////////////////*/

.container {
    display: flex; flex-direction: column;
    width: 100%; height: 100vh;
    padding: 0; overflow: visible;
}

.previewsection {
    display: flex; flex-direction: column;
    justify-content: center; align-items: center;
    height: 100vh; position: relative;
    overflow: visible;
}

.textdisplay {
    position: relative; display: flex; 
    justify-content: center; align-items: center;
    width: 100%; height: 100%;
    padding: 4em 4em 8em 4em; box-sizing: border-box; overflow: visible;
}

.textdisplay > .buttonbackground {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    z-index: 0;
    pointer-events: none;
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
}

.textdisplay > .textshadow,
.textdisplay > .textpreview {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
}

.textpreview {
    text-align: center;
    white-space: pre;
    overflow: visible;
    line-height: 1.2;
    z-index: 2;
}

.textshadow {
    text-align: center;
    white-space: pre;
    overflow: visible;
    line-height: 1.2;
    z-index: 1;
    pointer-events: none;
}

.textinput {
    position: absolute;
    top: 50%; left: 50%; transform: translate(-50%, -50%);
    width: 90vw; min-width: 200px; max-width: 950px; height: 90vh;
    background: transparent; border: none;
    outline: none; box-shadow: none;
    color: transparent; caret-color: transparent;
    font-family: inherit; font-size: inherit; text-align: center;
    resize: none; overflow: hidden;
    z-index: 10; padding: 0; margin: 0;
    letter-spacing: inherit; opacity: 0;
}
.textinput::placeholder {
    opacity: 0;
    color: transparent;
}
.textinput:focus {
    outline: none;
    border: none;
    box-shadow: none;
}

.cursoroverlay {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    z-index: 3;
}
.cursoroverlay .cursorline {
    position: absolute;
    width: 2px;
    background-color: white;
    animation: blink 1s infinite;
    pointer-events: none;
}
.selectionoverlay {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    z-index: 2.5;
}

.selectionoverlay .selectionbox {
    position: absolute;
    background-color: rgba(255, 255, 255, 0.3);
    pointer-events: none;
}

@keyframes blink {
    0%, 50% {opacity: 1}
    51%, 100% {opacity: 0}
}

/*//////////////////////////////////////////////////////////////////////*/

.configs {
    display: flex; flex-direction: column;
    padding: 1em; border-radius: 16px; 
    background: rgba(0,0,0,0.5);
    overflow-y: auto; position: fixed;
    left: 1em; bottom: 1em;
    width: max-content; min-width: fit-content;
    z-index: 10000; pointer-events: auto;
}
.configs .draghandle {
    position: absolute;
    top: -12px; left: -12px;
    width: 34px; height: 34px;
    background: rgba(0,0,0,0.3);
    border-radius: 50%; cursor: move; z-index: 1000;
}
.configs .draghandle:hover {
    background: rgba(0,0,0,0.75);
}

@media (max-width: 700px) {
    .configs {
        left: auto; right: auto;
        bottom: 0; width: 100%; max-width: 100%;
        border-radius: 0; font-size: 0.75em;
    }
    .configs .draghandle {display: none}
    .fontbutton, .preset {width: 6em; font-size: 1em;}
    .fontbutton img, .preset img {width: 6em}
}

.configlines {
    display: flex; flex-direction: column;
    gap: 0.5em; flex: 1;
}

.configline {
    display: flex;
    gap: 0.5em;
    justify-content: center;
    flex-wrap: wrap;
}

/*//////////////////////////////////////////////////////////////////////*/

.preset[data-preset="default"] span {
    -webkit-text-stroke: 0.15em #000000cc;
    text-shadow: 0 0.15em 0 #2b0f00cc;
}
.preset[data-preset="plain"] span {
    color: black;
    -webkit-text-stroke: 0;
    text-shadow: none;
}
.preset[data-preset="cyan"] span {
    color: #9faef1ff;
    -webkit-text-stroke: 0;
    text-shadow: none;
}

/*//////////////////////////////////////////////////////////////////////*/

.fontbutton, .preset {
    position: relative; display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    background: none; border: none;
    padding: 0;
}
.fontbutton img, .preset img {
    height: 3em;
}
.fontbutton span, .preset span {
    position: absolute;
    top: 50%; left: 50%; transform: translate(-50%, -50%);
    color: #fff; font-size: 1.5em; font-family: var(--sitefont, "Good Dog");
    -webkit-text-stroke: 0.15em black;
    text-shadow: 0 0.15em 0 black;
    paint-order: stroke fill;
    pointer-events: none; white-space: nowrap; user-select: none;
}
.fontbutton[data-font="Good Dog"] span {
    font-family: var(--sitefont, "Good Dog");
}
.fontbutton[data-font="Good Dog Cool"] span {
    font-family: "Good Dog Cool";
}
.fontbutton[data-font="Good Dog Bones"] span {
    font-family: "Good Dog Bones";
}
.fontbutton[data-font="Good Dog New"] span {
    font-family: "Good Dog New";
}

/*//////////////////////////////////////////////////////////////////////*/

.numberline {
    display: flex;
    gap: 0.5em;
    justify-content: center;
    flex-wrap: wrap;
}

.colorline {
    display: flex;
    gap: 0em;
    justify-content: center;
    flex-wrap: wrap;
}

.settinggroup {
    display: flex; flex-direction: column;
    gap: 0.2em; max-width: 100px !important
}
.colorline .settinggroup {
    width: max-content;
}

.settinglabel {
    color: white;
    font-size: 1.2em;
    -webkit-text-stroke: 0.15em black;
    text-shadow: 0 0.15em 0 black;
    paint-order: stroke fill;
}

.settinginput {
    padding: 0.4em 0.5em;
    background: rgba(0,0,0,0.5);
    border: none; border-radius: 1em;
    color: white;
    font-family: var(--sitefont, "Good Dog");
    font-size: 0.9em;
    width: 60px;
}
.settinginput.numberinput {
    width: 20px;
}
.settinginput.numberinput::-webkit-inner-spin-button,
.settinginput.numberinput::-webkit-outer-spin-button {
    -webkit-appearance: none;
    appearance: none;
    margin: 0;
}
.settinginput.numberinput {
    appearance: textfield;
    -moz-appearance: textfield;
}
.settinginput:focus {
    outline: none;
    background: rgba(0,0,0,0.5);
}
.settinginput.colorinput {
    width: 60px;
    padding: 0.4em 0.3em 0.4em 32px;
}

.combinedgroup {
    display: flex;
    gap: 0.3em;
    align-items: flex-end;
}
.combinedgroup .settinggroup {
    flex: 1;
}

/*//////////////////////////////////////////////////////////////////////*/

.colorgroup {
    display: flex;
    align-items: center;
    position: relative;
    width: max-content;
}
.settinginput.colorpicker {
    position: absolute;
    left: 5px; width: 22px; height: 22px;
    padding: 0; border-radius: 50%;
    cursor: pointer; -webkit-appearance: none;
    appearance: none; border: none;
    overflow: hidden;
}
.settinginput.colorpicker::-webkit-color-swatch-wrapper {
    padding: 0; border: none;
    border-radius: 50%; overflow: hidden;
}
.settinginput.colorpicker::-webkit-color-swatch {
    border: none; border-radius: 50%;
    padding: 0;
}
.settinginput.colorpicker::-moz-color-swatch {
    border: none;
    border-radius: 50%;
}

.settinginput[type="range"] {
    -webkit-appearance: none; appearance: none;
    height: 6px; width: 100%;
    background: rgba(0,0,0,0.5);
    border-radius: 3px;
    outline: none
}
.settinginput[type="range"]::-webkit-slider-runnable-track {
    width: 100%;
    height: 6px;
    background: rgba(0,0,0,0.5);
    border-radius: 3px;
    border: none;
}
.settinginput[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none; appearance: none;
    width: 16px; height: 16px;
    background: white;
    border-radius: 50%;
    cursor: pointer;
    margin-top: -5px;
}
.settinginput[type="range"]::-moz-range-track {
    width: 100%; height: 6px;
    background: rgba(0,0,0,0.5);
    border-radius: 3px;
    border: none;
}
.settinginput[type="range"]::-moz-range-thumb {
    width: 16px; height: 16px;
    background: white;
    border-radius: 50%;
    cursor: pointer; border: none;
}
.opacitycontrol {
    display: flex; align-items: center;
    gap: 0.3em; margin-top: 0.2em;
    width: max-content;
}
.opacityslider {
    flex: 0.45; height: 4px;
    background: rgba(0,0,0,0.5);
    border-radius: 2px;
    outline: none; margin: 0;
    -webkit-appearance: none; appearance: none;
    max-width: 45%;
}
.opacityslider::-webkit-slider-runnable-track {
    width: 100%; height: 4px;
    background: rgba(0,0,0,0.5);
    border-radius: 2px;
    border: none;
}
.opacityslider::-webkit-slider-thumb {
    -webkit-appearance: none; appearance: none;
    width: 12px; height: 12px;
    background: white; border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 0 1px rgba(0,0,0,0.3);
    margin-top: -4px;
}
.opacityslider::-moz-range-track {
    width: 100%; height: 4px;
    background: rgba(0,0,0,0.5);
    border-radius: 2px;
    border: none;
}
.opacityslider::-moz-range-thumb {
    width: 12px; height: 12px;
    background: white;
    border-radius: 50%;
    cursor: pointer; border: none;
    box-shadow: 0 0 0 1px rgba(0,0,0,0.3);
}
.opacityvalue {
    width: 15px !important;
    padding: 0.2em 0.1em !important;
    font-size: 0.8em !important;
}

/*//////////////////////////////////////////////////////////////////////*/

.downloadsection {
    position: absolute; text-align: right;
    top: 1em; right: 1em; gap: 0.5em; z-index: 10;
    display: flex; flex-direction: row; align-items: center;
}
.downloadsection .settinggroup {
    align-items: center;
    flex-direction: row;
    gap: 0.3em;
}
.downloadsection .downloadbutton span {
    font-size: 2em;
}

.downloadsection .settinglabel {font-size: 0.95em; line-height: 0.8}
.downloadsection .settinginput {width: 40px}

/*//////////////////////////////////////////////////////////////////////*/

.checkboxline {
    display: flex;
    gap: 0.5em;
    justify-content: center;
    flex-wrap: wrap;
    align-items: center;
}
.checkboxgroup {
    display: flex;
    align-items: center; gap: 0.3em;
}
.checkboxlabel {
    color: white;
    font-size: 1.2em;
    -webkit-text-stroke: 0.15em black;
    text-shadow: 0 0.15em 0 black;
    paint-order: stroke fill;
}
.checkboxinput {
    width: 32px; height: 32px;
    appearance: none; -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("/assets/images/buttons/unchecked.png");
    background-size: contain; background-repeat: no-repeat;
    background-position: center;
    cursor: pointer; border: none;
    padding: 0; margin: 0;
}
.checkboxinput:checked {background-image: url("/assets/images/buttons/checked.png")}

/*//////////////////////////////////////////////////////////////////////*/

.textdisplay .textpreview, .textdisplay .textshadow {
    width: max-content; max-width: none;
}
.textdisplay .textinput {
    min-width: 0; max-width: none;
    width: auto; height: auto;
    line-height: 1.2; white-space: pre;
    padding: 0; margin: 0;
    box-sizing: content-box; opacity: 1;
    color: transparent; caret-color: #fff;
    -webkit-text-fill-color: transparent; -webkit-text-stroke: 0;
    text-shadow: none; scrollbar-width: none;
    user-select: text; -webkit-user-select: text;
}
.textdisplay .textinput::-webkit-scrollbar {display: none}
.textdisplay .textinput::selection {
    color: transparent; background: rgba(92,161,255,0.4);
    -webkit-text-fill-color: transparent;
}
.textdisplay .cursoroverlay, .textdisplay .selectionoverlay {display: none}
