:root {
    --bg-ink: #17060d;
    --bg-deep: #250710;
    --bg-wine: #4d1020;
    --line: rgba(255, 226, 214, 0.18);
    --line-strong: rgba(255, 211, 196, 0.34);
    --text-main: #fff6f1;
    --text-soft: rgba(255, 244, 238, 0.72);
    --text-muted: rgba(255, 235, 227, 0.56);
    --strawberry: #ff5f7c;
    --rose: #ff8f8f;
    --cream: #ffe8db;
    --gold: #f8d48f;
    --shadow: 0 24px 80px rgba(7, 1, 4, 0.45);
}

body.light-theme {
    --bg-ink: #fff7f2;
    --bg-deep: #ffe6de;
    --bg-wine: #ffd1d6;
    --line: rgba(164, 67, 93, 0.16);
    --line-strong: rgba(164, 67, 93, 0.28);
    --text-main: #59283a;
    --text-soft: rgba(89, 40, 58, 0.76);
    --text-muted: rgba(89, 40, 58, 0.58);
    --cream: #fff8f2;
    --gold: #bb7b3f;
    --shadow: 0 24px 70px rgba(173, 99, 118, 0.18);
}

* {
    box-sizing: border-box;
}

html,
body {
    width: 100%;
    height: 100%;
}

body {
    margin: 0;
    overflow: hidden;
    position: relative;
    background:
        radial-gradient(circle at 15% 20%, rgba(255, 145, 145, 0.2), transparent 28%),
        radial-gradient(circle at 82% 18%, rgba(255, 95, 124, 0.18), transparent 24%),
        radial-gradient(circle at 50% 80%, rgba(248, 212, 143, 0.12), transparent 26%),
        linear-gradient(145deg, var(--bg-ink) 0%, var(--bg-deep) 42%, var(--bg-wine) 72%, #120206 100%);
    color: var(--text-main);
    font-family: "Manrope", sans-serif;
    transition: background 0.4s ease, color 0.3s ease;
}

body.light-theme {
    background:
        radial-gradient(circle at 14% 18%, rgba(255, 170, 170, 0.34), transparent 30%),
        radial-gradient(circle at 86% 12%, rgba(255, 141, 167, 0.22), transparent 24%),
        radial-gradient(circle at 50% 84%, rgba(255, 211, 154, 0.22), transparent 28%),
        linear-gradient(145deg, var(--bg-ink) 0%, var(--bg-deep) 48%, var(--bg-wine) 100%);
}

body::before,
body::after {
    content: "";
    position: fixed;
    inset: auto;
    border-radius: 999px;
    pointer-events: none;
    filter: blur(50px);
    z-index: 0;
}

body::before {
    width: 40vw;
    height: 40vw;
    left: -10vw;
    bottom: -14vw;
    background: rgba(255, 94, 125, 0.16);
    animation: driftBlob 16s ease-in-out infinite;
}

body::after {
    width: 28vw;
    height: 28vw;
    right: -6vw;
    top: 8vh;
    background: rgba(248, 212, 143, 0.12);
    animation: driftBlob 20s ease-in-out infinite reverse;
}

body.light-theme::before {
    background: rgba(255, 176, 167, 0.24);
}

body.light-theme::after {
    background: rgba(255, 209, 169, 0.24);
}

#container {
    position: fixed;
    inset: 0;
    z-index: 1;
}

#container canvas {
    display: block;
    filter: saturate(1.08) contrast(1.04);
}

.scene-chrome,
.ambient-copy,
#themeDock,
#controls,
#lyrics-container,
.letter-modal {
    position: fixed;
    z-index: 2;
}

.scene-chrome {
    inset: 0;
    pointer-events: none;
}

.scene-chrome::before {
    content: "";
    position: absolute;
    inset: 18px;
    border-radius: 30px;
    border: 1px solid rgba(255, 228, 219, 0.08);
    box-shadow: inset 0 0 0 1px rgba(255, 145, 145, 0.05);
}

.chrome-badge {
    position: absolute;
    top: 28px;
    left: 28px;
    padding: 10px 16px;
    border-radius: 999px;
    border: 1px solid rgba(255, 226, 214, 0.2);
    background: rgba(37, 7, 16, 0.55);
    backdrop-filter: blur(12px);
    color: var(--cream);
    font-size: 0.72rem;
    letter-spacing: 0.28em;
    text-transform: uppercase;
}

body.light-theme .chrome-badge {
    background: rgba(255, 255, 255, 0.58);
    color: #8a3551;
    border-color: rgba(164, 67, 93, 0.16);
}

.ambient-copy {
    top: 74px;
    left: 50%;
    transform: translateX(-50%);
    width: min(560px, calc(100vw - 40px));
    text-align: center;
    pointer-events: none;
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.ambient-kicker {
    margin: 0 0 10px;
    color: var(--gold);
    font-size: 0.78rem;
    letter-spacing: 0.34em;
    text-transform: uppercase;
}

.ambient-title {
    margin: 0;
    font-family: "Cormorant Garamond", serif;
    font-size: clamp(3rem, 7vw, 5.4rem);
    line-height: 0.98;
    font-weight: 600;
    letter-spacing: 0.03em;
    text-shadow: 0 10px 30px rgba(0, 0, 0, 0.28);
}

.ambient-subtitle {
    width: min(420px, 100%);
    margin: 14px auto 0;
    color: var(--text-soft);
    font-size: 1rem;
    line-height: 1.55;
}

body.music-on .ambient-copy {
    opacity: 0.4;
    transform: translateX(-50%) translateY(-10px);
}

body.light-theme .ambient-title {
    text-shadow: 0 10px 30px rgba(255, 255, 255, 0.24);
}

#themeDock {
    top: 28px;
    right: 28px;
    z-index: 3;
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

#themeDock.show {
    opacity: 1;
    transform: translateY(0);
}

.theme-toggle {
    min-width: 0;
    padding: 8px 10px 8px 8px;
    gap: 10px;
    border-radius: 999px;
    border: 1px solid rgba(255, 226, 214, 0.18);
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.02)),
        linear-gradient(180deg, rgba(55, 17, 28, 0.78), rgba(25, 8, 14, 0.9));
    box-shadow: 0 14px 32px rgba(14, 2, 7, 0.28);
    letter-spacing: 0.08em;
    text-transform: none;
}

.theme-toggle:hover {
    transform: translateY(-2px);
}

.theme-toggle-track {
    position: relative;
    width: 54px;
    height: 30px;
    flex: 0 0 auto;
    border-radius: 999px;
    background: linear-gradient(135deg, rgba(255, 184, 197, 0.25), rgba(121, 34, 61, 0.9));
    border: 1px solid rgba(255, 226, 214, 0.14);
    box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.24);
}

.theme-toggle-track::before,
.theme-toggle-track::after {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.72rem;
    line-height: 1;
}

.theme-toggle-track::before {
    content: "☀";
    left: 7px;
    color: rgba(255, 238, 204, 0.92);
}

.theme-toggle-track::after {
    content: "☾";
    right: 8px;
    color: rgba(255, 235, 227, 0.72);
}

.theme-toggle-thumb {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: linear-gradient(180deg, #fff8f2 0%, #ffd4de 100%);
    box-shadow: 0 4px 12px rgba(35, 7, 14, 0.34);
    transition: transform 0.26s ease, background 0.26s ease;
}

.theme-toggle-text {
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--text-main);
    white-space: nowrap;
}

body.light-theme .theme-toggle {
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.92), rgba(255, 245, 247, 0.72)),
        linear-gradient(180deg, rgba(255, 228, 231, 0.82), rgba(255, 242, 236, 0.88));
    border-color: rgba(164, 67, 93, 0.16);
    box-shadow: 0 12px 28px rgba(173, 99, 118, 0.16);
}

body.light-theme .theme-toggle-track {
    background: linear-gradient(135deg, rgba(255, 202, 184, 0.95), rgba(255, 136, 168, 0.86));
    border-color: rgba(164, 67, 93, 0.12);
    box-shadow: inset 0 2px 8px rgba(164, 67, 93, 0.14);
}

body.light-theme .theme-toggle-thumb {
    transform: translateX(24px);
    background: linear-gradient(180deg, #fffdfb 0%, #fff2cb 100%);
}

body.light-theme .theme-toggle-text {
    color: #7a2f4b;
}

#controls {
    top: 26px;
    left: 50%;
    transform: translateX(-50%) translateY(-8px);
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    width: min(760px, calc(100vw - 32px));
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.8s ease, transform 0.8s ease;
}

#controls.show {
    opacity: 1;
    pointer-events: auto;
    transform: translateX(-50%) translateY(0);
}

#controls .control-group {
    display: flex;
    gap: 12px;
}

button {
    appearance: none;
    border: 1px solid var(--line);
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.02)),
        linear-gradient(180deg, rgba(255, 108, 134, 0.12), rgba(80, 14, 31, 0.24));
    color: var(--text-main);
    padding: 13px 18px;
    border-radius: 999px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font: inherit;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    backdrop-filter: blur(18px);
    box-shadow: 0 14px 32px rgba(14, 2, 7, 0.28);
    transition:
        transform 0.28s ease,
        border-color 0.28s ease,
        box-shadow 0.28s ease,
        background 0.28s ease;
}

button:hover {
    transform: translateY(-3px);
    border-color: var(--line-strong);
    box-shadow: 0 18px 36px rgba(14, 2, 7, 0.38);
}

button:active {
    transform: translateY(0);
}

button.primary,
button.playing {
    background:
        linear-gradient(135deg, rgba(255, 236, 228, 0.22), rgba(255, 255, 255, 0.06)),
        linear-gradient(140deg, rgba(255, 110, 138, 0.82), rgba(164, 29, 60, 0.86));
    border-color: rgba(255, 226, 214, 0.32);
    box-shadow: 0 18px 38px rgba(100, 11, 34, 0.44);
}

body.light-theme button {
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.85), rgba(255, 255, 255, 0.5)),
        linear-gradient(180deg, rgba(255, 202, 208, 0.42), rgba(255, 228, 234, 0.74));
    box-shadow: 0 12px 26px rgba(173, 99, 118, 0.16);
}

body.light-theme button.primary,
body.light-theme button.playing {
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.94), rgba(255, 241, 244, 0.76)),
        linear-gradient(140deg, rgba(255, 128, 153, 0.8), rgba(240, 162, 133, 0.78));
    color: #fff9f7;
    border-color: rgba(255, 255, 255, 0.7);
    box-shadow: 0 16px 32px rgba(207, 117, 140, 0.26);
}

body.light-theme #playMusic {
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(255, 250, 246, 0.82)),
        linear-gradient(135deg, rgba(255, 117, 149, 0.92), rgba(245, 150, 117, 0.88));
    color: #7a2441;
    border-color: rgba(255, 255, 255, 0.84);
    box-shadow: 0 18px 34px rgba(214, 111, 137, 0.28);
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.28);
}

body.light-theme #playMusic.playing {
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(255, 244, 241, 0.84)),
        linear-gradient(135deg, rgba(224, 87, 126, 0.96), rgba(241, 127, 97, 0.92));
    color: #6a1835;
}

.letter-btn {
    background:
        linear-gradient(135deg, rgba(248, 212, 143, 0.15), rgba(255, 255, 255, 0.03)),
        linear-gradient(180deg, rgba(87, 29, 17, 0.32), rgba(50, 16, 12, 0.44)) !important;
    border-color: rgba(248, 212, 143, 0.24) !important;
    color: #ffe9c1 !important;
}

body.light-theme .letter-btn {
    background:
        linear-gradient(135deg, rgba(255, 249, 236, 0.9), rgba(255, 255, 255, 0.64)),
        linear-gradient(180deg, rgba(255, 211, 168, 0.72), rgba(255, 231, 202, 0.82)) !important;
    color: #8c4f2e !important;
    border-color: rgba(195, 129, 84, 0.28) !important;
}

.btn-icon {
    font-size: 0.95rem;
}

#lyrics-container {
    left: 50%;
    bottom: 34px;
    transform: translateX(-50%) translateY(16px);
    width: min(760px, calc(100vw - 32px));
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.45s ease, transform 0.45s ease;
}

#lyrics-container.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

#lyrics {
    min-height: 142px;
    padding: 28px 32px;
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    background:
        radial-gradient(circle at top center, rgba(255, 178, 196, 0.16), transparent 46%),
        linear-gradient(145deg, rgba(255, 245, 240, 0.12), rgba(255, 255, 255, 0.04)),
        linear-gradient(180deg, rgba(57, 17, 27, 0.72), rgba(25, 8, 14, 0.86));
    border: 1px solid rgba(255, 228, 219, 0.18);
    box-shadow:
        0 30px 70px rgba(8, 2, 5, 0.42),
        0 12px 30px rgba(66, 14, 28, 0.24),
        inset 0 1px 0 rgba(255, 255, 255, 0.06);
    backdrop-filter: blur(34px) saturate(135%);
}

body.light-theme #lyrics {
    background:
        radial-gradient(circle at top center, rgba(255, 190, 199, 0.28), transparent 44%),
        linear-gradient(145deg, rgba(255, 255, 255, 0.86), rgba(255, 250, 248, 0.62)),
        linear-gradient(180deg, rgba(255, 229, 233, 0.74), rgba(255, 243, 236, 0.84));
    border-color: rgba(178, 101, 122, 0.16);
    box-shadow:
        0 26px 54px rgba(190, 123, 142, 0.16),
        0 10px 24px rgba(221, 170, 181, 0.18),
        inset 0 1px 0 rgba(255, 255, 255, 0.52);
}

body.light-theme #lyrics::before {
    border-color: rgba(177, 94, 119, 0.08);
}

body.light-theme #lyrics::after {
    background: linear-gradient(120deg, transparent 18%, rgba(255, 255, 255, 0.22) 50%, transparent 82%);
}

#lyrics::before {
    content: "";
    position: absolute;
    inset: 1px;
    border-radius: 27px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    pointer-events: none;
}

#lyrics::after {
    content: "";
    position: absolute;
    inset: auto auto -24% 50%;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(circle, rgba(255, 110, 138, 0.18) 0%, rgba(255, 110, 138, 0.08) 34%, transparent 68%),
        linear-gradient(120deg, transparent 20%, rgba(255, 255, 255, 0.06) 50%, transparent 78%);
    transform: translateX(-120%) translateX(-50%);
    filter: blur(14px);
    animation: panelSweep 8s ease-in-out infinite;
    pointer-events: none;
}

.lyric-line {
    position: absolute;
    inset: 50% auto auto 50%;
    width: calc(100% - 56px);
    transform: translate(-50%, -50%);
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 0.55rem 0.85rem;
    opacity: 0;
    filter: blur(12px);
    transition: opacity 0.45s ease, filter 0.45s ease;
}

.lyric-line.is-visible {
    opacity: 1;
    filter: blur(0);
}

.word {
    display: inline-block;
    opacity: 0;
    transform: translateY(24px) scale(0.92) rotate(-2deg);
    font-family: "Cormorant Garamond", serif;
    font-size: clamp(1.7rem, 3vw, 2.9rem);
    font-weight: 600;
    line-height: 1.05;
    letter-spacing: 0.04em;
    color: var(--text-main);
    text-shadow:
        0 0 20px rgba(255, 105, 135, 0.2),
        0 12px 26px rgba(0, 0, 0, 0.28);
    will-change: transform, opacity;
}

body.light-theme .word {
    color: #702d46;
    text-shadow:
        0 0 20px rgba(255, 164, 178, 0.3),
        0 12px 26px rgba(205, 152, 165, 0.18);
}

body.light-theme .word.accent-word {
    color: #8f2f4d;
}

body.light-theme .word.emoji-word {
    color: #d05f84;
    text-shadow: 0 0 20px rgba(255, 141, 167, 0.22);
}

.word.is-visible {
    animation: lyricReveal 0.85s cubic-bezier(0.2, 0.9, 0.2, 1) forwards;
}

.word.accent-word {
    color: var(--cream);
}

.word.emoji-word {
    font-family: "Manrope", sans-serif;
    letter-spacing: 0;
    color: #ffd5dd;
    text-shadow: 0 0 26px rgba(255, 95, 124, 0.34);
}

.letter-modal {
    inset: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 24px;
    background: rgba(10, 2, 5, 0.76);
    backdrop-filter: blur(20px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.32s ease, visibility 0.32s ease;
}

.letter-modal.show {
    opacity: 1;
    visibility: visible;
}

body.light-theme .letter-modal {
    background: rgba(255, 240, 235, 0.6);
}

.letter-content {
    position: relative;
    width: min(680px, 100%);
    max-height: 90vh;
    overflow-y: auto;
    transform: translateY(30px) scale(0.94) rotateX(8deg);
    transform-origin: center top;
    transition: transform 0.4s cubic-bezier(0.2, 0.9, 0.2, 1);
}

.letter-modal.show .letter-content {
    transform: translateY(0) scale(1) rotateX(0deg);
}

.letter-paper {
    position: relative;
    padding: 44px 42px 38px;
    border-radius: 28px;
    background:
        radial-gradient(circle at top right, rgba(255, 191, 191, 0.38), transparent 26%),
        linear-gradient(180deg, #fff8f2 0%, #ffece3 100%);
    border: 1px solid rgba(156, 78, 61, 0.12);
    box-shadow:
        0 24px 90px rgba(0, 0, 0, 0.28),
        0 14px 32px rgba(88, 29, 40, 0.18);
    color: #582537;
    overflow: hidden;
}

.letter-paper::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(transparent 30px, rgba(194, 98, 119, 0.12) 31px, transparent 32px);
    background-size: 100% 34px;
    opacity: 0.55;
    pointer-events: none;
}

.letter-paper::after {
    content: "";
    position: absolute;
    top: 24px;
    right: 28px;
    width: 76px;
    height: 76px;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, #ffd7df, #ff8aa2 70%, #e15475 100%);
    box-shadow: inset 0 4px 10px rgba(255, 255, 255, 0.45);
    opacity: 0.22;
}

.close-letter {
    position: absolute;
    top: 18px;
    right: 18px;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    padding: 0;
    background: rgba(255, 255, 255, 0.58);
    border: 1px solid rgba(173, 87, 107, 0.2);
    color: #b13e60;
    font-size: 1.7rem;
    font-weight: 500;
    letter-spacing: 0;
    box-shadow: none;
}

.close-letter:hover {
    background: rgba(255, 255, 255, 0.88);
}

.letter-header,
.letter-body {
    position: relative;
    z-index: 1;
}

.letter-header {
    margin-bottom: 26px;
    padding-bottom: 18px;
    border-bottom: 1px solid rgba(177, 62, 96, 0.16);
    text-align: center;
}

.letter-header h2 {
    margin: 0;
    font-family: "Cormorant Garamond", serif;
    font-size: clamp(2.4rem, 4vw, 3.1rem);
    font-weight: 700;
    letter-spacing: 0.02em;
    color: #a22b57;
}

.letter-date {
    margin-top: 8px;
    color: rgba(88, 37, 55, 0.72);
    font-size: 0.95rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.letter-body {
    font-family: "Parisienne", cursive;
    font-size: clamp(1.7rem, 2.8vw, 2.15rem);
    line-height: 1.5;
}

.letter-body p {
    margin: 0 0 18px;
}

.greeting {
    color: #bf4168;
}

.closing {
    margin-top: 24px;
    padding-top: 16px;
    border-top: 1px solid rgba(177, 62, 96, 0.16);
    text-align: right;
}

.signature {
    color: #9f2f54;
}

.letter-decorations {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.heart-decoration {
    position: absolute;
    font-size: 1.9rem;
    opacity: 0.18;
    animation: floatHeart 7s ease-in-out infinite;
}

.heart-decoration:nth-child(1) {
    top: 18%;
    left: 10%;
}

.heart-decoration:nth-child(2) {
    top: 56%;
    right: 12%;
    animation-delay: 2.2s;
}

.heart-decoration:nth-child(3) {
    bottom: 18%;
    left: 18%;
    animation-delay: 4.1s;
}

@media (max-width: 900px) {
    .ambient-copy {
        top: 88px;
    }

    #controls {
        top: 20px;
        width: calc(100vw - 24px);
    }

    #controls .control-group {
        flex-wrap: wrap;
        justify-content: center;
    }
}

@media (max-width: 768px) {
    .scene-chrome::before {
        inset: 10px;
        border-radius: 24px;
    }

    .chrome-badge {
        top: 18px;
        left: 18px;
        font-size: 0.64rem;
        letter-spacing: 0.24em;
    }

    #themeDock {
        top: 18px;
        right: 18px;
    }

    .ambient-copy {
        top: 112px;
        width: calc(100vw - 28px);
    }

    .ambient-title {
        line-height: 1.02;
    }

    .ambient-subtitle {
        font-size: 0.94rem;
    }

    #controls {
        gap: 10px;
    }

    button {
        padding: 11px 14px;
        font-size: 0.68rem;
        letter-spacing: 0.14em;
        gap: 8px;
    }

    .theme-toggle {
        padding: 7px 9px 7px 7px;
    }

    .theme-toggle-text {
        font-size: 0.72rem;
    }

    #lyrics-container {
        bottom: 18px;
        width: calc(100vw - 20px);
    }

    #lyrics {
        min-height: 112px;
        padding: 22px 18px;
        border-radius: 22px;
    }

    .lyric-line {
        width: calc(100% - 30px);
        gap: 0.35rem 0.55rem;
    }

    .word {
        font-size: clamp(1.35rem, 5.5vw, 2rem);
    }

    .letter-modal {
        padding: 12px;
    }

    .letter-paper {
        padding: 36px 24px 28px;
        border-radius: 24px;
    }

    .close-letter {
        top: 12px;
        right: 12px;
        width: 38px;
        height: 38px;
    }
}

@media (max-width: 520px) {
    .ambient-kicker {
        font-size: 0.66rem;
        letter-spacing: 0.22em;
    }

    .ambient-title {
        font-size: clamp(2.4rem, 13vw, 3.3rem);
        line-height: 1.04;
    }

    #themeDock {
        top: auto;
        right: 12px;
        bottom: 126px;
    }

    #controls {
        top: 16px;
        gap: 8px;
    }

    #controls .control-group {
        width: 100%;
        gap: 8px;
    }

    button {
        flex: 1 1 calc(50% - 4px);
        min-width: 0;
        justify-content: center;
    }

    .theme-toggle {
        padding: 6px;
        gap: 0;
        width: 54px;
        height: 54px;
        justify-content: center;
    }

    .theme-toggle-text {
        display: none;
    }

    .btn-text {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    #lyrics {
        min-height: 96px;
        padding: 20px 14px;
    }

    .word {
        font-size: clamp(1.18rem, 6.8vw, 1.65rem);
        letter-spacing: 0.03em;
    }

    .letter-body {
        font-size: 1.5rem;
        line-height: 1.42;
    }
}

@keyframes lyricReveal {
    0% {
        opacity: 0;
        transform: translateY(24px) scale(0.92) rotate(-2deg);
    }
    55% {
        opacity: 1;
        transform: translateY(-4px) scale(1.03) rotate(0deg);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1) rotate(0deg);
    }
}

@keyframes panelSweep {
    0%,
    72%,
    100% {
        transform: translateX(-120%);
    }
    86% {
        transform: translateX(120%);
    }
}

@keyframes floatHeart {
    0%,
    100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-12px) rotate(6deg);
    }
}

@keyframes driftBlob {
    0%,
    100% {
        transform: translate3d(0, 0, 0);
    }
    50% {
        transform: translate3d(24px, -20px, 0);
    }
}
