@charset "UTF-8";







@layer defaults, theme, base, components, utilities;

@layer base {
    :root {
        --font-family: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, system-ui, Roboto, 'Helvetica Neue', 'Segoe UI', 'Apple SD Gothic Neo', 'Noto Sans KR', 'Malgun Gothic', 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', sans-serif;
        --font-eng: 'Inter', sans-serif;
        --font-noto: 'Noto Sans KR', sans-serif;
        --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    }


    body {
        font-family: var(--font-family);
        color: #1d1d1f;
        word-break: keep-all;
        overflow-wrap: anywhere;
    }
}

/* JIT가 생성하지 않는 UI 효과 보정. */
.floating-field > label {
    transition: top .16s ease, color .16s ease, font-size .16s ease, transform .16s ease;
}
.floating-field > input {
    transition: border-color .16s ease, box-shadow .16s ease, background-color .16s ease;
}
.floating-field > input:is(:autofill, :-webkit-autofill, [placeholder]:not(:placeholder-shown)) {
    padding-top: 16px;
    padding-bottom: 6px;
}
.floating-field > input:is(:autofill, :-webkit-autofill, [placeholder]:not(:placeholder-shown)) ~ label {
    top: 8px;
    color: #5f6368;
    font-size: 12px;
    transform: translateY(0);
}
.tooltip::after { transform: translateX(-50%); transition: opacity .2s ease; }
i.ph { vertical-align: middle; }

/* 달의소리: 어린이용 캐릭터와 한 화면 중심의 앱 구성. */
.moon-app {
    --font-family: -apple-system, BlinkMacSystemFont, 'Apple SD Gothic Neo', 'Noto Sans KR', 'Malgun Gothic', sans-serif;
    --naknes-container-gutter: 1rem;
    background: #efeeeb;
    height: 100dvh;
    overflow: hidden;
    -webkit-tap-highlight-color: transparent;
}
.moon-app [hidden] { display: none !important; }
.moon-app :is(a, button, input):focus-visible { outline: 3px solid #c99d23; outline-offset: 3px; }
.moon-app :is(button, a) { touch-action: manipulation; }
.moon-app button { cursor: pointer; }
.moon-app button:disabled { opacity: .35; cursor: not-allowed; }
.moon-app svg { flex-shrink: 0; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.moon-app .skip-link { position: fixed; top: -6rem; left: 1rem; z-index: 2000; background: white; padding: 1rem; border-radius: 1rem; }
.moon-app .skip-link:focus { top: 1rem; }
.moon-app .app-shell { --naknes-container-inset: 0; height: 100dvh; display: grid; place-items: center; }
.moon-app .app-panel { width: min(100%, 440px); height: 100dvh; background: #faf9f6; display: flex; flex-direction: column; overflow: hidden; }
.moon-app .topbar { min-height: 60px; padding-top: env(safe-area-inset-top, 0px); flex-shrink: 0; }
.moon-app .brand { white-space: nowrap; }
.moon-app .connection-state { color: #77766e; white-space: nowrap; }
.moon-app .status-dot { width: 5px; height: 5px; background: #b3b39a; border-radius: 50%; }
.moon-app .offline .status-dot { background: #d4ae45; }
.moon-app .round-control { width: 44px; height: 44px; flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; border-radius: 16px; transition: background .15s, transform .15s; }
.moon-app .round-control svg { width: 21px; height: 21px; }
.moon-app .round-control:hover { background: #efede6; }
.moon-app .round-control:active { transform: scale(.94); }
.moon-app main { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding-top: 8px; padding-bottom: 10px; }
.moon-app .home-view { height: 100%; display: grid; grid-template-rows: auto minmax(80px, 1fr) auto auto auto auto auto; gap: 8px; }
.moon-app .character-stage { position: relative; min-height: 0; display: flex; align-items: center; justify-content: center; }
.moon-app .sleepy-cat { height: 100%; max-height: 230px; max-width: 100%; width: auto; user-select: none; }
.moon-app .little-star { position: absolute; color: #d9b64f; }
.moon-app .star-left { left: 14%; top: 32%; transform: rotate(-15deg); }
.moon-app .star-right { right: 13%; bottom: 25%; transform: rotate(12deg); }
.moon-app .sleep-letter { position: absolute; right: 23%; top: 8%; color: #77766e; letter-spacing: .14em; font-weight: 600; transform: rotate(-12deg); }
.moon-app .is-playing .sleepy-cat { animation: sleepy-breathe 4s ease-in-out infinite; }
.moon-app .is-playing .sleep-letter { animation: sleepy-notes 4s ease-in-out infinite; }
.moon-app .time-block > p:first-child { font-variant-numeric: tabular-nums; font-feature-settings: 'tnum'; }
.moon-app .seek-area input[type='range'] { display: block; accent-color: #2a2b26; height: 20px; cursor: pointer; }
.moon-app .seek-area input:disabled { opacity: .45; cursor: default; }
.moon-app .listen-control { min-height: 56px; background: #272824; color: #fff; transition: background .15s, transform .15s; }
.moon-app .listen-control:hover { background: #47483f; }
.moon-app .listen-control:active { transform: scale(.98); }
.moon-app .option-control { min-height: 48px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; border-radius: 14px; color: #74736b; transition: background .15s, color .15s; }
.moon-app .option-control svg { width: 19px; height: 19px; }
.moon-app .option-control:hover { background: #f0eee5; color: #252522; }
.moon-app [aria-pressed='true'].option-control { color: #252522; background: #f9edbd; }
.moon-app [aria-pressed='true'] use[href$='#heart'] { fill: currentColor; }
.moon-app .collection-view { height: 100%; display: grid; grid-template-rows: auto auto auto auto minmax(0, 1fr) auto; gap: 12px; }
.moon-app .heading-star { color: #c5a13e; }
.moon-app .search-field { background: #efeee9; min-height: 44px; color: #77766e; }
.moon-app .search-field input { min-width: 0; border: 0; outline: none; height: 44px; }
.moon-app .search-field:focus-within { outline: 2px solid #c99d23; outline-offset: 2px; }
.moon-app .filter-chip { flex: 1; white-space: nowrap; min-height: 36px; border-radius: 12px; color: #74736b; transition: background .15s; }
.moon-app .filter-chip:hover { background: #efede5; }
.moon-app .filter-chip[aria-pressed='true'] { color: #252522; background: #f9edbd; }
.moon-app .collection-body { min-height: 0; overflow-y: auto; overscroll-behavior: contain; }
.moon-app .sound-row { min-height: 76px; background: #f0efea; border: 1px solid transparent; }
.moon-app .sound-row.is-current { border-color: #d6ba5d; background: #fbf2d2; }
.moon-app .sound-avatar { width: 42px; height: 42px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; border-radius: 15px; background: #e8e1c8; color: #57513b; }
.moon-app .sound-avatar svg { width: 22px; height: 22px; }
.moon-app .sound-avatar[data-category='rain'] { background: #e1e7e8; color: #576a6c; }
.moon-app .sound-avatar[data-category='nature'] { background: #e2e8d9; color: #63744f; }
.moon-app .sound-row .round-control { width: 40px; height: 44px; border-radius: 14px; }
.moon-app .row-play { background: #272824; color: #fff; }
.moon-app .row-play:hover { background: #47483f; }
.moon-app .row-favorite[aria-pressed='true'] { color: #aa744c; }
.moon-app .page-control { min-height: 42px; display: flex; align-items: center; justify-content: center; gap: 4px; padding-inline: 10px; border-radius: 12px; transition: background .15s; }
.moon-app .page-control svg { width: 17px; height: 17px; }
.moon-app .page-control:hover:not(:disabled) { background: #efede5; }
.moon-app .library-view { grid-template-rows: auto auto auto minmax(0, 1fr) auto; }
.moon-app .library-tabs { background: #efeee9; }
.moon-app .library-tab { min-height: 42px; transition: background .15s; }
.moon-app .library-tab:hover { background: #e9e7de; }
.moon-app .library-tab[aria-pressed='true'] { background: #fffefa; box-shadow: 0 2px 6px #3b35210a; }
.moon-app .empty-state { min-height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; padding-block: 10px; }
.moon-app .empty-cat { width: 140px; max-height: 100px; object-fit: contain; margin-bottom: 10px; }
.moon-app .empty-action { background: #f7e7a7; color: #3b3521; transition: background .15s; }
.moon-app .empty-action:hover { background: #edd784; }
.moon-app .download-progress { height: 3px; border-radius: 3px; background: #e6e2d2; overflow: hidden; }
.moon-app .download-progress span { display: block; height: 100%; background: #bc9e3d; }
.moon-app .bottom-nav { min-height: 68px; padding-bottom: env(safe-area-inset-bottom, 0px); display: grid; grid-template-columns: repeat(3, 1fr); flex-shrink: 0; background: #faf9f6; border-top: 1px solid #eae8e1; }
.moon-app .bottom-nav a { display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 4px; color: #85847c; }
.moon-app .bottom-nav svg { width: 21px; height: 21px; }
.moon-app .bottom-nav a[aria-current='page'] { color: #252522; }
.moon-app .bottom-nav a[aria-current='page'] svg { background: #f8ebba; border-radius: 7px; outline: 4px solid #f8ebba; }
.moon-app .player-dock { flex-shrink: 0; border-top: 1px solid #eae8e1; background: #f3f0e5; }
.moon-app .dock-inner { min-height: 60px; }
.moon-app .dock-progress { height: 2px; background: #e6e2d2; }
.moon-app .dock-progress span { display: block; height: 100%; background: #b49b49; width: 0; }
.moon-app .modal-overlay { background: #27282466; transition: opacity .25s; }
.moon-app .modal-content { border-radius: 28px; background: #faf9f6; color: #252522; box-shadow: 0 24px 80px #25252226; transition: transform .25s; }
.moon-app .timer-choice { background: #eeede6; min-height: 64px; transition: background .15s; }
.moon-app .timer-choice:hover, .moon-app .timer-choice[aria-pressed='true'] { background: #f7e7a7; }
@keyframes sleepy-breathe { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
@keyframes sleepy-notes { 0%, 100% { opacity: .45; } 50% { opacity: 1; } }
@media (min-width: 640px) {
    .moon-app .app-panel { height: min(850px, calc(100dvh - 48px)); border-radius: 32px; box-shadow: 0 12px 50px #35352d0c; border: 1px solid #fff; }
}
.moon-app .is-compact .topbar { min-height: 54px; }
.moon-app .is-compact main { padding-top: 2px; padding-bottom: 6px; }
.moon-app .is-compact .home-view { gap: 5px; grid-template-rows: auto minmax(64px, 1fr) auto auto auto auto auto; }
.moon-app .is-compact .home-intro p, .moon-app .is-compact .song-heading p { display: none; }
.moon-app .is-compact .listen-control { min-height: 50px; }
.moon-app .is-compact .option-control { min-height: 44px; }
.moon-app .is-compact .collection-view { gap: 8px; }
.moon-app .is-compact .bottom-nav { min-height: 62px; }
.moon-app .is-compact .empty-cat { max-height: 72px; }
@media (max-height: 450px) {
    .moon-app .home-view { min-height: 440px; }
    .moon-app .collection-view { min-height: 390px; }
}
.moon-app .is-short .home-view { gap: 4px; grid-template-rows: auto minmax(40px, 1fr) auto auto auto auto auto; }
@media (prefers-reduced-motion: reduce) {
    .moon-app *, .moon-app *::before, .moon-app *::after { transition: none !important; animation: none !important; }
}
