@import url("https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.9/dist/web/static/pretendard.min.css");
@import url('theme.css');

*::-webkit-scrollbar {
    width: 10px;
    height: 8px;
}

*::-webkit-scrollbar-corner, *::-webkit-scrollbar-track {
    background-color: transparent;
}

*::-webkit-scrollbar-thumb {
    background-color: #9e9e9e;
    border-radius: 10px;
    background-clip: padding-box;
    border: 1px solid transparent;
}

*::-webkit-scrollbar-thumb:hover {
    background-color: #717171;
}

*::-webkit-scrollbar-track {
    border-radius: 8px;
    border: 4px solid transparent;
    background-clip: content-box;
}

*::-webkit-scrollbar-corner, ::-webkit-scrollbar-track {
    background-color: transparent;
}

@media (hover: none) and (pointer: coarse), (max-width: 719px) {
    body::-webkit-scrollbar {
        width: 1px;
    }
    
    #main {
        width: calc(100% - 17px) !important;
        padding-right: 0 !important;
    }
}

div {
    -webkit-tap-highlight-color: transparent;
}

button {
    all: unset;
    display: flex;
    vertical-align: top;
}

button {
    user-select: none;
    transition: color 0.15s cubic-bezier(.4, 0, .2, 1), background-color 0.15s cubic-bezier(.4, 0, .2, 1);
}

button:focus-visible {
    outline: auto;
}

img {
    pointer-events: none;
}

html, body {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    overflow-y: auto;

    background-color: var(--canvas-color);

    font-family: Pretendard, sans-serif;
    font-size: 14px;
    font-weight: 400;
    line-height: 100%;
    color: var(--color);
}

html {
    font-size: 14px;
}

#main {
    width: calc(100% - 18px);
    min-height: 100dvh;
    padding: 0 9px 9px 9px;

    display: flex;
    flex-direction: column;
    align-items: center;
}

#title-box {
    max-width: 768px;
    width: 100%;
    background-color: hsl(var(--sonner));
    border: 1px solid var(--border-color);
    border-radius: calc(0.6rem - 2px);
    box-shadow: 0 0 #0000, 0 0 #0000, 0 1px 2px 0 rgba(0,0,0,.05);
    flex: 1 1 auto;
    box-sizing: border-box;
    margin-top: 9px;
    margin-bottom: 9px;
    padding: 10px 16px;
    min-height: 450px;
    position: relative;
    display: flex;
    flex-direction: column;
}

#bottom {
    width: 100%;
    height: 9px;
    flex-shrink: 0;
}

#navigation-bar {
    width: 100%;
    height: 24px;
    display: flex;
    margin-bottom: 6px;
    gap: 20px;
    box-sizing: border-box;
    position: relative;
    flex-shrink: 0;
}

#horizontal-line {
    width: 100%;
    height: 1px;
    margin-bottom: 2px;

    background-color: hsl(var(--border));
    flex-shrink: 0;
}

.select {
    height: 100%;
    padding: 12px 0 12px 0;

    display: flex;
    align-items: center;
    position: relative;

    color: var(--navigation-color);
    font-size: 16px;
    font-weight: 600;

    text-decoration: none;
    box-sizing: border-box;
    
    cursor: pointer;
}

.select[data-view="selected"] {
    font-weight: 700;
    color: var(--navigation-selected-color);
}

#catchphrase {
    width: 100%;
    flex: 1;

    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

#text {
    font-size: 1.875rem;
    line-height: 2.25rem;
    font-weight: 900;
    text-align: center;
    margin-bottom: 1.25rem;
}

#text span {
    background-image: linear-gradient(to right, #f436a6, #ff9e00);
    background-clip: text;
    color: transparent;
}

#search-box {
    width: 100%;
    max-width: 495px;
    padding-left: 1rem;
    padding-right: 1rem;
    position: relative;
    box-sizing: border-box;
}

#search-area {
    width: 100%;
    height: 40px;
    background-color: hsl(var(--input));
    border: 1px solid hsl(var(--border) / .5);
    border-radius: calc(0.6rem - 4px);
    display: flex;
    align-items: center;
    box-sizing: border-box;
}

#combobox {
    font-size: .875rem;
    font-weight: 600;
    line-height: 1.25rem;
    padding: .5rem .75rem;
    margin-left: 5px;
    white-space: nowrap;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
    width: 3.1rem;
    display: flex;
    cursor: pointer;
    position: relative;
}

#combobox svg {
    opacity: .5;
    width: 1rem;
    height: 1rem;
    display: block;
}

#dropdown-menu {
    position: absolute;
    margin: 0;
    padding: 0;
    top: 40px;
    left: -7px;
    width: 62px;
    padding: 5px;
    background-color: var(--dropdown-background-color);
    border: 1px solid var(--dropdown-border);
    border-radius: calc(0.6rem - 4px);
    box-shadow: rgba(0, 0, 0, 0) 0px 0px 0px 0px, rgba(0, 0, 0, 0) 0px 0px 0px 0px, rgba(0, 0, 0, 0.1) 0px 4px 6px -1px, rgba(0, 0, 0, 0.1) 0px 2px 4px -2px;
    z-index: 1;
    cursor: auto;
    transform: translate(0%, -4%);
    scale: 0.97;
    opacity: 0;
    visibility: hidden;
    display: block;
    transition: transform 0.15s ease, opacity 0.15s ease, scale 0.15s ease;
}

#dropdown-menu.show {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
}

#dropdown-menu.hide {
    transition: none;
}

#dropdown-menu li {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 30px;
    border-radius: calc(0.6rem - 6px);
}

#dropdown-menu li svg {
    opacity: 1;
    margin-right: 5px;
    pointer-events: none;
    visibility: hidden;
}

#dropdown-menu li[data-view="selected"] svg {
    visibility: visible;
}

#search {
    width: 100%;
    height: 26px;
    font-family: 'Noto Sans KR', sans-serif;
    font-size: .875rem;
    font-weight: 600;
    line-height: 1.25rem;
    padding-left: .75rem;
    padding-right: .75rem;
    padding-top: .5rem;
    padding-bottom: .5rem;
    border: none;
    outline: none;
    background-color: transparent;
    color: var(--input-color);
}

#clear,
#do-search {
    width: 17.5px;
    height: 17.5px;

    padding: 6px;
    margin-left: 0;
    margin-right: 4px;

    display: flex;
    justify-content: center;
    align-items: center;

    border-radius: calc(0.6rem - 2px);
    cursor: pointer;
}

#clear {
    visibility: hidden;
}

#shortcut-wrapper {
    max-width: 768px;
    width: 100%;
    flex: 0 0 auto;
    box-sizing: border-box;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(1, 1fr);
    column-gap: 9px;
}

@media (max-width: 600px) {
    #shortcut-wrapper {
        grid-template-columns: repeat(1, 1fr);
    }
}

.shortcut-box {
    border: 1px solid var(--border-color);

    padding: 16px;
    padding-bottom: 10px;

    font-size: .75rem;
    line-height: 1rem;

    justify-content: center;
    align-items: center;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
    height: 167px;

    margin-bottom: 9px;
    border-radius: calc(0.6rem - 4px);
    background-color: hsl(var(--sonner));
    box-shadow: 0 0 #0000, 0 0 #0000, 0 1px 2px 0 rgba(0,0,0,.05);
}

.shortcut-title {
    color: var(--color);
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: .7em;
    z-index: 1;
}

.link {
    font-weight: 600;
    font-size: .875rem;
    line-height: 1.25rem;
    padding-left: 1rem;
    padding-right: 1rem;
    border-radius: calc(0.6rem - 2px);
    white-space: nowrap;
    column-gap: .5rem;
    justify-content: center;
    align-items: center;
    height: 2.5rem;
    display: inline-flex;
    cursor: pointer;
    z-index: 1;
    color: var(--color);
    border: 1px solid hsl(var(--border));
    text-decoration: none;

    transition: color cubic-bezier(.4,0,.2,1) .15s, background-color cubic-bezier(.4,0,.2,1) .15s;
}

#untitled-element {
    max-width: 768px;
    width: 100%;
    height: 90px;

    color: #9ca3af;
    font-weight: 500;

    display: flex;
    justify-content: center;
    align-items: center;
    box-sizing: border-box;
    overflow: hidden;

    margin-bottom: 9px;
    flex-shrink: 0;

    border-radius: calc(0.6rem - 4px);
    background-color: hsl(var(--sonner));
    border: 1px solid var(--border-color);
    box-shadow: 0 0 #0000, 0 0 #0000, 0 1px 2px 0 rgba(0,0,0,.05);
}

#info {
    max-width: 768px;
    width: 100%;

    background-color: var(--info-background-color);
    color: var(--info-color);
    border: 1px solid var(--info-border-color);

    padding: 16px;
    padding-bottom: 10px;

    font-size: .75rem;
    line-height: 1rem;

    box-sizing: border-box;

    margin-top: 1px;

    padding: .625rem 13px;
    border-radius: calc(0.6rem - 4px);
    box-shadow: 0 0 #0000, 0 0 #0000, 0 1px 2px 0 rgba(0,0,0,.05);
}

#contacts {
    width: 100%;

    display: flex;
    justify-content: center;
    column-gap: .5rem;

    margin-top: 5px;
    margin-bottom: 10px;
}

#mailto {
    font-family: 'Noto Sans KR', sans-serif;
    color: inherit;
    text-decoration: none;
    font-weight: 500;
    word-break: keep-all;
    cursor: pointer;
}

#info-horizontal-line {
    width: 100%;
    height: 1px;
    margin: 10px 0;

    background-color: hsl(var(--border));
    flex-shrink: 0;
}

#message {
    width: 100%;
    text-align: center;
    word-break: keep-all;
    margin: 10px 0;
}

#copyright {
    display: block;
    width: 100%;
    text-align: center;
    word-break: keep-all;
}

#copyright a {
    text-decoration: none;
    cursor: pointer;
}

#privacy-box {
    display: flex;
    width: 100%;
    justify-content: center;
    text-align: center;
    margin-bottom: 6px;
}

#privacy-text {
    font-weight: 700;
    word-break: keep-all;
    cursor: pointer;
    color: inherit;
    text-decoration: none;
}

#bottom {
    width: 100%;
    height: 1px;
    flex-shrink: 0;
}

#mode {
    width: 30px;
    height: 30px;

    border-radius: calc(0.6rem - 2px);

    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;

    position: absolute;

    top: 5px;
    right: 16px;

    transition: color cubic-bezier(.4,0,.2,1) .15s, background-color cubic-bezier(.4,0,.2,1) .15s;
}

#mode svg {
    width: 15px;
    height: 15px;
}

#theme {
    position: absolute;
    top: 24px;
    right: 16px;
    box-shadow: 0 0 #0000, 0 0 #0000, 0 1px 2px 0 rgba(0,0,0,.05);
    color: hsl(var(--popover-foreground));
    padding: .25rem;
    background-color: hsl(var(--popover));
    border-radius: calc(0.6rem - 2px);
    overflow: hidden;
    min-width: 8rem;
    box-sizing: border-box;
    transform: translate(0%, -4%);
    scale: 0.97;
    opacity: 0;
    visibility: hidden;
    z-index: 1;
    transition: transform 0.15s ease, opacity 0.15s ease, scale 0.15s ease;
}

#theme.show {
    transform: translateY(0);
    opacity: 1;
    scale: 1;
    visibility: visible;
}

#theme li {
    outline: 2px solid transparent;
    outline-offset: 2px;
    font-size: .875rem;
    line-height: 1.25rem;
    padding-top: .375rem;
    padding-bottom: .375rem;
    padding-left: .5rem;
    padding-right: .5rem;
    border-radius: calc(0.6rem - 4px);
    column-gap: .375rem;
    align-items: center;
    cursor: default;
    display: flex;
    position: relative;
    transition: color cubic-bezier(.4,0,.2,1) .15s, background-color cubic-bezier(.4,0,.2,1) .15s;
}

#theme li svg {
    width: 14px;
    height: 14px;
}

#search-container {
    padding: .25rem;
    background-color: hsl(var(--input));
    border: 1px solid var(--dropdown-border);
    border-radius: calc(0.6rem - 4px);
    border-top-left-radius: 0;
    border-top-right-radius: 0;
    border-top: 1px solid hsl(var(--border));
    box-sizing: border-box;
    position: absolute;
    width: calc(100% - 28px);
    z-index: 2;
    box-shadow: 0 0 #0000, 0 0 #0000, 0 25px 50px -12px rgba(0, 0, 0, .15);
}

#search-result {
    min-height: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

#nothing {
    color: var(--info-color);
    font-size: .975rem;
    line-height: 1.25rem;
    text-align: center;
    padding: .5rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.result {
    line-height: 1em;
    font-size: 1rem;
    font-family: 'Noto Sans KR', sans-serif;
    font-weight: 600;
    padding-top: .25rem;
    padding-bottom: .25rem;
    padding-left: .25rem;
    padding-right: .25rem;
    border-radius: calc(0.6rem - 4px);
    display: flex;
    color: inherit;
    text-decoration: inherit;
    height: 28px;
    box-sizing: border-box;
    align-items: center;
    cursor: pointer;
    margin-top: 2px;
    justify-content: space-between;
    width: 100%;
}

.text {
    margin-left: 4px;
    margin-right: 4px;
}

.text span {
    color: var(--filtered);
}

.type {
    color: var(--type-color);
    line-height: 1;
    font-size: .875rem;
    margin-right: 4px;
}

#notice {
    margin-top: .225rem;
    color: var(--type-color);
    font-size: .8rem;
    line-height: 1rem;
    text-align: center;
}

@media (hover: hover) and (pointer: fine) {
    #dropdown-menu li:hover {
        background-color: var(--dropdown-hover);
    }
    
    #clear:hover,
    #do-search:hover {
        background-color: var(--hover);
    }

    .link:hover {
        background-color: var(--hover-light);
    }

    #mailto:hover {
        text-decoration: underline;
    }

    #copyright a:hover {
        text-decoration: underline;
    }

    #privacy-text:hover {
        text-decoration: underline;
    }

    #mode:hover {
        background-color: var(--hover);
    }

    #theme li:hover {
        background-color: hsl(var(--accent));
    }

    .result:hover {
        background-color: hsla(240, 4%, 46%, .1);
    }
}

@media (hover: none) and (pointer: coarse), (max-width: 719px) {
    #dropdown-menu li:active {
        background-color: var(--dropdown-hover);
    }
    
    #clear:active,
    #do-search:active {
        background-color: var(--hover);
    }

    .link:active {
        background-color: var(--hover-light);
    }

    #mailto:active {
        text-decoration: underline;
    }

    #copyright a:active {
        text-decoration: underline;
    }

    #privacy-text:active {
        text-decoration: underline;
    }

    #mode:active {
        background-color: var(--hover);
    }

    #theme li:active {
        background-color: hsl(var(--accent));
    }
    
    .result:active {
        background-color: hsla(240, 4%, 46%, .1);
    }
}