:root {
    --blue-100: #e6ecff;
    --blue-200: #cfdcff;
    --blue-300: #aebffd;
    --blue-500: #4d71c7;
    --blue-700: #283f8f;
    --purple-300: #cfb3ff;
    --purple-500: #9d65e9;
    --rose-300: #ffbfd7;
    --rose-500: #f176ac;
    --glass-white: rgba(255, 255, 255, 0.5);
    --glass-strong: rgba(255, 255, 255, 0.82);
    --text-dark: #2f2f63;
    --shadow-lg: 0 30px 60px rgba(49, 44, 109, 0.25);
    --outer-bg-image: none;
    --outer-bg-overlay: linear-gradient(180deg, #52246c 0%, #8f4ea8 35%, #d673ac 68%, #f5a4c8 100%);
    --app-bg-image: none;
    --app-bg-overlay: linear-gradient(180deg, #ffe8f2 0%, #f3dcf8 46%, #e7d7ff 100%);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Arial Rounded MT Bold', 'Helvetica', sans-serif;
}

body {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    color: var(--text-dark);
    background:
        var(--outer-bg-image) center / cover no-repeat,
        linear-gradient(90deg, rgba(255, 255, 255, 0.24) 2px, transparent 2px) 0 0 / 118px 118px,
        linear-gradient(0deg, rgba(255, 255, 255, 0.24) 2px, transparent 2px) 0 0 / 118px 118px,
        var(--outer-bg-overlay);
}

#white-overlay {
    position: fixed;
    inset: 0;
    background: white;
    z-index: 100;
    pointer-events: none;
    animation: fadeOutWhite 1.1s forwards;
}

@keyframes fadeOutWhite {
    from { opacity: 1; }
    to { opacity: 0; }
}

.fade-in {
    animation: pageLoadIn 0.9s ease-out;
}

@keyframes pageLoadIn {
    from { opacity: 0; transform: translateY(16px) scale(0.99); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.app-shell {
    width: min(1380px, 96vw);
    height: min(880px, 94vh);
    border: 12px solid rgba(255, 255, 255, 0.96);
    border-radius: 20px;
    overflow: hidden;
    isolation: isolate;
    box-shadow: 0 25px 60px rgba(35, 20, 60, 0.35), 0 0 0 1px rgba(255, 255, 255, 0.5);
    display: flex;
    flex-direction: column;
    position: relative;
    background: var(--app-bg-image) center / cover no-repeat, var(--app-bg-overlay);
    transition: transform 0.4s ease, opacity 0.4s ease;
}

.app-shell > main {
    min-height: 0;
}

.icon-sm { width: 24px; height: 24px; filter: opacity(0.8); }
.icon-tb { width: 22px; height: 22px; }
.icon-xs { width: 15px; height: 15px; opacity: 0.72; }
.icon-tb-emoji { font-size: 1.25rem; line-height: 1; display: inline-block; filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.15)); }

.top-bar {
    height: 48px;
    flex-shrink: 0;
    background: var(--glass-white);
    backdrop-filter: blur(8px);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 0 16px;
    z-index: 2;
}

.status-left,
.status-center,
.status-right {
    display: flex;
    align-items: center;
}

.status-right {
    gap: 8px;
    background: rgba(255, 255, 255, 0.72);
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 0.95rem;
    white-space: nowrap;
    color: #293f6a;
}

.pink-battery {
    width: 46px;
    height: 14px;
    border-radius: 7px;
    background: linear-gradient(to right, var(--rose-300), var(--rose-500));
}

.taskbar {
    min-height: 62px;
    flex-shrink: 0;
    margin-top: auto;
    position: relative;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(238, 233, 255, 0.84)),
        var(--glass-strong);
    border-top: 1px solid rgba(255, 255, 255, 0.95);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    padding: 8px 14px;
    z-index: 20;
}

.tb-left,
.tb-center,
.tb-right {
    display: flex;
    align-items: center;
    min-width: 0;
}

.tb-left,
.tb-right {
    flex: 1;
    gap: 6px;
}

.tb-right {
    justify-content: flex-end;
}

.tb-center {
    gap: 6px;
    font-weight: bold;
    white-space: nowrap;
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.58);
    border: 1px solid rgba(255, 255, 255, 0.85);
}

#tb-clock {
    margin-left: 4px;
    font-size: 0.9rem;
    font-weight: 700;
    color: #3f3f79;
    letter-spacing: 0.5px;
}

.tb-left a,
.tb-right a {
    width: 36px;
    height: 36px;
    margin: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.92);
    opacity: 0.85;
    transition: transform 0.2s ease, opacity 0.2s ease, background 0.2s ease;
}

.tb-left a:hover,
.tb-right a:hover {
    opacity: 1;
    background: rgba(255, 255, 255, 0.72);
    transform: translateY(-1px) scale(1.03);
}

.tb-left a:active,
.tb-right a:active {
    transform: translateY(0) scale(0.98);
}

@media (max-width: 760px) {
    .taskbar {
        min-height: 58px;
        padding: 6px 8px;
        gap: 6px;
    }

    .tb-left,
    .tb-right {
        gap: 4px;
    }

    .tb-left a,
    .tb-right a {
        width: 32px;
        height: 32px;
        border-radius: 9px;
    }

    .tb-center {
        padding: 5px 8px;
        gap: 4px;
    }

    .tb-center .icon-xs {
        display: none;
    }

    #tb-clock {
        margin-left: 0;
        font-size: 0.82rem;
    }
}