:root {
    --words-gap: 0.4rem;
    --words-width: 32rem;
    --category-0-color: rgb(249, 223, 109);
    --category-1-color: rgb(160, 195, 90);
    --category-2-color: rgb(176, 196, 239);
    --category-3-color: rgb(186, 129, 197);
    /* --category-0-color: linear-gradient(rgb(249, 223, 109), rgb(160, 195, 90));
  --category-1-color: linear-gradient(rgb(160, 195, 90), rgb(176, 196, 239));
  --category-2-color: linear-gradient(rgb(176, 196, 239), rgb(186, 129, 197));
  --category-3-color: linear-gradient(rgb(186, 129, 197), rgb(186, 129, 197)); */
    --header-font-size: 1.6rem;
}

html,
body {
    width: 100%;
    height: 100dvh;
    display: flex;
    flex-direction: column;
    background-color: whitesmoke;
    box-sizing: border-box;
    overflow-y: auto;
    transition: background-color 1s ease;
}

.body.dictionary {
    overflow-y: auto;
}

.body.dictionary .main {
    padding: 0.5rem;
}

a {
    text-decoration: none;
    color: inherit;
}

button {
    border: none;
    outline: none;
    background-color: inherit;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
}

.main {
    width: 100%;
    flex: 1;
    padding: 2.5rem 1rem;
}

.section {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.section.dictionary {
    font-family: "Ahn Sangsoo", sans-serif;
    font-weight: 700;
    font-size: 4rem;
    width: 100%;
    height: auto;
    display: block;
}

.section.stats {
    height: auto;
}

.container {
    display: flex;
    width: var(--words-width);
    max-width: 100%;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.container.nav {
    width: var(--words-width);
    margin-bottom: 0.75rem;
    position: relative;
}

.container.disclaimer {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: var(--words-width);
    gap: 0.3rem;
    margin-top: 3rem;
}

.container.title h1 {
    font-family: "Ahn Sangsoo", sans-serif;
    font-size: 2rem;
    font-weight: 700;
}

.words {
    /* display: flex;
  flex-wrap: wrap;
  width: var(--words-width);
  gap: var(--words-gap); */
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    /* gap: var(--words-gap); */
    width: 100%;
    margin-bottom: 1rem;
    font-family: "Ahn Sangsoo", sans-serif;
    font-weight: 700;
    font-size: 1.6rem;
}

.words li {
    display: flex;
    justify-content: center;
    align-items: center;
    /* width: calc((var(--words-width) - var(--words-gap) * 3) / 4); */
    aspect-ratio: 1/1;
    list-style: none;
    cursor: pointer;
    background-color: gainsboro;
    color: black;
    user-select: none;
    -webkit-user-select: none;
}

li.correct {
    /* background-color: lightgreen; */
    pointer-events: none;
}

li.active {
    background-color: black;
    color: white;
}

.buttons {
    display: flex;
    width: 100%;
    gap: 0.5rem;
}

#submit {
    flex: 1;
    height: 50px;
    outline: none;
    border: none;
    border-radius: 6rem;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: black;
    color: white;
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: normal;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    white-space: pre-line;
    text-align: center;
}

#submit:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* #submit:not(:disabled):hover {
    opacity: 0.75;
} */

.answer-block {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    aspect-ratio: 4/1;
    grid-column: span 4;
    gap: 0.6rem;
}

.answer-block.category-0 {
    background: var(--category-0-color);
    color: black;
}

.answer-block.category-1 {
    background: var(--category-1-color);
    color: black;
}

.answer-block.category-2 {
    background: var(--category-2-color);
    color: black;
}

.answer-block.category-3 {
    background: var(--category-3-color);
    color: black;
}

.category-name {
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-weight: 700;
    font-size: 1.2rem;
}

.category-words {
    font-family: "Ahn Sangsoo", sans-serif;
    font-weight: 700;
    font-size: 1.6rem;
}

.nav {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: "Pretendard Variable", Pretendard, sans-serif;
}

#prevDay,
#nextDay,
#title {
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-size: 1.2rem;
    font-weight: 700;
}

#title.clickable,
#prevDay,
#nextDay {
    cursor: pointer;
    position: relative;
    isolation: isolate;
}
/* 
#title.clickable::before,
#prevDay::before,
#nextDay::before {
    content: "";
    position: absolute;
    inset: -0.25rem -0.5rem;
    border-radius: 0.25rem;
    background-color: transparent;
    transition: background-color 0.2s ease;
    z-index: -1;
} */

/* #title.clickable:hover::before,
#prevDay:hover::before,
#nextDay:hover::before {
    background-color: rgba(0, 0, 0, 0.075);
} */

#title.clickable:hover,
#prevDay:hover:not(:disabled),
#nextDay:hover:not(:disabled) {
    opacity: 0.5;
}

#prevDay:disabled,
#nextDay:disabled {
    cursor: default;
}

/* 달력 모달 스타일 */
.calendar-modal {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    margin-top: 0.5rem;
}

.calendar-modal.hidden {
    display: none;
}

.calendar-container {
    background: white;
    border-radius: 0.75rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    padding: 0.75rem 0.5rem;
    min-width: 280px;
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-weight: 700;
    font-size: 1rem;
    user-select: none;
    -webkit-user-select: none;
}

.calendar-nav-btn {
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    color: black;
    touch-action: manipulation;
    align-items: center;
    font-size: 0.75rem;
    transition: background-color 0.2s ease;
    user-select: none;
    -webkit-user-select: none;
}

/* .calendar-nav-btn:hover {
    background-color: rgba(0, 0, 0, 0.075);
} */

.calendar-nav-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-size: 0.75rem;
    font-weight: 600;
    color: gray;
    margin-bottom: 0.25rem;
    user-select: none;
    -webkit-user-select: none;
}

.calendar-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    /* gap: 0.25rem; */
}

.calendar-day {
    aspect-ratio: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: 50%;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
}

.calendar-day:hover:not(.disabled):not(.empty) {
    background-color: rgba(0, 0, 0, 0.1);
}

.calendar-day.today {
    background-color: black;
    color: white;
}

.calendar-day.available.selected {
    background-color: black;
    color: white;
}

.calendar-day.available:hover {
    color: black;
}

.calendar-day.available {
    color: black;
}

.calendar-day.disabled {
    color: #ccc;
    cursor: not-allowed;
}

.calendar-day.empty {
    cursor: default;
}

/* 결과 팝업 스타일 */
.result-modal {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
}

.result-modal.hidden {
    display: none;
}

.result-overlay {
    position: absolute;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.result-container {
    position: relative;
    background: white;
    /* border-radius: 1rem; */
    padding: 2.5rem 1.25rem 1.5rem 1.25rem;
    min-width: 300px;
    max-width: 90vw;
    max-height: 90vh;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.25rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    animation: popIn 0.3s ease;
}

@keyframes popIn {
    0% {
        transform: scale(0.9);
        opacity: 0;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.result-close {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    width: 1rem;
    height: 1rem;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.25rem;
    color: black;
}

.result-title {
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-size: 1rem;
    font-weight: 700;
    text-align: center;
}

.result-emoji {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.result-emoji-row {
    display: flex;
}

.result-color-box {
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 0.25rem;
}

.result-color-box.category-0 {
    background-color: var(--category-0-color);
}

.result-color-box.category-1 {
    background-color: var(--category-1-color);
}

.result-color-box.category-2 {
    background-color: var(--category-2-color);
}

.result-color-box.category-3 {
    background-color: var(--category-3-color);
}

.result-share {
    width: 75%;
    height: 50px;
    flex-shrink: 0;
    background-color: black;
    color: white;
    border-radius: 6rem;
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-size: 0.9rem;
    font-weight: 700;
}

.result-share:hover {
    opacity: 0.75;
}

.result-copied {
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-size: 0.875rem;
    color: gray;
    margin-top: -0.5rem;
}

.result-copied.hidden {
    display: none;
}

#prevDay:enabled,
#nextDay:enabled {
    color: black;
}

.additional-buttons.button {
    height: 50px;
    aspect-ratio: 1/1;
    outline: none;
    border: 2px solid black;
    border-radius: 6rem;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: transparent;
    color: black;
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-size: 1.125rem;
    font-weight: 700;
    cursor: pointer;
}

.additional-buttons.button:hover {
    background-color: black;
    color: white;
}

.pop-animation {
    animation: popText 0.4s ease-in-out;
}

.typewriter-text {
    opacity: 1;
    transition: opacity 0.3s ease;
    white-space: nowrap;
}

.disabled {
    pointer-events: none;
}

.disclaimer {
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-size: 1rem;
    font-weight: 400;
    color: silver;
    text-align: center;
}

.disclaimer .ahn {
    font-family: "Ahn Sangsoo", sans-serif;
    font-weight: 700;
}

.disclaimer .karnak {
    font-family: "NYTKarnakCondensed", sans-serif;
}

/* Create 페이지 스타일 */
.body.create {
    overflow-y: auto;
}

/* .main.create {
    padding: 2rem 1rem;
} */

.section.create {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.section.create .container.game {
    gap: 0.75rem;
}

.title-field {
    flex: 1;
    margin-right: 0.5rem;
}

.title-field input {
    width: 100%;
    background-color: transparent;
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-size: 1rem;
    font-weight: 700;
    padding: 0.75rem 1rem;
    border: 1px solid gainsboro;
    outline: none;
    text-align: center;
}

.title-field input:focus {
    border-color: black;
}

/* 탭 스타일 */
.create-tabs {
    display: flex;
}

.tab-btn {
    flex: 1;
    padding: 0.75rem 1rem;
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-size: 0.875rem;
    font-weight: 600;
    border: 1px solid gainsboro;
    background-color: transparent;
    color: gray;
    cursor: pointer;
}

.tab-btn.active {
    background-color: black;
    color: white;
    border-color: black;
}

.tab-btn:not(.active):hover {
    border-color: black;
    color: black;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* 문제 모드: 16칸 그리드 */
.create-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2px;
}

.grid-input {
    aspect-ratio: 1;
    width: 100%;
    font-family: "Ahn Sangsoo", sans-serif;
    font-size: 1.4rem;
    font-weight: 700;
    text-align: center;
    border: none;
    outline: none;
    background-color: gainsboro;
}

.grid-input:focus {
    background-color: black;
    color: white;
}

/* 정답 모드 */
#answersTab.active {
    width: 100%;
    display: flex;
    flex-direction: column;
}

.answer-row {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem;
    aspect-ratio: 4/1;
}

.answer-row.category-0 {
    background-color: var(--category-0-color);
}

.answer-row.category-1 {
    background-color: var(--category-1-color);
}

.answer-row.category-2 {
    background-color: var(--category-2-color);
}

.answer-row.category-3 {
    background-color: var(--category-3-color);
}

.category-input {
    width: 100%;
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-size: 1rem;
    font-weight: 700;
    padding: 0.5rem 0.75rem;
    border: none;
    outline: none;
    background-color: rgba(255, 255, 255, 0.5);
    text-align: center;
}

.category-input:focus {
    background-color: rgba(255, 255, 255, 0.8);
}

.category-input::placeholder {
    color: rgba(0, 0, 0, 0.3);
}

.word-selects {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.25rem;
}

.word-select {
    font-family: "Ahn Sangsoo", sans-serif;
    font-size: 0.875rem;
    font-weight: 700;
    padding: 0.5rem 0.25rem;
    border: none;
    outline: none;
    background-color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    text-align: center;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

.word-select:focus {
    background-color: rgba(255, 255, 255, 0.8);
}

.word-select.selected {
    background-color: rgba(0, 0, 0, 0.1);
}

/* 에러 메시지 */
.error-message {
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-size: 0.875rem;
    color: red;
    text-align: center;
}

.error-message.hidden {
    display: none;
}

.create-submit {
    width: 100%;
    height: 50px;
    background-color: black;
    color: white;
    border: none;
    border-radius: 6rem;
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
}

.create-submit:hover {
    opacity: 0.75;
}

.create-submit:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.link-result {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem;
    background-color: white;
    border: 1px solid gainsboro;
}

.link-result.hidden {
    display: none;
}

.link-label {
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-size: 1rem;
    font-weight: 700;
}

.link-box {
    display: flex;
    width: 100%;
    gap: 0.5rem;
}

.link-box input {
    flex: 1;
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-size: 0.875rem;
    padding: 0.75rem 1rem;
    border: 1px solid gainsboro;
    background-color: whitesmoke;
    outline: none;
}

.copy-link-btn {
    padding: 0.75rem 1.25rem;
    background-color: black;
    color: white;
    border: none;
    border-radius: 6rem;
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-size: 0.875rem;
    font-weight: 700;
    cursor: pointer;
    flex-shrink: 0;
}

.copy-link-btn:hover {
    opacity: 0.75;
}

.link-copied {
    font-family: "Pretendard Variable", Pretendard, sans-serif;
    font-size: 0.875rem;
    color: gray;
}

.link-copied.hidden {
    display: none;
}

@media screen and (max-width: 600px) {
    .grid-input {
        font-size: 1.2rem;
    }
    
    .word-select {
        font-size: 0.75rem;
    }
}

/* 햄버거 메뉴 */
/*
.menu {
    position: fixed;
    bottom: 3rem;
    right: 1rem;
    display: flex;
    flex-direction: row;
    align-items: center;
    z-index: 1000;
    gap: 0.875rem;
}

.menu-button {
    width: 50px;
    height: 50px;
    background-color: black;
    color: white;
    border: none;
    border-radius: 50%;
    font-family: "Ahn Sangsoo", sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    cursor: pointer;
    touch-action: manipulation;
    animation: rotate 10s linear infinite;
}

.menu-items {
    display: flex;
    gap: 0.875rem;
    background-color: black;
    padding: 0.75rem 1rem;
    border-radius: 20px;
    opacity: 1;
    transform: translateX(0);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.menu-items.hidden {
    opacity: 0;
    transform: translateX(10px);
    pointer-events: none;
}

.menu-item {
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 0.875rem;
    font-weight: 700;
    text-decoration: none;
    touch-action: manipulation;
    white-space: nowrap;
    opacity: 1;
    transform: translateX(0);
}

.menu-item:hover {
    opacity: 0.75;
}

@media screen and (max-width: 600px) {
    .menu {
        bottom: 2.75rem;
        right: 0.5rem;
    }

    .menu-button {
        width: 40px;
        height: 40px;
        font-size: 1.25rem;
    }

    .menu-items {
        padding: 0.5rem 0.875rem;
    }

    .menu-item {
        font-size: 0.75rem;
    }
}

@keyframes rotate {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
} */

/* 테스트: dialog 메뉴 */
/* 풀스크린 메뉴 */
.fullscreen-menu-button {
    position: fixed;
    bottom: 3rem;
    right: 1rem;
    width: 50px;
    height: 50px;
    background-color: black;
    color: white;
    border: none;
    border-radius: 50%;
    font-family: "Ahn Sangsoo", sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    cursor: pointer;
    touch-action: manipulation;
    z-index: 1000;
}

.fullscreen-menu {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
}

.fullscreen-menu.hidden {
    display: none;
}

.fullscreen-menu-overlay {
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(10px);
}

.fullscreen-menu-content {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4rem;
}

.fullscreen-menu-item {
    font-family: "Ahn Sangsoo", sans-serif;
    font-size: 2.5rem;
    font-weight: 700;
    color: black;
    text-decoration: none;
    touch-action: manipulation;
}

.fullscreen-menu-item:hover {
    opacity: 0.5;
}

@media screen and (max-width: 600px) {
    .fullscreen-menu-button {
        bottom: 2.75rem;
        right: 0.5rem;
        width: 40px;
        height: 40px;
        font-size: 1.25rem;
    }

    .fullscreen-menu-content {
        gap: 3rem;
    }

    .fullscreen-menu-item {
        font-size: 2rem;
    }
}

/* 사전 */
.dictionary-container {
    /* display: flex;
  flex-wrap: wrap;
  gap: 0.5rem; */
    line-height: 1.5;
}

.dictionary-container span {
    color: silver;
    user-select: none;
    -webkit-user-select: none;
    margin-right: 0.125rem;
}

.dictionary-container span::after {
    content: ".";
    margin-left: 0.25rem;
}

.dictionary-container span:hover {
    color: black;
    cursor: pointer;
}

.dictionary-container span.active {
    color: black;
}

.footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex: 0 0 auto;
    padding: .5rem 1rem;
    font-size: .75rem;
    text-align: right;
    background-color: white;
    border-top: 1px solid gainsboro;
}

.footer a {
    opacity: .5;
}

.footer a:hover {
    opacity: 1;
}

.footer div:last-child a {
    font-family: 'Pretendard Variable', Pretendard, sans-serif;
}

.logo {
    display: inline-flex;
    align-items: center;
    position: relative;
    font-family: Logo;
    font-size: 1rem;
}

.logo span:last-child {
    display: none;
}

.three-stars {
    font-family: 'Pretendard Variable', Pretendard, sans-serif;
    font-weight: 700;
    font-size: 1.5rem;
    padding: 1.5rem;
}

.stats-container {
    font-family: 'Pretendard Variable', Pretendard, sans-serif;
    font-weight: 700;
    font-size: 1rem;
    text-align: center;
    line-height: 1.7;
    padding-bottom: 1rem;
}


@media screen and (max-width: 899px) {
    .logo span:first-child {
        display: none;
    }
    .logo span:last-child {
        display: inline-block;
    }
}

@keyframes popText {
    0% {
        transform: scale(0.9);
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
    }
}

@media screen and (max-height: 900px) {
     /* :root {
        --words-width: 50dvh;
    } */
    .main {
        padding: 2.5rem 0.75rem;
    }
    .words {
        font-size: 1.4rem;
    }
    #submit {
        font-size: 0.9rem;
    }
    
    .category-name {
        font-size: 0.9rem;
    }
    .category-words {
        font-size: 1.2rem;
    }
    #prevDay,
    #title,
    #nextDay {
        font-size: 1rem;
    }
    .container.nav {
        margin-bottom: 0.75rem;
    }
    .container.disclaimer {
        margin-top: 1rem;
        gap: 0.1rem;
    }
    .disclaimer {
        font-size: 0.7rem;
    }
}

@media screen and (max-width: 600px) {
     :root {
        --words-width: 100%;
    }
    .words {
        font-size: 1.4rem;
    }
    #submit {
        font-size: 0.9rem;
    }
    .answer-block {
        height: auto;
        aspect-ratio: 4/1;
        gap: 0.3rem;
    }
    .category-name {
        font-size: 0.9rem;
    }
    .category-words {
        font-size: 1.2rem;
    }
    .section.dictionary {
        font-size: 2rem;
    }
    #prevDay,
    #title,
    #nextDay {
        font-size: 0.9rem;
    }
    .container.nav {
        margin-bottom: 0.75rem;
    }
    .container.disclaimer {
        margin-top: 1rem;
        gap: 0.1rem;
    }
    .disclaimer {
        font-size: 0.7rem;
    }
    .three-stars {
        font-size: 1rem;
    }
    .stats-container {
        font-size: .75rem;
    }
    .calendar-container {
        min-width: 260px;
        padding: 0.75rem;
    }
    .calendar-header {
        font-size: 0.9rem;
    }
    .calendar-day {
        font-size: 0.8rem;
    }
    #title.clickable::after {
        font-size: 0.5rem;
    }

    .result-container {
        min-width: 80%;
        max-width: 80%;
    }
}

@media screen and (max-width: 450px) and (max-height: 450px) {
     :root {
        --words-width: 70%;
    }
    .words {
        font-size: 0.9rem;
        margin-bottom: 0.5rem;
    }
    .container.nav {
        margin-bottom: 0.4rem;
    }
    .category-name {
        font-size: 0.6rem;
    }
    .category-words {
        font-size: 0.8rem;
    }
    #prevDay,
    #title,
    #nextDay {
        font-size: 0.5rem;
    }
    #submit,
    .additional-buttons.button {
        font-size: 0.5rem;
        height: 30px;
        margin-bottom: 0.3rem;
    }
    .container.disclaimer {
        margin: 0.2rem;
    }
    .disclaimer {
        font-size: 0.4rem;
    }
    .footer {
        display: none;
    }
    .calendar-container {
        min-width: 200px;
        padding: 0.5rem;
    }
    .calendar-header {
        font-size: 0.6rem;
        margin-bottom: 0.5rem;
    }
    .calendar-nav-btn {
        width: 1.5rem;
        height: 1.5rem;
        font-size: 0.5rem;
    }
    .calendar-weekdays {
        font-size: 0.5rem;
    }
    .calendar-day {
        font-size: 0.6rem;
    }
    #title.clickable::after {
        font-size: 0.35rem;
        margin-left: 0.2rem;
    }
}

/* 커스텀 게임 UI */
.custom-game .nav {
    justify-content: center;
}

.custom-game .additional-buttons.button {
    display: none;
}

.custom-game #submit {
    flex: none;
    width: 100%;
}