
#desktop-root {
    opacity: 0;
    transition: opacity 0.6s ease;
}


body {
    background: url('/assets/icons/wall_aryan.jpg') no-repeat center center fixed;
    background-size: cover;
    margin: 0;
    padding: 0 !important;
    font-family: "Segoe UI", sans-serif;
    overflow: hidden;
}

.desktop {
    display: flex;
    flex-wrap: wrap;
    flex-direction: column; /* 关键：使图标从上往下排列 */
    align-content: flex-start; /* 关键：控制列的起始位置 */
    height: calc(100% - 46px); /* 允许下方排列 */
    padding: 20px !important;
    overflow-y: auto !important;
    max-height: calc(100vh - 61px);
    gap: 20px;
}

.icon {
    position: relative;
    max-width: 100px;
    max-height: 100px;
    text-align: center;
    user-select: none;
    flex-shrink: 0; /* 禁止被压缩 */
    transition: none !important; /* 关闭动画，防止不必要的位移 */
}

    .icon img {
        width: 64px;
        height: 64px;
        object-fit: contain;
        border-radius: 12px;
        padding: 6px;
        background-color: transparent;
        transition: background 0.3s;
    }

    .icon:hover img {
        background-color: rgba(255, 255, 255, 0.2);
    }

    .icon label {
        display: block;
        font-size: 12px;
        color: white;
        pointer-events: none;
    }

    /* 防止点击出现outline等影响布局 */
    .icon:focus,
    .icon img:focus {
        outline: none;
    }

.taskbar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 42px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(6px);
    display: flex;
    align-items: center;
    padding: 0 12px;
    box-shadow: 0 -1px 4px rgba(0, 0, 0, 0.3);
}

.start-button {
    width: 38px;
    height: 38px;
    background: rgba(255, 255, 255, 0.4);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    cursor: default;
}

    .start-button img {
        width: 28px;
        height: 28px;
        object-fit: contain;
    }

.start-menu h4 {
    margin-top: 0;
    font-size: 16px;
    color: #222;
    border-bottom: 1px solid #ccc;
    padding-bottom: 8px;
}

.start-menu ul {
    list-style: none;
    padding-left: 0;
    margin: 0;
}

.start-menu li {
    padding: 6px 0;
    color: #333;
    cursor: pointer;
}

    .start-menu li:hover {
        background: rgba(0, 0, 0, 0.05);
    }

.taskbar-app {
    user-select: none;
    -webkit-user-select: none;
}

.taskbar-app {
    transition: background 0.2s ease;
}

    .taskbar-app:hover {
        background-color: rgba(255, 255, 255, 0.25);
    }

.taskbar-app {
    background-color: rgba(255, 255, 255, 0.1);
    transition: background-color 0.2s ease, border 0.2s ease;
}

    .taskbar-app.active {
        background-color: rgba(255, 255, 255, 0.35);
        border: 1px solid rgba(255, 255, 255, 0.6);
    }

.folder-view {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.icon-tile {
    width: 80px;
    text-align: center;
    cursor: pointer;
    user-select: none;
}

    .icon-tile img {
        width: 100%;
        height: 100%;
        object-fit: contain;
        border-radius: 12px;
        padding: 6px;
        transition: background 0.3s;
        background-color: transparent;
    }

    .icon-tile:hover img {
        background-color: rgba(255, 255, 255, 0.2);
    }

    .icon-tile span {
        display: block;
        margin-top: 6px;
        font-size: 12px;
        color: #333;
    }


#taskbar-time {
    display: none;
}


#calendar-popup {
    position: fixed;
    bottom: 60px;
    right: 10px;
    background: #1e1e1e;
    color: white;
    padding: 14px;
    border-radius: 10px;
    display: none;
    box-shadow: 0 4px 20px rgba(0,0,0,0.4);
    width: 280px;
    font-family: 'Segoe UI', sans-serif;
    z-index: 9999;
}

    #calendar-popup header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 8px;
    }

    #calendar-popup button {
        background: none;
        border: none;
        color: white;
        font-size: 16px;
        cursor: pointer;
    }

    #calendar-popup h4 {
        margin: 0;
        font-size: 16px;
    }

    #calendar-popup .days {
        display: flex;
        grid-template-columns: repeat(7, 1fr); /* ✅ 一周7天 */
        flex-wrap: wrap;
        gap: 4px;
    }

.weekdays-header {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    font-weight: bold;
    padding-bottom: 5px;
    border-bottom: 1px solid #ddd;
}

.weekday {
    font-size: 14px;
    color: #333;
}

.day {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 5px;
}

    .day[style*="blue"] {
        background-color: #69c0ff !important;
    }

    .day[style*="green"] {
        background-color: #95de64 !important;
    }

.weekday-label {
    font-size: 12px;
    color: #999;
}

#calendar-popup .day {
    width: 26px;
    height: 26px;
    line-height: 26px;
    text-align: center;
    border-radius: 4px;
    background: #333;
    font-size: 13px;
}

#calendar-popup .today {
    background: #0078D7;
}


.company-info {
    position: absolute;
    top: 8px;
    left: 20px;
    font-family: "Microsoft YaHei", "Segoe UI", sans-serif;
    font-size: 14px;
    color: white;
    text-shadow: 0 0 2px #000;
    z-index: 9999;
}

.taskbar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 42px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    padding: 0 12px;
    box-shadow: 0 -1px 4px rgba(0, 0, 0, 0.2);
    border-top: 1px solid rgba(255,255,255,0.3);
}

.company-info {
    color: white;
    font-size: 12px;
    margin-right: auto;
    padding-left: 10px;
    line-height: 1.2;
    font-family: "Microsoft YaHei", "Segoe UI", sans-serif;
}

#taskbar-datetime {
    position: absolute;
    right: 10px;
    text-align: right;
    color: white;
    font-size: 12px;
    line-height: 1.2;
    cursor: default;
}

.weather-widget, .weather-widget * {
    user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
}

#start-menu {
    display: none;
    position: fixed;
    bottom: 60px;
    left: 50%;
    transform: translateX(-50%);
    width: 360px;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(18px);
    border-radius: 18px;
    padding: 20px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2);
    animation: fadeIn 0.2s ease-out;
}

    #start-menu ul {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 16px;
        list-style: none;
        padding: 0;
        margin: 0;
    }

    #start-menu li {
        display: flex;
        flex-direction: column;
        align-items: center;
        padding: 10px;
        border-radius: 10px;
        cursor: pointer;
        transition: background 0.2s;
    }

        #start-menu li:hover {
            background: rgba(255, 255, 255, 0.3);
        }

        #start-menu li img {
            width: 32px;
            height: 32px;
            margin-bottom: 6px;
        }

        #start-menu li span {
            font-size: 13px;
            color: #222;
            text-align: center;
        }

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateX(-50%) scale(0.95);
    }

    to {
        opacity: 1;
        transform: translateX(-50%) scale(1);
    }
}


.taskbar {
    z-index: 2000;
}

#start-menu {
    z-index: 3000;
}

#custom-context-menu {
    z-index: 5000;
}

.boot-overlay {
    z-index: 9999;
}


.resizer {
    position: absolute;
    z-index: 10;
    background: transparent;
}

    .resizer.n {
        top: -2px;
        left: 0;
        height: 5px;
        width: 100%;
        cursor: n-resize;
    }

    .resizer.s {
        bottom: -2px;
        left: 0;
        height: 5px;
        width: 100%;
        cursor: s-resize;
    }

    .resizer.e {
        top: 0;
        right: -2px;
        width: 5px;
        height: 100%;
        cursor: e-resize;
    }

    .resizer.w {
        top: 0;
        left: -2px;
        width: 5px;
        height: 100%;
        cursor: w-resize;
    }

    .resizer.ne {
        top: -2px;
        right: -2px;
        width: 10px;
        height: 10px;
        cursor: ne-resize;
    }

    .resizer.nw {
        top: -2px;
        left: -2px;
        width: 10px;
        height: 10px;
        cursor: nw-resize;
    }

    .resizer.se {
        bottom: -2px;
        right: -2px;
        width: 10px;
        height: 10px;
        cursor: se-resize;
    }

    .resizer.sw {
        bottom: -2px;
        left: -2px;
        width: 10px;
        height: 10px;
        cursor: sw-resize;
    }
#start-menu-login {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px;
  margin: 10px;
  border-radius: 16px;
  backdrop-filter: blur(10px);
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 4px 20px rgba(0,0,0,0.1);
  color: #000;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  font-size: 14px;
}
#start-menu-login img {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  margin-right: 8px;
}
#login-status {
  width: 8px;
  height: 8px;
  background: #cc8800;
  border-radius: 50%;
  display: inline-block;
  margin-left: 6px;
}
.window.login-type {
  background: transparent;
  border: none;
  box-shadow: none;
  overflow: visible;
  padding: 0;
}

.window.login-type iframe {
  border-radius: 12px;
  overflow: hidden;
  width: 100%;
  height: 100%;
}

#user-popup {
  position: fixed;
  z-index: 9999;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(12px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
  border-radius: 20px;
  width: 180px;
  padding: 14px;
  transition: opacity 0.2s ease, transform 0.2s ease;
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
}

#user-popup.show {
  top: -94px;
  left: 30px;
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

#user-popup::before {
  content: '';
  position: absolute;
  top: -10px;
  left: 24px;
  border: 10px solid transparent;
  border-bottom-color: rgba(255, 255, 255, 0.6);
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.1));
}

/* 内部文字样式 */
#user-popup .text-sm {
  color: #333;
  font-weight: 500;
  margin-bottom: 10px;
  font-size: 10pt;
}

#user-popup button {
  display: block;
  width: 100%;
  background: none;
  border: none;
  font-size: 14px;
  padding: 8px 0;
  border-radius: 12px;
  color: #e53935;
  transition: background 0.2s ease, color 0.2s ease;
  cursor: pointer;
}

#user-popup button:hover {
  background-color: #e53935;
  color: white;
}
.window-resize-corner {
  background: transparent;
}

