﻿:root {
  --desktop-wallpaper: radial-gradient(circle at top, #eef1f4 0%, #e1e6ec 55%, #d4dbe3 100%);
  --tablet-wallpaper: radial-gradient(circle at top, #eef1f4 0%, #e1e6ec 60%, #d4dbe3 100%);
  --login-wallpaper: radial-gradient(circle at top, #f1f4f8 0%, #e1e7f0 60%, #cfd7e4 100%);
  --desktop-accent: #6f7d94;
  --tablet-accent: #6f7d94;
  --tablet-icon-size: 78px;
  --tablet-home-top: 304px;
  --windows-logo: url("assets/icons/windows.png");
  --text: #0f1a2b;
  --muted: #5c6b84;
  --accent-glow: rgba(98, 150, 255, 0.28);
  --focus-ring: rgba(90, 150, 255, 0.5);
  --panel-alpha: 0.72;
  --panel-2-alpha: 0.84;
  --glass-alpha: 0.55;
  --glass-strong-alpha: 0.78;
  --panel: rgba(255, 255, 255, var(--panel-alpha));
  --panel-2: rgba(255, 255, 255, var(--panel-2-alpha));
  --glass: rgba(255, 255, 255, var(--glass-alpha));
  --glass-strong: rgba(255, 255, 255, var(--glass-strong-alpha));
  --border-glass: rgba(255, 255, 255, 0.55);
  --shadow-strong: 0 26px 60px rgba(10, 18, 35, 0.28);
  --shadow-soft: 0 14px 32px rgba(12, 20, 40, 0.16);
  --ui-blur: 12px;
  --ui-blur-strong: 22px;
  --ui-font-scale: 1;
  --danger: #ff6b6b;
}

@keyframes uiFadeIn {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes glowFloat {
  0% {
    transform: translateY(0) scale(1);
    opacity: 0.85;
  }
  50% {
    transform: translateY(-10px) scale(1.02);
    opacity: 1;
  }
  100% {
    transform: translateY(0) scale(1);
    opacity: 0.9;
  }
}

@keyframes windowPop {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes riseIn {
  from {
    opacity: 0;
    transform: translateY(10px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes panelFloat {
  0% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-6px);
  }
  100% {
    transform: translateY(0);
  }
}

@keyframes softPulse {
  0% {
    box-shadow: 0 0 0 0 rgba(98, 150, 255, 0.35);
  }
  70% {
    box-shadow: 0 0 0 12px rgba(98, 150, 255, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(98, 150, 255, 0);
  }
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  width: 100%;
  height: 100%;
  background: var(--login-wallpaper);
  background-size: cover;
  background-position: center;
  color: var(--text);
  overflow: hidden;
  font-size: calc(14px * var(--ui-font-scale));
}

html.nui-transparent,
body.nui-transparent {
  background: transparent !important;
}

.ui.nui-transparent {
  background: transparent !important;
}

.ui {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: transparent !important;
  animation: uiFadeIn 0.35s ease both;
}

.ui.open {
  display: flex;
}

.ui-shell {
  position: relative;
  width: min(1440px, 95vw);
  height: min(920px, 92vh);
  border-radius: 28px;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.92), rgba(255, 255, 255, 0.65));
  border: 1px solid var(--border-glass);
  backdrop-filter: blur(var(--ui-blur)) saturate(160%);
  box-shadow: var(--shadow-strong);
  isolation: isolate;
}

.ui-shell::before {
  content: "";
  position: absolute;
  top: -30%;
  left: -10%;
  right: -10%;
  height: 60%;
  background: radial-gradient(circle at 20% 20%, rgba(110, 160, 255, 0.35), transparent 55%),
    radial-gradient(circle at 80% 30%, rgba(255, 255, 255, 0.45), transparent 60%);
  opacity: 0.65;
  pointer-events: none;
  animation: panelFloat 18s ease-in-out infinite;
  z-index: 0;
}

.ui-shell::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.4), transparent 55%);
  opacity: 0.55;
  pointer-events: none;
  z-index: 0;
}

.ui-shell > * {
  z-index: 1;
}

.ui.web-fullscreen .ui-shell {
  width: 100vw;
  height: 100vh;
  border-radius: 0;
  border: none;
  box-shadow: none;
}

.ui.web-fullscreen .ui-close {
  display: none;
}

.ui.browser-fullscreen .ui-shell {
  width: 100vw;
  height: 100vh;
  border-radius: 0;
  border: none;
  box-shadow: none;
}

.ui.browser-fullscreen .network-bar {
  opacity: 0;
  pointer-events: none;
}

.ui.window-docked .network-bar {
  opacity: 0;
  pointer-events: none;
}

.ui-close {
  position: absolute;
  top: 12px;
  right: 14px;
  z-index: 20;
  background: rgba(255, 255, 255, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 10px;
  padding: 6px 10px;
  font-size: 12px;
  cursor: pointer;
}

.ui.mode-desktop .desktop {
  display: block;
}

.ui.mode-desktop .tablet {
  display: none;
}

.ui.mode-tablet .desktop {
  display: none;
}

.ui.mode-tablet .tablet {
  display: block;
}

.desktop {
  position: absolute;
  inset: 0;
  background: var(--desktop-wallpaper);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  font-family: "Segoe UI Variable", "Segoe UI", "Segoe UI Emoji", sans-serif;
  overflow: hidden;
  transition: background 0.45s ease;
}

.desktop::before {
  content: "";
  position: absolute;
  inset: -20% -10% auto -10%;
  height: 70%;
  background: radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.75), transparent 60%),
    radial-gradient(circle at 70% 20%, rgba(220, 232, 255, 0.7), transparent 55%);
  filter: blur(0px);
  opacity: 0.9;
  z-index: 0;
  pointer-events: none;
  animation: glowFloat 18s ease-in-out infinite;
}

.desktop::after {
  content: "";
  position: absolute;
  inset: auto -20% -30% -20%;
  height: 70%;
  background: radial-gradient(circle at 50% 60%, rgba(190, 210, 245, 0.65), transparent 65%);
  opacity: 0.9;
  z-index: 0;
  pointer-events: none;
  animation: glowFloat 22s ease-in-out infinite;
}

.desktop::before,
.desktop::after,
.tablet::before {
  display: none;
}

.network-bar {
  position: absolute;
  top: 18px;
  left: 24px;
  right: 24px;
  height: 54px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.75);
  backdrop-filter: blur(var(--ui-blur-strong)) saturate(160%);
  z-index: 3;
  box-shadow: 0 12px 30px rgba(24, 40, 70, 0.18);
}

.ui.mode-tablet .network-bar {
  display: none;
}

.network-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.network-logo {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--desktop-accent);
  color: #0b0f16;
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.5px;
}

.network-logo.has-image {
  color: transparent;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

.network-name {
  font-size: 14px;
  font-weight: 600;
}

.network-sub {
  font-size: 11px;
  color: var(--muted);
}

.network-user {
  font-size: 12px;
  color: var(--muted);
}

.desktop-icons {
  position: absolute;
  top: 86px;
  left: 18px;
  right: 18px;
  bottom: 90px;
  z-index: 2;
}

.desktop-icon {
  position: absolute;
  width: 96px;
  height: 110px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 10px 8px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid transparent;
  color: var(--text);
  cursor: pointer;
  transition: left 0.18s ease, top 0.18s ease, transform 0.18s ease, background 0.18s ease, border-color 0.18s ease, filter 0.18s ease;
  pointer-events: auto;
  user-select: none;
}

.desktop-icon .icon {
  width: 58px;
  height: 58px;
  border-radius: 18px;
  background: linear-gradient(160deg, rgba(74, 163, 255, 0.28), rgba(74, 163, 255, 0.08));
  color: #eaf4ff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  box-shadow: 0 10px 22px rgba(22, 38, 66, 0.2), inset 0 0 0 1px rgba(255, 255, 255, 0.16);
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
}

.desktop-icon .label {
  font-size: 12px;
  text-align: center;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(10, 18, 32, 0.24);
  color: #f7fbff;
  line-height: 1.2;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.28);
}

.desktop-icon:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.24);
  transform: translateY(-2px);
}

.desktop-icon.dragging {
  z-index: 8;
  transition: none;
  transform: scale(1.05);
  filter: drop-shadow(0 18px 28px rgba(6, 12, 24, 0.28));
}

.desktop-icon .icon.has-app-icon {
  background-color: transparent;
  box-shadow: none;
  filter: drop-shadow(0 12px 18px rgba(6, 12, 24, 0.22));
}

.desktop-windows {
  position: absolute;
  top: 86px;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 0 24px 120px;
  z-index: 2;
  pointer-events: none;
}

.snap-overlay {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  display: none;
}

.snap-overlay.active {
  display: block;
}

.snap-zone {
  position: absolute;
  opacity: 0;
  border-radius: 16px;
  border: 1px solid rgba(120, 180, 255, 0.4);
  background: rgba(80, 140, 220, 0.18);
  transition: opacity 0.12s ease;
}

.snap-zone.left {
  top: 0;
  bottom: 0;
  left: 0;
  width: 50%;
}

.snap-zone.right {
  top: 0;
  bottom: 0;
  right: 0;
  width: 50%;
}

.snap-zone.max {
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
}

.snap-overlay.show-left .snap-zone.left {
  opacity: 1;
}

.snap-overlay.show-right .snap-zone.right {
  opacity: 1;
}

.snap-overlay.show-max .snap-zone.max {
  opacity: 1;
}

.snap-layout {
  position: absolute;
  top: 18px;
  left: 50%;
  transform: translateX(-50%);
  width: 220px;
  height: 120px;
  padding: 10px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(var(--ui-blur-strong));
  z-index: 5;
  display: none;
  pointer-events: none;
}

.snap-layout.show {
  display: block;
}

.snap-layout-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 8px;
  height: 100%;
}

.snap-cell {
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
}

.snap-cell.max {
  grid-column: 1 / span 2;
}

.snap-layout.show-left .snap-cell.left,
.snap-layout.show-right .snap-cell.right,
.snap-layout.show-max .snap-cell.max {
  background: rgba(120, 180, 255, 0.28);
  border-color: rgba(120, 180, 255, 0.55);
}

.desktop-window {
  position: absolute;
  width: 560px;
  height: 380px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(245, 248, 255, 0.74));
  border: 1px solid var(--border-glass);
  border-radius: 22px;
  box-shadow: 0 28px 58px rgba(10, 18, 35, 0.22);
  overflow: hidden;
  backdrop-filter: blur(var(--ui-blur)) saturate(160%);
  display: flex;
  flex-direction: column;
  pointer-events: auto;
  animation: riseIn 0.25s ease;
  transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.desktop-window::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.38), transparent 18%),
    radial-gradient(circle at top left, rgba(140, 186, 255, 0.16), transparent 28%);
  pointer-events: none;
  opacity: 0.85;
  z-index: 0;
}

.desktop-window > * {
  position: relative;
  z-index: 1;
}

.resize-handle {
  position: absolute;
  z-index: 6;
}

.resize-handle.n,
.resize-handle.s {
  left: 16px;
  right: 16px;
  height: 10px;
}

.resize-handle.n {
  top: -4px;
  cursor: ns-resize;
}

.resize-handle.s {
  bottom: -4px;
  cursor: ns-resize;
}

.resize-handle.e,
.resize-handle.w {
  top: 16px;
  bottom: 16px;
  width: 10px;
}

.resize-handle.e {
  right: -4px;
  cursor: ew-resize;
}

.resize-handle.w {
  left: -4px;
  cursor: ew-resize;
}

.resize-handle.ne,
.resize-handle.nw,
.resize-handle.se,
.resize-handle.sw {
  width: 14px;
  height: 14px;
}

.resize-handle.ne {
  top: -5px;
  right: -5px;
  cursor: nesw-resize;
}

.resize-handle.nw {
  top: -5px;
  left: -5px;
  cursor: nwse-resize;
}

.resize-handle.se {
  bottom: -5px;
  right: -5px;
  cursor: nwse-resize;
}

.resize-handle.sw {
  bottom: -5px;
  left: -5px;
  cursor: nesw-resize;
}

.desktop-window.docked-left {
  border-radius: 16px 0 0 16px;
}

.desktop-window.docked-right {
  border-radius: 0 16px 16px 0;
}

.desktop-window.docked-custom {
  border-radius: 16px;
}

.desktop-window.docked-max {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  border-radius: 0;
  z-index: 2000;
}

.desktop-window.minimized {
  display: none;
}

.window-header {
  height: 46px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 0 0 16px;
  background: rgba(255, 255, 255, 0.5);
  border-bottom: 1px solid rgba(255, 255, 255, 0.5);
  cursor: move;
  z-index: 4;
  overflow: visible;
}

.window-title-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.window-title-stack {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.window-app-icon {
  width: 18px;
  height: 18px;
  border-radius: 5px;
  background: linear-gradient(135deg, rgba(74, 163, 255, 0.42), rgba(74, 163, 255, 0.1));
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  flex: 0 0 auto;
}

.window-app-icon.has-app-icon {
  background-color: transparent;
  background-size: contain;
  box-shadow: none;
}

.window-title {
  font-size: 12px;
  letter-spacing: 0.2px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.window-title-sub {
  font-size: 10px;
  line-height: 1.2;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.window-actions {
  display: flex;
  gap: 0;
}

.window-action-group {
  position: relative;
  display: flex;
}

.window-action-group.snap-open {
  z-index: 14;
}

.window-actions button {
  width: 44px;
  height: 38px;
  border-radius: 0;
  border: none;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  font-size: 12px;
  transition: transform 0.2s ease, background 0.2s ease;
}

.window-actions button span {
  pointer-events: none;
}

.window-actions button:hover {
  background: rgba(16, 24, 40, 0.08);
}

.window-actions button[data-action="close"] {
  border-top-right-radius: 18px;
}

.window-actions button[data-action="close"]:hover {
  background: rgba(224, 67, 54, 0.9);
  color: #fff;
}

.window-snap-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 4px;
  width: 316px;
  padding: 12px;
  border-radius: 16px;
  background: rgba(248, 250, 255, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.78);
  box-shadow: 0 20px 40px rgba(10, 18, 35, 0.18);
  backdrop-filter: blur(var(--ui-blur-strong));
  opacity: 0;
  pointer-events: none;
  transform: translateY(6px);
  transition: opacity 0.16s ease, transform 0.16s ease;
  z-index: 9;
  cursor: default;
}

.window-action-group.snap-open .window-snap-menu {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.window-snap-layouts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.snap-layout-option {
  position: relative;
  height: 74px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.78);
  background: rgba(255, 255, 255, 0.54);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.42);
  overflow: hidden;
}

.snap-layout-option::before {
  content: "";
  position: absolute;
  inset: 7px;
  border-radius: 10px;
  border: 1px solid rgba(10, 18, 35, 0.06);
  background: rgba(18, 27, 46, 0.05);
}

.window-snap-menu button {
  width: auto;
  height: auto;
  min-height: 0;
  padding: 0;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.92);
  color: var(--text);
  font-size: 0;
  font-weight: 600;
  position: absolute;
  z-index: 1;
  cursor: pointer;
}

.window-snap-menu button:hover,
.window-snap-menu button:focus-visible {
  background: rgba(115, 167, 255, 0.32);
  border-color: rgba(115, 167, 255, 0.72);
  outline: none;
}

.window-snap-zone-button.z-max {
  inset: 10px;
}

.window-snap-zone-button.z-left,
.window-snap-zone-button.z-right {
  top: 10px;
  bottom: 10px;
  width: calc(50% - 13px);
}

.window-snap-zone-button.z-left {
  left: 10px;
}

.window-snap-zone-button.z-right {
  right: 10px;
}

.window-snap-zone-button.z-left-wide,
.window-snap-zone-button.z-right-wide {
  top: 10px;
  bottom: 10px;
  width: calc(50% - 13px);
}

.window-snap-zone-button.z-left-wide {
  left: 10px;
}

.window-snap-zone-button.z-right-wide {
  right: 10px;
}

.window-snap-zone-button.z-top-left,
.window-snap-zone-button.z-top-right,
.window-snap-zone-button.z-bottom-left,
.window-snap-zone-button.z-bottom-right {
  width: calc(50% - 13px);
  height: calc(50% - 13px);
}

.window-snap-zone-button.z-top-left {
  top: 10px;
  left: 10px;
}

.window-snap-zone-button.z-top-right {
  top: 10px;
  right: 10px;
}

.window-snap-zone-button.z-bottom-left {
  bottom: 10px;
  left: 10px;
}

.window-snap-zone-button.z-bottom-right {
  bottom: 10px;
  right: 10px;
}

.snap-layout-option.left-stack .window-snap-zone-button.z-left-wide,
.snap-layout-option.right-stack .window-snap-zone-button.z-right-wide {
  width: calc(52% - 13px);
}

.snap-layout-option.left-stack .window-snap-zone-button.z-top-right,
.snap-layout-option.left-stack .window-snap-zone-button.z-bottom-right,
.snap-layout-option.right-stack .window-snap-zone-button.z-top-left,
.snap-layout-option.right-stack .window-snap-zone-button.z-bottom-left {
  width: calc(48% - 13px);
}

.window-snap-zone-button.z-left-third,
.window-snap-zone-button.z-center-third,
.window-snap-zone-button.z-right-third {
  top: 10px;
  bottom: 10px;
  width: calc(33.333% - 12px);
}

.window-snap-zone-button.z-left-third {
  left: 10px;
}

.window-snap-zone-button.z-center-third {
  left: 50%;
  transform: translateX(-50%);
}

.window-snap-zone-button.z-right-third {
  right: 10px;
}

.window-content {
  flex: 1;
  padding: 14px;
  overflow: auto;
  background: rgba(252, 253, 255, 0.72);
  display: flex;
  flex-direction: column;
  min-height: 0;
  z-index: 1;
}

.taskbar {
  position: absolute;
  left: 50%;
  bottom: 10px;
  transform: translateX(-50%);
  padding: 8px 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: rgba(246, 248, 253, 0.58);
  border: 1px solid rgba(255, 255, 255, 0.38);
  border-radius: 22px;
  backdrop-filter: blur(var(--ui-blur-strong)) saturate(160%);
  box-shadow: 0 18px 42px rgba(12, 20, 38, 0.2);
  z-index: 1000;
  transition: transform 0.3s ease, opacity 0.3s ease, background 0.3s ease;
}

.taskbar::before {
  content: none;
}

.taskbar-main,
.taskbar-tray {
  display: flex;
  align-items: center;
  gap: 10px;
}

.taskbar-hover {
  position: absolute;
  left: 50%;
  bottom: 0;
  width: min(520px, 70vw);
  height: 24px;
  transform: translateX(-50%);
  z-index: 999;
  display: none;
}

.ui.window-docked .taskbar {
  transform: translateX(-50%) translateY(140%);
  opacity: 0;
  pointer-events: none;
}

.ui.window-docked .taskbar-hover {
  display: block;
}

.ui.window-docked .taskbar-hover:hover ~ .taskbar,
.ui.window-docked .taskbar:hover {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.taskbar.left {
  left: 18px;
  transform: none;
}

.taskbar-start {
  position: relative;
  width: 42px;
  height: 42px;
  padding: 0;
  font-size: 0;
  background: rgba(255, 255, 255, 0.12);
  border: none;
  color: var(--text);
  border-radius: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12);
  transition: background 0.2s ease, box-shadow 0.2s ease;
}

.taskbar-start::before,
.taskbar-start::after {
  content: none;
}

.taskbar-start:hover {
  background: rgba(255, 255, 255, 0.42);
}

.taskbar-search {
  min-width: 168px;
  height: 42px;
  padding: 0 14px;
  border-radius: 14px;
  border: none;
  background: rgba(255, 255, 255, 0.34);
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
}

.taskbar-search:hover {
  background: rgba(255, 255, 255, 0.46);
}

.taskbar-search-icon {
  width: 20px;
  height: 20px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.58);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  color: var(--text);
}

.taskbar-search-label {
  font-size: 12px;
  font-weight: 600;
}

.taskbar-start-icon {
  width: 26px;
  height: 26px;
  background-image: var(--windows-logo);
  background-size: 115%;
  background-repeat: no-repeat;
  background-position: center;
}

.taskbar-apps {
  display: flex;
  gap: 6px;
  align-items: center;
}

.task-icon {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  border: none;
  background: rgba(255, 255, 255, 0.12);
  color: var(--text);
  cursor: pointer;
  font-size: 12px;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.12);
  background-size: 115%;
  background-position: center;
  background-repeat: no-repeat;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  position: relative;
}

.task-icon:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 22px rgba(0, 0, 0, 0.18);
  z-index: 2;
}

.has-app-icon {
  color: transparent;
  text-shadow: none;
}

.has-app-icon span {
  color: transparent;
}

.task-icon.active {
  background: rgba(255, 255, 255, 0.34);
  box-shadow: 0 12px 22px rgba(0, 0, 0, 0.14);
}

.task-icon.active::after,
.taskbar-start.active::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 4px;
  transform: translateX(-50%);
  width: 16px;
  height: 3px;
  border-radius: 999px;
  background: var(--desktop-accent);
}

.taskbar-clock {
  min-width: 96px;
  font-size: 11px;
  color: var(--muted);
  padding: 7px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.22);
  text-align: right;
  line-height: 1.2;
}

.taskbar-clock .taskbar-time {
  display: block;
  font-size: 12px;
  font-weight: 700;
  color: var(--text);
}

.taskbar-clock .taskbar-date {
  display: block;
  font-size: 10px;
}

.taskbar-tray-icons {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 10px;
  height: 42px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.22);
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
}

.app-hidden {
  display: none !important;
}

.start-menu {
  position: absolute;
  left: 50%;
  bottom: 82px;
  transform: translateX(-50%);
  width: 620px;
  max-width: calc(100% - 80px);
  background: rgba(245, 248, 253, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.6);
  border-radius: 26px;
  padding: 18px;
  box-shadow: 0 32px 60px rgba(12, 20, 38, 0.22);
  backdrop-filter: blur(var(--ui-blur-strong)) saturate(140%);
  display: none;
  z-index: 1100;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.start-menu.open {
  display: block;
}

.start-header {
  margin-bottom: 16px;
}

.start-search input {
  width: 100%;
  border-radius: 16px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.82);
  color: var(--text);
}

.start-section {
  margin-top: 10px;
}

.start-section-title {
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
}

.start-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

.start-tile {
  height: 92px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.8);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  color: var(--text);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.start-tile:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 24px rgba(10, 18, 35, 0.12);
  background: rgba(255, 255, 255, 0.86);
}

.start-tile .tile-icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: linear-gradient(160deg, rgba(120, 180, 255, 0.45), rgba(120, 180, 255, 0.15));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  background-size: 115%;
  background-position: center;
  background-repeat: no-repeat;
}

.start-tile .tile-label {
  font-size: 11px;
}

.start-recommendations {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.start-rec {
  background: rgba(255, 255, 255, 0.68);
  border: 1px solid rgba(255, 255, 255, 0.75);
  border-radius: 16px;
  padding: 10px 12px;
  display: flex;
  justify-content: space-between;
  font-size: 12px;
}

.start-footer {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.6);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--muted);
}

.start-power {
  background: rgba(255, 255, 255, 0.72);
  border: none;
  color: var(--text);
  padding: 8px 12px;
  border-radius: 12px;
  font-size: 12px;
  cursor: pointer;
}

.start-user {
  font-weight: 600;
  color: var(--text);
}

.lock-screen,
.login-screen {
  position: absolute;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  background: var(--login-wallpaper);
  background-size: cover;
  background-position: center;
  overflow: hidden;
  backdrop-filter: none;
  z-index: 40;
}

.lock-screen::before,
.login-screen::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(140deg, rgba(246, 248, 252, 0.86), rgba(232, 238, 246, 0.8));
  opacity: 0.78;
  backdrop-filter: blur(var(--ui-blur-strong)) saturate(150%);
  z-index: 0;
}

.lock-screen > *,
.login-screen > * {
  position: relative;
  z-index: 1;
}

.desktop.auth-active .taskbar,
.desktop.auth-active .desktop-icons,
.desktop.auth-active .desktop-windows,
.desktop.auth-active .start-menu,
.desktop.auth-active .snap-overlay,
.desktop.auth-active .snap-layout,
.desktop.auth-active .cursor {
  visibility: hidden;
  pointer-events: none;
}

.ui.auth-active .network-bar,
.ui.auth-active .taskbar,
.ui.auth-active .desktop-icons,
.ui.auth-active .desktop-windows,
.ui.auth-active .start-menu,
.ui.auth-active .snap-overlay,
.ui.auth-active .snap-layout,
.ui.auth-active .cursor {
  visibility: hidden;
  pointer-events: none;
}

.lock-screen.show {
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-align: center;
}

.lock-time {
  font-size: 64px;
  font-weight: 600;
}

.lock-date {
  font-size: 16px;
  color: var(--muted);
}

.lock-hint {
  margin-top: 12px;
  font-size: 13px;
  color: var(--muted);
}

.login-screen.show {
  display: flex;
}

.login-card {
  width: min(360px, 90vw);
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.94), rgba(255, 255, 255, 0.75));
  border: 1px solid var(--border-glass);
  border-radius: 20px;
  padding: 20px;
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(var(--ui-blur)) saturate(160%);
  display: flex;
  flex-direction: column;
  gap: 12px;
  animation: riseIn 0.45s ease both;
  position: relative;
}

.login-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 20px;
  background: radial-gradient(circle at top left, rgba(120, 170, 255, 0.25), transparent 60%);
  pointer-events: none;
  opacity: 0.7;
  z-index: 0;
}

.login-card > * {
  position: relative;
  z-index: 1;
}

.login-title {
  font-size: 18px;
  font-weight: 600;
}

.login-mode {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.login-mode-buttons {
  display: flex;
  gap: 8px;
}

.login-mode-btn {
  flex: 1;
  padding: 8px 10px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  background: rgba(255, 255, 255, 0.7);
  color: var(--text);
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.login-mode-btn.active {
  background: linear-gradient(140deg, var(--desktop-accent), #8cb5ff);
  color: #0b0f16;
  box-shadow: 0 10px 20px rgba(90, 130, 220, 0.3);
  transform: translateY(-1px);
}

.login-label {
  font-size: 12px;
  color: var(--muted);
}

.login-input {
  width: 100%;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: rgba(255, 255, 255, 0.95);
  transition: border 0.2s ease, box-shadow 0.2s ease;
}

.login-password-row {
  display: flex;
  gap: 8px;
  align-items: center;
}

.login-toggle {
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.98);
  color: var(--text);
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
}

.login-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.login-remember {
  font-size: 12px;
  color: var(--muted);
  display: flex;
  gap: 6px;
  align-items: center;
}

.login-submit {
  background: linear-gradient(140deg, var(--desktop-accent), #9dc3ff);
  border: none;
  color: #0b0f16;
  padding: 9px 16px;
  border-radius: 12px;
  cursor: pointer;
  font-weight: 600;
  box-shadow: 0 12px 24px rgba(88, 130, 220, 0.28);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.login-submit:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 30px rgba(88, 130, 220, 0.35);
}

.login-error {
  font-size: 12px;
  color: #d64545;
  min-height: 14px;
}

.tablet {
  position: absolute;
  inset: 0;
  background: var(--tablet-wallpaper);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  font-family: "SF Pro Display", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  overflow: hidden;
  transition: background 0.45s ease;
}

.tablet::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 10% 12%, rgba(255, 255, 255, 0.22), transparent 36%),
    radial-gradient(circle at 82% 20%, rgba(109, 186, 255, 0.18), transparent 32%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0));
  opacity: 0.92;
  pointer-events: none;
  animation: glowFloat 20s ease-in-out infinite;
}

.tablet::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), transparent 22%),
    linear-gradient(0deg, rgba(7, 10, 18, 0.1), transparent 26%);
  pointer-events: none;
}

.tablet-statusbar {
  position: absolute;
  top: 18px;
  left: 28px;
  right: 28px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 14px;
  font-size: 13px;
  letter-spacing: 0.2px;
  color: #ffffff;
  z-index: 6;
}

.tablet-status-left,
.tablet-status-right,
.tablet-status-center {
  display: flex;
  align-items: center;
  gap: 10px;
}

.tablet-status-right {
  justify-content: flex-end;
}

.tablet-status-title {
  font-size: 15px;
  font-weight: 700;
}

.tablet-status-day {
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(var(--ui-blur-strong));
}

.tablet-status-pill,
.tablet-logout {
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.16);
  color: #ffffff;
  padding: 10px 14px;
  border-radius: 16px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 12px 24px rgba(12, 18, 30, 0.18);
  backdrop-filter: blur(var(--ui-blur-strong));
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.tablet-status-pill:hover,
.tablet-logout:hover,
.tablet-profile-primary:hover,
.tablet-profile-action:hover,
.tablet-app-action:hover,
.tablet-sidebar-btn:hover,
.tablet-control-tile:hover,
.tablet-modal-close:hover,
.tablet-segment-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 28px rgba(12, 18, 30, 0.24);
  background: rgba(255, 255, 255, 0.24);
  border-color: rgba(255, 255, 255, 0.32);
}

.tablet-status-right {
  gap: 12px;
}

.tablet-status-icons {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px;
  border-radius: 18px;
  background: rgba(15, 22, 34, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(var(--ui-blur-strong));
}

.tablet-time-chip,
.tablet-status {
  padding: 8px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.1);
  font-weight: 600;
}

.tablet-hero {
  position: absolute;
  top: 74px;
  left: 28px;
  right: 28px;
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(270px, 320px);
  gap: 18px;
  z-index: 3;
}

.tablet-widgets {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  align-content: start;
}

.tablet-widget {
  min-height: 136px;
  background: rgba(18, 28, 44, 0.26);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 28px;
  padding: 18px 18px 16px;
  color: #fff;
  backdrop-filter: blur(var(--ui-blur-strong));
  box-shadow: 0 20px 36px rgba(10, 16, 28, 0.26);
  position: relative;
  cursor: pointer;
  overflow: hidden;
}

.tablet-widget::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.12), transparent 58%);
  pointer-events: none;
}

.tablet-widget[data-widget="clock"] {
  grid-column: 1 / span 2;
}

.tablet-widget.large {
  min-height: 168px;
}

.widget-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  border: none;
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  font-size: 14px;
  cursor: pointer;
  z-index: 1;
}

.widget-time {
  margin-top: 10px;
  font-size: 48px;
  font-weight: 700;
  letter-spacing: -1.2px;
}

.widget-date {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.85);
}

.widget-title {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.9px;
  color: rgba(255, 255, 255, 0.72);
}

.widget-body {
  margin-top: 12px;
  font-size: 14px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.9);
}

.widget-subline,
.widget-mail-count {
  margin-top: 8px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.72);
}

.tablet-profile-card {
  min-height: 322px;
  border-radius: 30px;
  padding: 22px;
  background: rgba(16, 24, 38, 0.32);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  backdrop-filter: blur(var(--ui-blur-strong));
  box-shadow: 0 22px 42px rgba(10, 16, 28, 0.28);
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.tablet-profile-kicker {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1px;
  opacity: 0.72;
}

.tablet-profile-name {
  font-size: 30px;
  font-weight: 700;
  line-height: 1.05;
}

.tablet-profile-meta {
  font-size: 14px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.8);
}

.tablet-profile-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.tablet-profile-action,
.tablet-profile-primary {
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  border-radius: 18px;
  padding: 11px 14px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  backdrop-filter: blur(var(--ui-blur-strong));
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.tablet-profile-primary {
  margin-top: auto;
  justify-content: center;
}

.tablet-home {
  position: absolute;
  top: var(--tablet-home-top);
  left: 28px;
  right: 28px;
  bottom: 112px;
  padding: 26px 30px 24px;
  display: block;
  z-index: 2;
  border-radius: 34px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(calc(var(--ui-blur) * 0.7));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.tablet-icon {
  position: absolute;
  width: calc(var(--tablet-icon-size) + 18px);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 10px;
  color: #ffffff;
  font-size: 12px;
  cursor: pointer;
  background: transparent;
  border: none;
  touch-action: none;
  transition: left 0.18s ease, top 0.18s ease, transform 0.18s ease, filter 0.18s ease;
}

.tablet-icon.dragging {
  z-index: 8;
  transition: none;
  transform: scale(1.06);
  filter: drop-shadow(0 18px 28px rgba(6, 12, 24, 0.3));
}

.tablet-icon-face {
  width: var(--tablet-icon-size);
  height: var(--tablet-icon-size);
  border-radius: 26px;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.36), rgba(255, 255, 255, 0.1));
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 18px 30px rgba(10, 18, 28, 0.34), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  color: #ffffff;
  background-size: cover;
  background-position: center;
}

.tablet-icon-label {
  max-width: 116px;
  font-size: 12px;
  letter-spacing: 0.2px;
  text-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
}

.tablet-dock-shell {
  position: absolute;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  z-index: 6;
}

.tablet-dock {
  display: flex;
  gap: 16px;
  padding: 14px 22px;
  background: rgba(18, 26, 40, 0.34);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 30px;
  backdrop-filter: blur(calc(var(--ui-blur-strong) + 2px));
  box-shadow: 0 24px 48px rgba(10, 16, 28, 0.34);
  max-width: calc(100vw - 80px);
  overflow-x: auto;
}

.tablet-page-dots {
  position: absolute;
  bottom: 116px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 4;
}

.tablet-page-dots .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
}

.tablet-page-dots .dot.active {
  width: 18px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.85);
}

.tablet-dock-icon {
  width: 62px;
  height: 62px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.18);
  color: #ffffff;
  font-size: 12px;
  cursor: pointer;
  box-shadow: 0 14px 26px rgba(10, 16, 28, 0.34);
  display: flex;
  align-items: center;
  justify-content: center;
  background-size: cover;
  background-position: center;
}

.tablet-dock-icon span {
  font-weight: 600;
}

.tablet-home-indicator {
  width: 140px;
  height: 5px;
  background: rgba(255, 255, 255, 0.6);
  border-radius: 999px;
  opacity: 0.8;
  border: none;
  cursor: pointer;
}

.tablet-app {
  position: absolute;
  top: 82px;
  left: 28px;
  right: 28px;
  bottom: 102px;
  display: none;
  z-index: 5;
}

.tablet-app.active {
  display: block;
  animation: windowPop 0.26s ease both;
}

.tablet-app-window {
  height: 100%;
  border-radius: 38px;
  overflow: hidden;
  background: rgba(248, 250, 255, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.5);
  box-shadow: 0 32px 54px rgba(10, 16, 28, 0.34);
  backdrop-filter: blur(calc(var(--ui-blur-strong) + 4px));
}

.tablet-app-topbar {
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 18px 0 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.48);
  background: rgba(255, 255, 255, 0.44);
}

.tablet-app-topbar-left,
.tablet-app-topbar-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.tablet-app-titlewrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.tablet-app-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
}

.tablet-app-subtitle {
  font-size: 12px;
  color: var(--muted);
}

.tablet-app-action {
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.72);
  color: var(--text);
  padding: 10px 14px;
  border-radius: 16px;
  cursor: pointer;
  font-weight: 600;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.tablet-shell {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  height: calc(100% - 72px);
}

.tablet-sidebar {
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: rgba(255, 255, 255, 0.38);
  border-right: 1px solid rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(var(--ui-blur-strong));
}

.tablet-sidebar-title {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: var(--muted);
}

.tablet-sidebar-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.tablet-sidebar-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.6);
  background: rgba(255, 255, 255, 0.74);
  cursor: pointer;
  text-align: left;
  color: var(--text);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.tablet-sidebar-btn.active {
  background: linear-gradient(135deg, rgba(98, 150, 255, 0.22), rgba(98, 150, 255, 0.08));
  border-color: rgba(98, 150, 255, 0.34);
  box-shadow: 0 14px 26px rgba(98, 150, 255, 0.18);
}

.tablet-sidebar-icon {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(135deg, var(--tablet-accent), #9fc4ff);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.tablet-content {
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: rgba(255, 255, 255, 0.24);
}

.tablet-app-body {
  flex: 1;
  min-height: 0;
  padding: 22px;
  overflow: auto;
}

.tablet-modal {
  position: absolute;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 10;
}

.tablet-modal.show {
  display: flex;
}

.tablet-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 12, 18, 0.3);
  backdrop-filter: blur(var(--ui-blur-strong));
}

.tablet-modal-card {
  position: relative;
  z-index: 1;
  width: min(720px, 92%);
  background: rgba(246, 248, 253, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 28px;
  padding: 20px;
  box-shadow: 0 32px 64px rgba(10, 18, 30, 0.34);
  backdrop-filter: blur(calc(var(--ui-blur-strong) + 4px));
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.tablet-modal-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.tablet-modal-kicker {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--muted);
}

.tablet-modal-card h3 {
  margin: 4px 0 0;
}

.tablet-modal-close {
  border: 1px solid rgba(255, 255, 255, 0.7);
  background: rgba(255, 255, 255, 0.7);
  color: var(--text);
  padding: 10px 14px;
  border-radius: 16px;
  cursor: pointer;
  font-weight: 700;
}

.tablet-control-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.tablet-control-tile {
  min-height: 116px;
  border: 1px solid rgba(255, 255, 255, 0.66);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.7);
  padding: 16px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  color: var(--text);
  cursor: pointer;
  text-align: left;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.tablet-control-tile span,
.tablet-control-tile small {
  color: var(--muted);
}

.tablet-control-tile strong {
  font-size: 18px;
}

.tablet-control-tile.danger strong {
  color: var(--danger);
}

.tablet-control-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.tablet-control-segment {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.62);
}

.tablet-segment-btn {
  min-width: 48px;
  border: none;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--text);
  padding: 10px 12px;
  font-weight: 700;
  cursor: pointer;
}

.tablet-segment-btn.active {
  background: linear-gradient(135deg, var(--tablet-accent), #9dc3ff);
  color: #fff;
}

.tablet-control-summary {
  flex: 1;
  min-width: 220px;
  padding: 12px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.62);
  border: 1px solid rgba(255, 255, 255, 0.62);
  color: var(--muted);
}

.app-header {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px;
  background: var(--panel);
  border-radius: 16px;
  border: 1px solid var(--border-glass);
  box-shadow: var(--shadow-soft);
  animation: riseIn 0.35s ease both;
}

.app-header h2 {
  margin: 0 0 4px 0;
  font-size: 20px;
}

.app-header p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

.app-section {
  margin-top: 14px;
  padding: 12px 14px;
  background: var(--panel);
  border-radius: 16px;
  border: 1px solid var(--border-glass);
  box-shadow: var(--shadow-soft);
  animation: riseIn 0.4s ease both;
}

.list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  overflow: auto;
}

.list-item {
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 12px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 4px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border 0.2s ease;
  animation: riseIn 0.35s ease both;
}

.list-item.active {
  border-color: rgba(74, 163, 255, 0.6);
  box-shadow: 0 0 0 1px rgba(74, 163, 255, 0.4) inset;
}

.list-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.12);
}

.app-error {
  padding: 12px;
  border-radius: 10px;
  background: rgba(255, 107, 107, 0.12);
  border: 1px solid rgba(255, 107, 107, 0.35);
  color: #a12b2b;
  font-size: 12px;
}

button {
  background: linear-gradient(135deg, var(--desktop-accent), #9cc4ff);
  color: #0b0f16;
  border: none;
  padding: 9px 14px;
  border-radius: 12px;
  cursor: pointer;
  font-weight: 600;
  box-shadow: 0 10px 20px rgba(88, 130, 220, 0.25);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

button.secondary {
  background: rgba(255, 255, 255, 0.6);
  color: var(--text);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.12);
}

button.danger {
  background: linear-gradient(135deg, #ff6b6b, #ffa6a6);
  color: #0b0f16;
}

button:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 28px rgba(88, 130, 220, 0.3);
}

button:active {
  transform: translateY(1px);
}

input,
textarea,
select {
  width: 100%;
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 12px;
  color: var(--text);
  padding: 9px 12px;
  outline: none;
  transition: border 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

input:focus,
textarea:focus,
select:focus {
  border-color: var(--focus-ring);
  box-shadow: 0 0 0 3px rgba(90, 150, 255, 0.2);
  background: rgba(255, 255, 255, 0.98);
}

textarea {
  min-height: 120px;
  resize: none;
}

.row {
  display: flex;
  gap: 10px;
}

.browser {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 0;
  flex: 1;
  animation: riseIn 0.4s ease both;
}

.window-browser .window-content {
  overflow: hidden;
}

.window-browser .browser {
  height: 100%;
}

.browser-results {
  position: absolute;
  inset: 10px;
  background: linear-gradient(180deg, rgba(15, 22, 35, 0.96), rgba(10, 16, 26, 0.98));
  border: 1px solid rgba(117, 145, 255, 0.14);
  border-radius: 12px;
  padding: 12px;
  overflow: auto;
  display: block;
  z-index: 2;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.22);
}

.browser-result-card {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid rgba(117, 145, 255, 0.1);
  background: linear-gradient(180deg, rgba(20, 29, 44, 0.98), rgba(14, 20, 31, 0.98));
}

.browser-result-card.is-video {
  min-height: 120px;
}

.browser-result-thumb {
  width: 220px;
  min-width: 220px;
  aspect-ratio: 16 / 9;
  border-radius: 14px;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.14);
  border: 1px solid rgba(15, 23, 42, 0.08);
}

.browser-result-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.browser-result-body {
  min-width: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.browser-result-meta {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}

.browser-results:empty {
  display: none;
}

.browser-bar {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: var(--shadow-soft);
  transition: box-shadow 0.2s ease;
}

.browser-query {
  flex: 1;
  min-width: 0;
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: rgba(255, 255, 255, 0.96);
  color: var(--text);
}

.browser-query:focus {
  outline: none;
  border-color: rgba(86, 129, 255, 0.5);
  box-shadow: 0 0 0 3px rgba(86, 129, 255, 0.12);
}

.browser-tabs {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.75);
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: var(--shadow-soft);
}

.browser-tabs-list {
  display: flex;
  gap: 8px;
  flex: 1;
  overflow: auto;
  padding-bottom: 2px;
}

.browser-tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 12px 12px 8px 8px;
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(15, 23, 42, 0.08);
  color: var(--text);
  font-size: 12px;
  cursor: pointer;
  min-width: 110px;
  max-width: 200px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.browser-tab.active {
  background: #ffffff;
  border-color: rgba(120, 170, 255, 0.35);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.12);
}

.browser-tab:hover {
  transform: translateY(-1px);
}

.browser-tab-close {
  font-weight: 700;
  opacity: 0.6;
}

.browser-tab-add {
  width: 28px;
  height: 28px;
  border-radius: 10px;
  border: none;
  background: rgba(255, 255, 255, 0.6);
  cursor: pointer;
  font-size: 16px;
}

.browser-nav {
  width: 30px;
  height: 30px;
  border-radius: 10px;
  border: none;
  background: rgba(255, 255, 255, 0.85);
  cursor: pointer;
  font-size: 13px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.browser-search,
.browser-open-external,
.browser-direct {
  padding: 10px 14px;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  font-weight: 700;
  transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.browser-search,
.browser-direct {
  background: linear-gradient(135deg, #5f7cff, #7db7ff);
  color: #fff;
  box-shadow: 0 10px 24px rgba(95, 124, 255, 0.2);
}

.browser-open-external {
  background: rgba(15, 23, 42, 0.08);
  color: var(--text);
}

.browser-search:hover,
.browser-open-external:hover,
.browser-direct:hover,
.browser-quick-link:hover,
.browser-engine-chip:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 16px rgba(15, 23, 42, 0.12);
}

.browser-nav:hover:enabled {
  transform: translateY(-1px);
  box-shadow: 0 8px 16px rgba(15, 23, 42, 0.12);
}

.browser-nav:disabled {
  opacity: 0.4;
  cursor: default;
}

.browser-provider {
  padding: 8px 12px;
  min-width: 120px;
  border-radius: 12px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: rgba(255, 255, 255, 0.9);
  color: var(--text);
}

.browser-view {
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 16px;
  padding: 12px;
  min-height: 200px;
  flex: 1;
  min-height: 0;
  overflow: hidden;
  position: relative;
  box-shadow: var(--shadow-soft);
}

.browser-home {
  display: none;
  flex-direction: column;
  gap: 18px;
  padding: 14px;
  position: absolute;
  inset: 44px 12px 12px;
  overflow: auto;
  z-index: 1;
  background:
    radial-gradient(circle at top right, rgba(86, 96, 180, 0.16), transparent 26%),
    linear-gradient(180deg, rgba(18, 24, 36, 0.98), rgba(11, 16, 26, 0.98));
  border-radius: 16px;
  border: 1px solid rgba(117, 145, 255, 0.12);
}

.browser-home.show {
  display: flex;
}

.browser-home[data-mode="search"] .browser-home-grid,
.browser-home[data-mode="engine"] .browser-home-grid,
.browser-home[data-mode="blocked"] .browser-home-grid {
  grid-template-columns: 1fr;
}

.browser-home[data-mode="search"] .browser-home-section:not(:first-child),
.browser-home[data-mode="engine"] .browser-home-section:not(:first-child),
.browser-home[data-mode="blocked"] .browser-home-section:not(:first-child) {
  display: none;
}

.browser-home[data-mode="search"] .browser-home-hero,
.browser-home[data-mode="engine"] .browser-home-hero,
.browser-home[data-mode="blocked"] .browser-home-hero {
  padding: 18px;
  align-items: center;
}

.browser-home-hero {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-end;
  padding: 22px;
  border-radius: 18px;
  border: 1px solid rgba(117, 145, 255, 0.12);
  background:
    radial-gradient(circle at top right, rgba(115, 86, 255, 0.16), transparent 28%),
    radial-gradient(circle at left center, rgba(66, 125, 255, 0.14), transparent 24%),
    linear-gradient(180deg, rgba(20, 29, 44, 0.98), rgba(14, 20, 31, 0.98));
  box-shadow: 0 18px 32px rgba(0, 0, 0, 0.22);
}

.browser-home-kicker {
  margin-bottom: 8px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #8da0c8;
}

.browser-home-hero-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.browser-home-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.browser-home-title {
  font-size: 24px;
  font-weight: 800;
  color: #f2f6ff;
}

.browser-home-sub {
  color: #9cadcf;
  max-width: 640px;
}

.browser-home-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 18px;
  border-radius: 18px;
  border: 1px solid rgba(117, 145, 255, 0.1);
  background: linear-gradient(180deg, rgba(16, 23, 36, 0.92), rgba(12, 18, 28, 0.92));
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.03);
}

.browser-home-section-wide {
  grid-column: 1 / -1;
}

.browser-home-label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #8da0c8;
}

.browser-home-links,
.browser-blocked-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.browser-quick-link,
.browser-engine-chip,
.browser-saved-link {
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid rgba(117, 145, 255, 0.12);
  background: linear-gradient(180deg, rgba(26, 35, 52, 0.98), rgba(19, 27, 41, 0.98));
  color: #edf3ff;
  cursor: pointer;
  font-weight: 700;
  box-shadow: 0 10px 20px rgba(4, 8, 16, 0.2);
}

.browser-quick-link-primary {
  background: linear-gradient(135deg, #5d7dff, #8c6dff);
  color: #fff;
  border-color: rgba(155, 173, 255, 0.26);
}

.browser-note {
  font-size: 11px;
  color: #8da0c8;
}

.browser-saved-link {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
  min-width: 180px;
  max-width: 240px;
  min-height: 70px;
  text-align: left;
}

.browser-saved-title {
  font-weight: 800;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.browser-saved-sub {
  font-size: 11px;
  color: #8da0c8;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 1200px) {
  .browser-home-hero {
    flex-direction: column;
    align-items: flex-start;
  }

  .browser-home-hero-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 900px) {
  .browser-home-grid {
    grid-template-columns: 1fr;
  }

  .browser-home-section-wide {
    grid-column: auto;
  }
}

.browser-blocked {
  position: absolute;
  inset: 36px 10px 10px;
  background: rgba(12, 18, 28, 0.85);
  color: #ffffff;
  border-radius: 12px;
  padding: 18px;
  display: none;
  flex-direction: column;
  gap: 10px;
  align-items: flex-start;
  justify-content: center;
  text-align: left;
  z-index: 3;
}

.browser-blocked.show {
  display: flex;
}

.browser-blocked-title {
  font-size: 15px;
  font-weight: 600;
}

.browser-blocked-sub {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.85);
}

.browser-blocked .browser-external {
  background: #fff;
  color: #0b0f16;
}

.browser-frame {
  width: 100%;
  flex: 1;
  min-height: 200px;
  height: 100%;
  min-height: 0;
  border: 1px solid rgba(15, 23, 42, 0.12);
  border-radius: 10px;
  background: #ffffff;
}

.browser-frame.is-hidden {
  opacity: 0;
  pointer-events: none;
}

.browser-results .title {
  font-weight: 600;
  font-size: 14px;
  color: #eef4ff;
}

.browser-results .snippet,
.browser-results .url {
  font-size: 12px;
  color: var(--muted);
}

.browser-results .list-item {
  cursor: pointer;
}

.notes {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 16px;
  min-height: 0;
  animation: riseIn 0.4s ease both;
}

.notes-sidebar,
.notes-editor {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 0;
  padding: 12px;
  border-radius: 16px;
  background: var(--panel);
  border: 1px solid var(--border-glass);
  box-shadow: var(--shadow-soft);
}

.calculator {
  display: flex;
  flex-direction: column;
  gap: 14px;
  height: 100%;
  min-height: 0;
  animation: riseIn 0.4s ease both;
}

.calc-display {
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.96), rgba(255, 255, 255, 0.78));
  border: 1px solid var(--border-glass);
  border-radius: 18px;
  padding: 16px 18px;
  min-height: 86px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  box-shadow: var(--shadow-soft);
}

.calc-expression {
  font-size: 13px;
  color: var(--muted);
  text-align: right;
  min-height: 16px;
  letter-spacing: 0.3px;
  word-break: break-all;
}

.calc-result {
  font-size: 32px;
  font-weight: 600;
  text-align: right;
  line-height: 1.1;
  color: var(--text);
  word-break: break-all;
}

.calc-body {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 12px;
  flex: 1;
  min-height: 0;
}

.calc-history {
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid var(--border-glass);
  border-radius: 16px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 0;
  box-shadow: var(--shadow-soft);
}

.calc-history-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  font-weight: 600;
}

.calc-history-clear {
  border: 1px solid rgba(15, 23, 42, 0.16);
  background: rgba(255, 255, 255, 0.7);
  border-radius: 10px;
  padding: 4px 10px;
  font-size: 12px;
  cursor: pointer;
}

.calc-history-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  overflow: auto;
  padding-right: 4px;
}

.calc-history-item {
  border-radius: 14px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.95);
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.calc-history-item:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 18px rgba(15, 23, 42, 0.12);
}

.calc-history-item .expr {
  font-size: 13px;
  color: var(--muted);
}

.calc-history-item .result {
  font-size: 16px;
  font-weight: 600;
}

.calc-history-item .time {
  font-size: 11px;
  color: var(--muted);
}

.calc-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  align-content: start;
}

.calc-grid button {
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: rgba(255, 255, 255, 0.94);
  border-radius: 14px;
  padding: 12px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.calc-grid button:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.12);
}

.calc-grid .calc-operator {
  background: rgba(96, 165, 250, 0.16);
  color: #1d4ed8;
}

.calc-grid .calc-control {
  background: rgba(248, 113, 113, 0.16);
  color: #b91c1c;
}

.calc-grid .calc-equals {
  background: var(--desktop-accent);
  color: #ffffff;
  border-color: transparent;
}

@media (max-width: 900px) {
  .calc-body {
    grid-template-columns: 1fr;
  }
}

.mail {
  display: block;
  height: 100%;
  min-height: 0;
  animation: riseIn 0.35s ease both;
}

.mail-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.mail-identity {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-radius: 12px;
  background: var(--glass);
  border: 1px solid rgba(255, 255, 255, 0.6);
  box-shadow: 0 10px 18px rgba(15, 23, 42, 0.08);
}

.mail-identity-label {
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.mail-address {
  font-weight: 600;
}

.mail-shell {
  display: grid;
  grid-template-columns: 230px 1fr;
  gap: 16px;
  min-height: 0;
  height: 100%;
}

.mail-sidebar {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 16px;
  border-radius: 16px;
  background: var(--panel);
  border: 1px solid var(--border-glass);
  min-height: 0;
  box-shadow: var(--shadow-soft);
}

.mail-new {
  width: 100%;
}

.mail-folders {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.mail-folder {
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.7);
  color: var(--text);
  padding: 10px 12px;
  border-radius: 10px;
  text-align: left;
  font-weight: 600;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.mail-folder:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 18px rgba(15, 23, 42, 0.12);
}

.mail-folder.active {
  border-color: rgba(74, 163, 255, 0.6);
  box-shadow: 0 0 0 1px rgba(74, 163, 255, 0.25) inset;
}

.mail-help {
  margin-top: auto;
  font-size: 12px;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.mail-domain {
  font-weight: 600;
  color: var(--text);
}

.mail-content {
  display: grid;
  grid-template-columns: minmax(260px, 340px) 1fr;
  grid-template-rows: auto 1fr;
  gap: 16px;
  min-height: 0;
}

.mail-left {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-height: 0;
}

.mail-compose {
  grid-column: 1 / -1;
  position: relative;
  display: grid;
  gap: 12px;
  padding: 16px;
  border-radius: 16px;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.92), rgba(255, 255, 255, 0.78));
  border: 1px solid var(--border-glass);
  box-shadow: var(--shadow-soft);
}

.mail-compose.is-hidden {
  display: none;
}

.mail-compose-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-weight: 600;
}

.mail-compose-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.mail-compose-status {
  font-size: 12px;
  color: var(--muted);
}

.mail-lock {
  position: absolute;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 6px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(var(--ui-blur));
  z-index: 2;
  text-align: center;
}

.mail-lock.show {
  display: flex;
}

.mail-lock-title {
  font-weight: 700;
}

.mail-to-wrap {
  display: flex;
  align-items: center;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.8);
  overflow: hidden;
}

.mail-to-wrap input {
  border: none;
  background: transparent;
  padding: 8px 10px;
  flex: 1;
}

.mail-domain-suffix {
  padding: 0 10px;
  font-size: 12px;
  color: var(--muted);
  border-left: 1px solid rgba(255, 255, 255, 0.65);
  background: rgba(255, 255, 255, 0.55);
}

.mail-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}

.mail-directory {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 12px;
  border-radius: 16px;
  background: var(--panel-2);
  border: 1px solid var(--border-glass);
  min-height: 0;
  box-shadow: var(--shadow-soft);
}

.mail-directory-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-weight: 600;
  font-size: 13px;
}

.mail-directory-count {
  font-size: 12px;
  color: var(--muted);
}

.mail-directory-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 0;
  max-height: 300px;
  overflow: auto;
}

.mail-directory-item {
  width: 100%;
  text-align: left;
  gap: 6px;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.6);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.mail-directory-item:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 18px rgba(15, 23, 42, 0.12);
}

.mail-directory-name {
  font-weight: 600;
  font-size: 13px;
}

.mail-directory-meta,
.mail-directory-email {
  font-size: 11px;
  color: var(--muted);
}

.mail-directory-empty {
  font-size: 11px;
  color: var(--muted);
}

.mail-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 12px;
  border-radius: 16px;
  background: var(--panel-2);
  border: 1px solid var(--border-glass);
  min-height: 0;
  box-shadow: var(--shadow-soft);
}

.mail-list-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-weight: 600;
}

.mail-count {
  font-size: 12px;
  color: var(--muted);
}

.mail-list-items {
  min-height: 0;
}

.mail-item {
  width: 100%;
  text-align: left;
  gap: 6px;
}

.mail-item-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
}

.mail-item-time {
  font-size: 11px;
  color: var(--muted);
}

.mail-item-meta {
  font-size: 11px;
  color: var(--muted);
}

.mail-item-snippet {
  font-size: 12px;
  color: var(--muted);
}

.mail-detail {
  padding: 16px;
  border-radius: 16px;
  background: var(--panel-2);
  border: 1px solid var(--border-glass);
  min-height: 0;
  overflow: auto;
  box-shadow: var(--shadow-soft);
}

.mail-detail-empty {
  color: var(--muted);
  font-size: 12px;
}

.mail-detail-body {
  display: none;
  flex-direction: column;
  gap: 12px;
}

.mail-detail-body.show {
  display: flex;
}

.mail-detail-subject {
  font-size: 16px;
  font-weight: 700;
}

.mail-detail-meta {
  font-size: 12px;
  color: var(--muted);
}

.mail-detail-text {
  font-size: 13px;
  line-height: 1.5;
  white-space: pre-wrap;
}

.mail .field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12px;
  color: var(--muted);
}

.mail .field span {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.mail .field.grow textarea {
  min-height: 140px;
}

.mail button:disabled,
.mail input:disabled,
.mail textarea:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

@media (max-width: 1100px) {
  .mail-shell {
    grid-template-columns: 1fr;
  }
  .mail-sidebar {
    flex-direction: row;
    align-items: center;
    flex-wrap: wrap;
  }
}

@media (max-width: 900px) {
  .mail-content {
    grid-template-columns: 1fr;
  }
  .mail-compose {
    grid-column: 1;
  }
}

.faction {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 16px;
  min-height: 0;
}

.channels,
.chat {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 0;
}

.channel-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.chat-header {
  font-weight: 600;
}

.chat-messages {
  flex: 1;
  overflow: auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.chat-message {
  padding: 8px;
  background: rgba(255, 255, 255, 0.85);
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.7);
}

.chat-message .meta {
  font-size: 11px;
  color: var(--muted);
}

.chat-input {
  display: flex;
  gap: 10px;
}

.clock {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 0;
  height: 100%;
  animation: riseIn 0.4s ease both;
}

.clock-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px;
  border-radius: 18px;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.78));
  border: 1px solid var(--border-glass);
  box-shadow: var(--shadow-soft);
}

.clock-hero-time {
  font-size: 34px;
  font-weight: 600;
  letter-spacing: 0.6px;
}

.clock-hero-date {
  font-size: 13px;
  color: var(--muted);
  text-align: right;
}

.clock-tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  padding: 6px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid var(--border-glass);
  box-shadow: var(--shadow-soft);
}

.clock-tab {
  background: transparent;
  color: var(--text);
  border: none;
  padding: 8px 12px;
  border-radius: 10px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.clock-tab.active {
  background: linear-gradient(135deg, var(--desktop-accent), #9dc3ff);
  color: #0b0f16;
  box-shadow: 0 10px 18px rgba(88, 130, 220, 0.25);
}

.clock-tab:hover {
  transform: translateY(-1px);
}

.clock-panels {
  flex: 1;
  min-height: 0;
}

.clock-panel {
  display: none;
  gap: 12px;
  flex-direction: column;
  background: rgba(255, 255, 255, 0.86);
  border: 1px solid var(--border-glass);
  border-radius: 18px;
  padding: 16px;
  min-height: 0;
  box-shadow: var(--shadow-soft);
}

.clock-panel.active {
  display: flex;
}

.stopwatch-display,
.timer-display {
  font-size: 34px;
  font-weight: 600;
  text-align: center;
  padding: 14px;
  background: rgba(255, 255, 255, 0.92);
  border-radius: 14px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  letter-spacing: 0.6px;
}

.alarm-list,
.world-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.alarm-list .list-item,
.world-list .list-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(15, 23, 42, 0.08);
}

.alarm-list .list-item button,
.world-list .list-item button {
  padding: 6px 10px;
  font-size: 11px;
}

.clock-alert {
  position: absolute;
  inset: 0;
  background: rgba(10, 14, 22, 0.45);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 5;
}

.clock-alert.show {
  display: flex;
}

.clock-alert-card {
  min-width: 260px;
  max-width: 360px;
  padding: 16px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.98);
  border: 1px solid rgba(15, 23, 42, 0.12);
  box-shadow: 0 18px 36px rgba(15, 23, 42, 0.18);
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.clock-alert-title {
  font-size: 18px;
  font-weight: 700;
}

.clock-alert-message {
  font-size: 14px;
  color: var(--muted);
}

.clock-alert-stop {
  padding: 10px 14px;
  border-radius: 12px;
  border: none;
  background: #ef4444;
  color: #fff;
  font-weight: 600;
  cursor: pointer;
}

.global-alarm {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 999;
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.global-alarm.show {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.global-alarm-card {
  min-width: 260px;
  max-width: 360px;
  padding: 16px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.98);
  border: 1px solid rgba(15, 23, 42, 0.12);
  box-shadow: 0 18px 36px rgba(15, 23, 42, 0.18);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.global-alarm-title {
  font-size: 18px;
  font-weight: 700;
}

.global-alarm-message {
  font-size: 14px;
  color: var(--muted);
}

.global-alarm-stop {
  padding: 10px 14px;
  border-radius: 12px;
  border: none;
  background: #ef4444;
  color: #fff;
  font-weight: 600;
  cursor: pointer;
}

.settings {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}

.settings-card {
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.75));
  border: 1px solid var(--border-glass);
  border-radius: 18px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-shadow: var(--shadow-soft);
  animation: riseIn 0.35s ease both;
}

.settings-card.is-hidden {
  display: none;
}

.settings-card h3 {
  margin: 0;
  font-size: 15px;
}

.settings-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 12px;
  color: var(--muted);
}

.settings-row span {
  min-width: 88px;
  font-weight: 600;
  color: var(--text);
}

.settings-row select,
.settings-row input[type="color"],
.settings-row input[type="range"] {
  flex: 1;
}

.settings-row output {
  min-width: 44px;
  text-align: right;
  font-size: 11px;
  color: var(--muted);
}

.settings-hint {
  font-size: 12px;
  color: var(--muted);
}

.staff-grid {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 16px;
}

.staff-panel {
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid var(--border-glass);
  border-radius: 16px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  box-shadow: var(--shadow-soft);
}

.staff-filter-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12px;
  color: var(--muted);
}

.staff-panel h3 {
  margin: 0;
  font-size: 14px;
}

.staff-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.staff-meta {
  font-size: 11px;
  color: var(--muted);
}

.staff-actions {
  display: flex;
  gap: 6px;
}

.admin-toolbar {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.admin-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.admin-filter {
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  background: rgba(255, 255, 255, 0.7);
  color: var(--text);
  font-size: 12px;
  font-weight: 600;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.admin-filter.active {
  background: linear-gradient(135deg, var(--desktop-accent), #9dc3ff);
  color: #0b0f16;
  border-color: transparent;
  box-shadow: 0 10px 18px rgba(88, 130, 220, 0.25);
}

.admin-filter:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 18px rgba(15, 23, 42, 0.12);
}

.admin-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.admin-search {
  flex: 1;
  min-width: 180px;
  padding: 8px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  background: rgba(255, 255, 255, 0.85);
  box-shadow: var(--shadow-soft);
}

.admin-log-list {
  max-height: 420px;
  overflow: auto;
}

.admin-meta {
  font-size: 11px;
  color: var(--muted);
}

.status {
  position: absolute;
  bottom: 16px;
  right: 16px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.7);
  padding: 8px 12px;
  border-radius: 12px;
  font-size: 12px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
  box-shadow: var(--shadow-soft);
}

.status.show {
  opacity: 1;
}

html.no-blur *,
html.no-blur *::before,
html.no-blur *::after {
  backdrop-filter: none !important;
}

html.dark-mode {
  color-scheme: dark;
  --text: #e6ebf5;
  --muted: #9aa6bd;
  --panel: rgba(20, 25, 38, var(--panel-alpha));
  --panel-2: rgba(26, 32, 48, var(--panel-2-alpha));
  --glass: rgba(30, 36, 54, var(--glass-alpha));
  --glass-strong: rgba(34, 40, 58, var(--glass-strong-alpha));
  --border-glass: rgba(255, 255, 255, 0.08);
  --shadow-strong: 0 26px 60px rgba(0, 0, 0, 0.5);
  --shadow-soft: 0 14px 32px rgba(0, 0, 0, 0.35);
  --focus-ring: rgba(120, 170, 255, 0.6);
  --accent-glow: rgba(120, 170, 255, 0.35);
}

html.dark-mode .ui-shell {
  background: linear-gradient(160deg, rgba(22, 26, 38, 0.95), rgba(18, 22, 34, 0.75));
}

html.dark-mode .ui-shell::before,
html.dark-mode .ui-shell::after {
  display: none;
}

html.dark-mode .desktop-window {
  background: linear-gradient(160deg, rgba(20, 24, 36, 0.95), rgba(16, 20, 30, 0.82));
  border-color: rgba(255, 255, 255, 0.08);
}

html.dark-mode .desktop-window::before {
  display: none;
}

html.dark-mode .desktop-icon {
  background: rgba(14, 20, 34, 0.12);
  border-color: transparent;
  box-shadow: none;
}

html.dark-mode .desktop-icon:hover {
  background: rgba(26, 34, 52, 0.22);
  border-color: rgba(255, 255, 255, 0.12);
}

html.dark-mode .desktop-icon .icon {
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.05));
  color: #dce7ff;
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.35), inset 0 0 0 1px rgba(255, 255, 255, 0.1);
}

html.dark-mode .desktop-icon .label {
  color: #f4f8ff;
  background: rgba(4, 8, 16, 0.58);
}

html.dark-mode .has-app-icon {
  filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.55));
}

html.dark-mode .desktop-icon .icon.has-app-icon,
html.dark-mode .window-app-icon.has-app-icon,
html.dark-mode .start-tile .tile-icon.has-app-icon,
html.dark-mode .task-icon.has-app-icon,
html.dark-mode .tablet-icon-face.has-app-icon,
html.dark-mode .tablet-dock-icon.has-app-icon {
  background-color: transparent;
  background-blend-mode: normal;
}

html.dark-mode .window-header {
  background: rgba(18, 22, 34, 0.72);
  border-bottom-color: rgba(255, 255, 255, 0.08);
}

html.dark-mode .window-actions button {
  background: transparent;
  border: none;
}

html.dark-mode .window-actions button:hover {
  background: rgba(38, 44, 64, 0.82);
}

html.dark-mode .window-actions button[data-action="close"] {
  border-color: rgba(255, 107, 107, 0.35);
}

html.dark-mode .window-actions button[data-action="close"]:hover {
  background: rgba(255, 107, 107, 0.45);
}

html.dark-mode .window-title-sub {
  color: var(--muted);
}

html.dark-mode .window-snap-menu,
html.dark-mode .snap-layout-option,
html.dark-mode .window-snap-menu button,
html.dark-mode .taskbar-search,
html.dark-mode .taskbar-tray-icons {
  background: rgba(20, 26, 40, 0.82);
  border-color: rgba(255, 255, 255, 0.12);
  color: var(--text);
}

html.dark-mode .snap-layout-option::before {
  background: rgba(255, 255, 255, 0.03);
  border-color: rgba(255, 255, 255, 0.08);
}

html.dark-mode .window-snap-menu button:hover,
html.dark-mode .window-snap-menu button:focus-visible {
  background: rgba(115, 167, 255, 0.28);
  border-color: rgba(115, 167, 255, 0.55);
}

html.dark-mode .taskbar-search-icon {
  background: rgba(255, 255, 255, 0.12);
  color: var(--text);
}

html.dark-mode .desktop-window,
html.dark-mode .window-header,
html.dark-mode .window-actions button,
html.dark-mode .window-content,
html.dark-mode .browser-bar,
html.dark-mode .browser-tabs,
html.dark-mode .browser-tab,
html.dark-mode .browser-tab-add,
html.dark-mode .browser-nav,
html.dark-mode .browser-results,
html.dark-mode .browser-view,
html.dark-mode .browser-blocked,
html.dark-mode .calc-display,
html.dark-mode .calc-history,
html.dark-mode .calc-grid button,
html.dark-mode .calc-history-clear,
html.dark-mode .mail-identity,
html.dark-mode .mail-to-wrap,
html.dark-mode .mail-domain-suffix,
html.dark-mode .mail-folder,
html.dark-mode .mail-directory-item,
html.dark-mode .mail-item,
html.dark-mode .start-menu,
html.dark-mode .start-header,
html.dark-mode .start-search input,
html.dark-mode .start-tile,
html.dark-mode .start-recommendations,
html.dark-mode .taskbar,
html.dark-mode .taskbar-clock,
html.dark-mode .network-bar,
html.dark-mode .settings-card,
html.dark-mode .app-header,
html.dark-mode .app-section,
html.dark-mode .notes-sidebar,
html.dark-mode .notes-editor,
html.dark-mode .tablet-modal-card,
html.dark-mode .tablet-sidebar,
html.dark-mode .tablet-content,
html.dark-mode .tablet-widget,
html.dark-mode .tablet-logout {
  background: var(--panel);
  border-color: rgba(255, 255, 255, 0.12);
  color: var(--text);
}

html.dark-mode .window-header {
  background: rgba(18, 22, 34, 0.72);
}

html.dark-mode .window-actions button {
  background: transparent;
  border: none;
}

html.dark-mode .window-actions button:hover {
  background: rgba(38, 44, 64, 0.82);
}

html.dark-mode .browser-provider,
html.dark-mode .staff-panel,
html.dark-mode .admin-filter,
html.dark-mode .admin-search,
html.dark-mode .status {
  background: rgba(24, 30, 44, 0.9);
  border-color: rgba(255, 255, 255, 0.12);
  color: var(--text);
}

html.dark-mode .tablet::before {
  opacity: 0.55;
}

html.dark-mode .tablet-home,
html.dark-mode .tablet-profile-card,
html.dark-mode .tablet-app-window,
html.dark-mode .tablet-app-topbar,
html.dark-mode .tablet-status-day,
html.dark-mode .tablet-status-icons,
html.dark-mode .tablet-time-chip,
html.dark-mode .tablet-status,
html.dark-mode .tablet-status-pill,
html.dark-mode .tablet-profile-action,
html.dark-mode .tablet-profile-primary,
html.dark-mode .tablet-app-action,
html.dark-mode .tablet-sidebar-btn,
html.dark-mode .tablet-control-tile,
html.dark-mode .tablet-control-segment,
html.dark-mode .tablet-control-summary,
html.dark-mode .tablet-modal-close,
html.dark-mode .tablet-segment-btn {
  background: rgba(20, 26, 40, 0.78);
  border-color: rgba(255, 255, 255, 0.12);
  color: var(--text);
}

html.dark-mode .tablet-home {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

html.dark-mode .tablet-status-title,
html.dark-mode .tablet-profile-name,
html.dark-mode .tablet-app-title,
html.dark-mode .tablet-control-tile strong {
  color: var(--text);
}

html.dark-mode .tablet-status-day,
html.dark-mode .tablet-profile-meta,
html.dark-mode .tablet-profile-kicker,
html.dark-mode .tablet-app-subtitle,
html.dark-mode .tablet-modal-kicker,
html.dark-mode .tablet-control-tile span,
html.dark-mode .tablet-control-tile small,
html.dark-mode .tablet-control-summary {
  color: var(--muted);
}

html.dark-mode .tablet-sidebar-btn.active {
  background: rgba(48, 62, 96, 0.9);
  border-color: rgba(120, 170, 255, 0.28);
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.28);
}

html.dark-mode .tablet-home-indicator {
  background: rgba(255, 255, 255, 0.72);
}

html.dark-mode .tablet-control-tile.danger strong {
  color: #ff8c8c;
}

html.dark-mode .stopwatch-display,
html.dark-mode .timer-display,
html.dark-mode .alarm-list .list-item,
html.dark-mode .world-list .list-item {
  background: rgba(24, 30, 44, 0.9);
  border-color: rgba(255, 255, 255, 0.12);
  color: var(--text);
}

html.dark-mode .mail-compose,
html.dark-mode .mail-lock,
html.dark-mode .mail-directory,
html.dark-mode .mail-list,
html.dark-mode .mail-detail,
html.dark-mode .mail-folder,
html.dark-mode .mail-directory-item,
html.dark-mode .mail-to-wrap,
html.dark-mode .mail-domain-suffix,
html.dark-mode .clock-hero,
html.dark-mode .clock-tabs,
html.dark-mode .clock-panel,
html.dark-mode .notes-sidebar,
html.dark-mode .notes-editor,
html.dark-mode .browser-bar,
html.dark-mode .browser-tabs,
html.dark-mode .browser-view,
html.dark-mode .browser-results {
  background: rgba(24, 30, 44, 0.9);
  border-color: rgba(255, 255, 255, 0.12);
  color: var(--text);
}

html.dark-mode .browser-results .title,
html.dark-mode .mail-address,
html.dark-mode .mail-domain,
html.dark-mode .clock-hero-time,
html.dark-mode .clock-tab,
html.dark-mode .calc-result {
  color: var(--text);
}

html.dark-mode .browser-results .snippet,
html.dark-mode .browser-results .url,
html.dark-mode .browser-result-meta,
html.dark-mode .mail-item-meta,
html.dark-mode .mail-item-snippet,
html.dark-mode .mail-item-time,
html.dark-mode .calc-expression,
html.dark-mode .calc-history-item .expr,
html.dark-mode .calc-history-item .time {
  color: var(--muted);
}

html.dark-mode .browser-result-thumb {
  background: rgba(10, 14, 22, 0.9);
  border-color: rgba(255, 255, 255, 0.12);
}

html.dark-mode .login-screen,
html.dark-mode .lock-screen {
  color: #0f1a2b;
}

html.dark-mode .login-card,
html.dark-mode .login-input,
html.dark-mode .login-toggle,
html.dark-mode .login-submit,
html.dark-mode .login-mode-btn {
  color: #0f1a2b;
}

html.dark-mode .window-content,
html.dark-mode .browser-bar,
html.dark-mode .browser-tabs,
html.dark-mode .browser-view,
html.dark-mode .calc-display,
html.dark-mode .calc-history,
html.dark-mode .clock-hero,
html.dark-mode .clock-tabs,
html.dark-mode .clock-panel,
html.dark-mode .mail-sidebar,
html.dark-mode .mail-compose,
html.dark-mode .mail-directory,
html.dark-mode .mail-list,
html.dark-mode .mail-detail,
html.dark-mode .settings-card,
html.dark-mode .notes-sidebar,
html.dark-mode .notes-editor,
html.dark-mode .app-header,
html.dark-mode .app-section {
  background: var(--panel);
  border-color: rgba(255, 255, 255, 0.12);
}

html.dark-mode .list-item,
html.dark-mode .calc-history-item,
html.dark-mode .mail-directory-item,
html.dark-mode .mail-folder {
  background: rgba(24, 30, 44, 0.85);
  border-color: rgba(255, 255, 255, 0.12);
}

html.dark-mode input,
html.dark-mode textarea,
html.dark-mode select {
  background: rgba(24, 30, 44, 0.9);
  border-color: rgba(255, 255, 255, 0.12);
  color: var(--text);
}

html.dark-mode .browser-frame {
  background: rgba(12, 16, 24, 0.9);
  border-color: rgba(255, 255, 255, 0.12);
}

html.dark-mode .taskbar {
  background: rgba(20, 25, 40, 0.7);
  border-color: rgba(255, 255, 255, 0.08);
}

html.dark-mode .task-icon,
html.dark-mode .taskbar-start {
  background: rgba(24, 30, 44, 0.7);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.35);
}

html.dark-mode .taskbar-clock {
  background: rgba(24, 30, 44, 0.7);
  color: var(--muted);
}

html.dark-mode .start-menu {
  background: rgba(20, 25, 40, 0.9);
  border-color: rgba(255, 255, 255, 0.08);
}

html.dark-mode .network-bar {
  background: rgba(20, 25, 40, 0.72);
  border-color: rgba(255, 255, 255, 0.1);
}

@media (max-width: 900px) {
  .desktop-window {
    width: 90vw;
    height: 70vh;
  }

  .notes,
  .mail,
  .faction,
  .settings,
  .staff-grid {
    grid-template-columns: 1fr;
  }

  .tablet-home {
    grid-template-columns: repeat(3, minmax(90px, 1fr));
  }
}

/* 2026-03 polish pass */

.app-shell {
  flex: 1;
  min-height: 0;
}

.app-topbar,
.app-header-rich {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.app-topbar {
  padding: 4px 2px 0;
}

.app-topbar-copy {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.app-kicker {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--muted);
}

.app-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.08);
  font-size: 12px;
  font-weight: 600;
}

.app-header-stats {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.app-stat {
  min-width: 96px;
  padding: 10px 12px;
  border-radius: 16px;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.88), rgba(255, 255, 255, 0.62));
  border: 1px solid rgba(255, 255, 255, 0.72);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.app-stat.compact {
  min-width: 78px;
  padding: 9px 10px;
}

.app-stat span {
  font-size: 11px;
  color: var(--muted);
}

.app-stat strong {
  font-size: 14px;
  line-height: 1.2;
}

.empty-state,
.list-empty {
  padding: 18px;
  border-radius: 16px;
  border: 1px dashed rgba(120, 150, 220, 0.28);
  background: rgba(255, 255, 255, 0.48);
  color: var(--muted);
  text-align: center;
  font-size: 12px;
}

.notes {
  align-items: stretch;
}

.notes-sidebar-top,
.notes-editor-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.notes-sidebar-top {
  flex-direction: column;
  align-items: stretch;
}

.notes-subtle {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.45;
}

.notes-save-state {
  flex: 0 0 auto;
  min-width: 76px;
  text-align: center;
  padding: 8px 10px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.76);
  border: 1px solid rgba(255, 255, 255, 0.7);
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
}

.notes-save-state.is-dirty {
  color: #915d00;
  background: rgba(255, 234, 185, 0.9);
  border-color: rgba(255, 196, 96, 0.55);
}

.notes-save-state.is-saved {
  color: #0d6b39;
  background: rgba(204, 251, 230, 0.9);
  border-color: rgba(72, 187, 120, 0.42);
}

.notes-note-card {
  align-items: flex-start;
}

.notes-note-title {
  font-weight: 700;
}

.notes-note-preview,
.notes-note-time {
  font-size: 12px;
  color: var(--muted);
}

.calculator {
  overflow: hidden;
}

.calc-history-subtitle {
  font-size: 12px;
  color: var(--muted);
}

.calc-history-list .muted {
  padding: 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.54);
  color: var(--muted);
  text-align: center;
}

.calc-grid button {
  min-height: 56px;
}

.calc-grid .calc-equals {
  box-shadow: 0 12px 26px rgba(74, 163, 255, 0.28);
}

.browser {
  overflow: hidden;
}

.browser-state.is-searching {
  background: rgba(255, 237, 184, 0.9);
  border-color: rgba(255, 205, 86, 0.45);
  color: #7a5300;
}

.browser-state.is-site {
  background: rgba(224, 244, 255, 0.9);
  border-color: rgba(93, 174, 255, 0.35);
  color: #0f4e86;
}

.browser-state.is-blocked {
  background: rgba(255, 220, 220, 0.9);
  border-color: rgba(235, 87, 87, 0.4);
  color: #8a1f1f;
}

.browser-view {
  gap: 10px;
}

.browser-view-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 0 4px;
}

.browser-meta-title {
  font-size: 13px;
  font-weight: 700;
}

.browser-meta-sub {
  font-size: 12px;
  color: var(--muted);
}

.browser-results {
  inset: 64px 10px 10px;
}

.browser-blocked {
  inset: 64px 10px 10px;
}

.browser-frame {
  border-radius: 14px;
}

.mail-header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.mail-header-stats {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.mail-directory-empty,
.mail-list-empty {
  padding: 16px;
  border-radius: 14px;
  border: 1px dashed rgba(120, 150, 220, 0.25);
  background: rgba(255, 255, 255, 0.55);
  color: var(--muted);
  text-align: center;
  font-size: 12px;
}

.mail-folder.active {
  transform: translateY(-1px);
}

.mail-item,
.mail-directory-item {
  text-align: left;
}

.clock {
  overflow: hidden;
}

.clock-panel .row {
  flex-wrap: wrap;
}

.settings-card::after,
.staff-panel::after,
.admin-summary::after {
  content: "";
  display: block;
}

.staff-grid {
  grid-template-columns: 280px 1fr;
}

.staff-panel-wide {
  min-height: 0;
}

.staff-toolbar {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.staff-list {
  min-height: 220px;
  max-height: 340px;
}

.staff-item {
  align-items: center;
}

.staff-item-main {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.staff-item-title {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.staff-item-title strong {
  font-size: 14px;
}

.staff-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(74, 163, 255, 0.14);
  color: #0f4e86;
  font-size: 11px;
  font-weight: 700;
}

.staff-chip.is-boss {
  background: rgba(255, 220, 120, 0.3);
  color: #8a5a00;
}

.staff-chip.is-disabled {
  background: rgba(255, 119, 119, 0.18);
  color: #a22f2f;
}

.staff-item-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.staff-item-actions button {
  min-width: 82px;
}

.staff-editor {
  margin-top: 14px;
  padding: 14px;
  border-radius: 18px;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.92), rgba(255, 255, 255, 0.72));
  border: 1px solid rgba(255, 255, 255, 0.72);
  box-shadow: var(--shadow-soft);
}

.staff-editor-form.is-hidden {
  display: none;
}

.staff-editor-empty {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.55;
}

.staff-editor-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.staff-editor-grid label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12px;
  color: var(--muted);
}

.staff-edit-password-wrap,
.staff-edit-active-toggle {
  grid-column: 1 / -1;
}

.staff-edit-active-toggle {
  flex-direction: row !important;
  align-items: center;
}

.staff-edit-active-toggle input {
  width: auto;
}

.staff-editor-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 14px;
}

.admin-summary {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}

.admin-log-entry {
  gap: 8px;
}

.admin-log-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.admin-log-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(74, 163, 255, 0.15);
  color: #0f4e86;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
}

.admin-log-message {
  font-size: 13px;
}

.admin-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.login-input,
.login-toggle,
.login-submit,
.login-mode-btn {
  color-scheme: light;
}

.login-input::placeholder {
  color: rgba(15, 26, 43, 0.45);
}

.login-input:focus,
.login-toggle:focus,
.login-submit:focus,
.login-mode-btn:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(90, 150, 255, 0.18);
}

.login-input:-webkit-autofill,
.login-input:-webkit-autofill:hover,
.login-input:-webkit-autofill:focus {
  -webkit-text-fill-color: #0f1a2b;
  box-shadow: 0 0 0 1000px rgba(255, 255, 255, 0.96) inset;
  transition: background-color 9999s ease-in-out 0s;
}

html.dark-mode .app-pill,
html.dark-mode .app-stat,
html.dark-mode .notes-save-state,
html.dark-mode .staff-editor,
html.dark-mode .admin-summary,
html.dark-mode .mail-directory-empty,
html.dark-mode .mail-list-empty,
html.dark-mode .empty-state,
html.dark-mode .list-empty,
html.dark-mode .calc-history-list .muted {
  background: rgba(24, 30, 44, 0.82);
  border-color: rgba(255, 255, 255, 0.12);
  color: var(--text);
}

html.dark-mode .browser-state.is-searching {
  background: rgba(99, 71, 20, 0.95);
  color: #ffd98c;
}

html.dark-mode .browser-state.is-site {
  background: rgba(24, 58, 92, 0.95);
  color: #b5dcff;
}

html.dark-mode .browser-state.is-blocked {
  background: rgba(99, 33, 33, 0.95);
  color: #ffb8b8;
}

html.dark-mode .notes-save-state.is-dirty {
  background: rgba(99, 71, 20, 0.95);
  color: #ffd98c;
}

html.dark-mode .notes-save-state.is-saved {
  background: rgba(18, 86, 54, 0.95);
  color: #c7ffd8;
}

html.dark-mode .staff-chip {
  background: rgba(72, 112, 178, 0.32);
  color: #d5e7ff;
}

html.dark-mode .staff-chip.is-boss {
  background: rgba(96, 72, 22, 0.95);
  color: #ffe3a8;
}

html.dark-mode .staff-chip.is-disabled {
  background: rgba(102, 40, 40, 0.95);
  color: #ffc4c4;
}

html.dark-mode .admin-log-badge {
  background: rgba(72, 112, 178, 0.32);
  color: #d5e7ff;
}

html.dark-mode .login-card,
html.dark-mode .login-input,
html.dark-mode .login-toggle,
html.dark-mode .login-submit,
html.dark-mode .login-mode-btn {
  color: #0f1a2b;
}

html.dark-mode .login-input,
html.dark-mode .login-toggle,
html.dark-mode .login-mode-btn {
  background: rgba(255, 255, 255, 0.96);
  border-color: rgba(15, 23, 42, 0.12);
}

html.dark-mode .login-input:focus {
  background: rgba(255, 255, 255, 0.99);
}

html.dark-mode .login-input:-webkit-autofill,
html.dark-mode .login-input:-webkit-autofill:hover,
html.dark-mode .login-input:-webkit-autofill:focus {
  -webkit-text-fill-color: #0f1a2b;
  box-shadow: 0 0 0 1000px rgba(255, 255, 255, 0.97) inset;
}

@media (max-width: 980px) {
  .app-header-rich,
  .app-topbar,
  .mail-header-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .admin-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .staff-toolbar,
  .staff-editor-grid {
    grid-template-columns: 1fr;
  }
}



