/* =========================================
   ISOGA NEXUS — SYSTEM INTERFACE
   White / Red | Futuristic UI | Responsive
   ========================================= */

:root {
  color-scheme: light;

  --red: #e32636;
  --red-dark: #a70f22;
  --red-light: #ff5262;
  --red-glow: rgba(227, 38, 54, 0.24);

  --bg: #f2f4f7;
  --panel: #ffffff;
  --panel-soft: #f8f9fb;
  --text: #171a21;
  --muted: #747b88;
  --border: #dfe3ea;

  --shadow:
    0 8px 22px rgba(20, 25, 35, 0.09),
    0 2px 5px rgba(20, 25, 35, 0.05);

  --shadow-red:
    0 8px 20px rgba(227, 38, 54, 0.20);

  --radius: 16px;
  --transition: 180ms ease;
}

/* RESET */

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  min-height: 100dvh;

  background:
    radial-gradient(
      ellipse at 100% 0%,
      rgba(227, 38, 54, 0.07),
      transparent 42%
    ),
    var(--bg);

  color: var(--text);
  font-family:
    Inter, "Segoe UI", Roboto, Arial, sans-serif;

  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

button,
input,
textarea,
select {
  font: inherit;
}

button {
  color: inherit;
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 3px solid rgba(227, 38, 54, 0.32);
  outline-offset: 3px;
}

::selection {
  color: white;
  background: var(--red);
}

[hidden],
.hidden {
  display: none !important;
}

/* SUBTELNA SIATKA TECHNOLOGICZNA */

#desktop,
.desktop,
#app,
.app-shell {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
}

#desktop::before,
.desktop::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;

  background-image:
    linear-gradient(
      rgba(30, 35, 45, 0.025) 1px,
      transparent 1px
    ),
    linear-gradient(
      90deg,
      rgba(30, 35, 45, 0.025) 1px,
      transparent 1px
    );

  background-size: 30px 30px;
  mask-image: linear-gradient(
    to bottom,
    black,
    transparent 85%
  );
}

/* =========================================
   PRZYCISKI — GŁÓWNY STYL NEXUS
   ========================================= */

button,
.button,
.btn,
.action-button {
  position: relative;
  border: 1px solid var(--border);
  border-radius: 11px;

  padding: 10px 16px;

  background: linear-gradient(
    180deg,
    #ffffff 0%,
    #f1f2f5 100%
  );

  color: var(--text);
  font-weight: 650;
  letter-spacing: 0.1px;

  box-shadow:
    0 3px 0 #d9dce2,
    0 5px 12px rgba(20, 25, 35, 0.06);

  cursor: pointer;
  transition:
    transform var(--transition),
    box-shadow var(--transition),
    border-color var(--transition),
    background var(--transition),
    color var(--transition);
}

button:hover,
.button:hover,
.btn:hover,
.action-button:hover {
  border-color: rgba(227, 38, 54, 0.45);

  background: linear-gradient(
    180deg,
    #ffffff 0%,
    #fff0f1 100%
  );

  box-shadow:
    0 3px 0 #e8b8bd,
    0 7px 18px rgba(227, 38, 54, 0.13);

  transform: translateY(-2px);
}

button:active,
.button:active,
.btn:active,
.action-button:active {
  transform: translateY(2px);

  box-shadow:
    0 1px 0 #d9dce2,
    0 2px 5px rgba(20, 25, 35, 0.06);
}

button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* GŁÓWNE PRZYCISKI */

.primary-button,
.btn-primary,
button.primary,
#start-button,
.start-button,
[data-primary="true"] {
  border-color: var(--red-dark);

  background: linear-gradient(
    180deg,
    #ff5969 0%,
    #e32636 48%,
    #bd1528 100%
  );

  color: #ffffff;

  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.35),
    0 3px 0 #890d1c,
    0 7px 16px rgba(227, 38, 54, 0.22);
}

.primary-button:hover,
.btn-primary:hover,
button.primary:hover,
#start-button:hover,
.start-button:hover,
[data-primary="true"]:hover {
  border-color: #8e0b1b;

  background: linear-gradient(
    180deg,
    #ff7380 0%,
    #f02f42 45%,
    #c7142a 100%
  );

  color: white;

  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.42),
    0 3px 0 #890d1c,
    0 0 22px var(--red-glow);

  transform: translateY(-2px);
}

.primary-button:active,
.btn-primary:active,
button.primary:active,
#start-button:active,
.start-button:active,
[data-primary="true"]:active {
  transform: translateY(2px);

  box-shadow:
    inset 0 2px 5px rgba(70, 0, 0, 0.2),
    0 1px 0 #890d1c;
}

/* =========================================
   GÓRNY PASEK SYSTEMU
   ========================================= */

.topbar,
#topbar,
.system-bar,
.status-bar {
  position: relative;
  z-index: 20;

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;

  min-height: 62px;
  padding: 10px 20px;

  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--border);

  box-shadow: 0 4px 18px rgba(20, 25, 35, 0.045);

  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.brand,
.logo,
.brand-name,
.system-brand {
  display: flex;
  align-items: center;
  gap: 10px;

  color: var(--text);
  font-weight: 850;
  letter-spacing: 1.4px;
}

.brand span,
.logo span,
.brand-name span,
.system-brand span {
  color: var(--red);
}

.clock,
#clock,
#system-clock,
.topbar-clock {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

/* =========================================
   PANEL POWITALNY
   ========================================= */

.welcome,
#welcome,
.welcome-panel,
.hero,
.hero-card {
  position: relative;
  overflow: hidden;

  margin: 22px;
  padding: 26px;

  background:
    linear-gradient(
      120deg,
      #ffffff 0%,
      #ffffff 65%,
      #fff0f1 100%
    );

  border: 1px solid #e5e6eb;
  border-left: 4px solid var(--red);
  border-radius: var(--radius);

  box-shadow: var(--shadow);
}

.welcome::after,
#welcome::after,
.welcome-panel::after,
.hero-card::after {
  content: "";
  position: absolute;

  width: 180px;
  height: 180px;

  right: -70px;
  top: -85px;

  border: 1px solid rgba(227, 38, 54, 0.13);
  border-radius: 36px;

  transform: rotate(35deg);
  pointer-events: none;
}

.welcome h1,
#welcome h1,
.welcome-panel h1,
.hero h1,
.hero-card h1 {
  margin: 0 0 10px;
  font-size: clamp(24px, 4vw, 38px);
  line-height: 1.15;
  font-weight: 850;
  letter-spacing: -1px;
}

.welcome p,
#welcome p,
.welcome-panel p,
.hero p,
.hero-card p {
  max-width: 650px;
  color: var(--muted);
}

/* =========================================
   APLIKACJE I SKRÓTY NA PULPICIE
   ========================================= */

.app-grid,
#app-grid,
.apps-grid,
.shortcuts,
.desktop-icons,
.launcher-grid {
  position: relative;
  z-index: 1;

  display: grid;
  grid-template-columns: repeat(
    auto-fit,
    minmax(130px, 1fr)
  );

  gap: 16px;
  padding: 22px;
}

.app-shortcut,
.shortcut,
.desktop-icon,
.app-card,
.launcher-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;

  min-height: 138px;
  padding: 18px 12px;

  background: linear-gradient(
    145deg,
    #ffffff 0%,
    #f6f7f9 100%
  );

  color: var(--text);
  text-align: center;

  border: 1px solid #e1e4ea;
  border-radius: 16px;

  box-shadow:
    0 4px 0 #dfe2e8,
    0 7px 15px rgba(20, 25, 35, 0.045);

  cursor: pointer;

  transition:
    transform 200ms ease,
    border-color 200ms ease,
    box-shadow 200ms ease,
    background 200ms ease;
}

.app-shortcut:hover,
.shortcut:hover,
.desktop-icon:hover,
.app-card:hover,
.launcher-item:hover {
  border-color: rgba(227, 38, 54, 0.5);

  background: linear-gradient(
    145deg,
    #ffffff 0%,
    #fff0f1 100%
  );

  box-shadow:
    0 4px 0 #e7b8bd,
    0 9px 24px rgba(227, 38, 54, 0.12);

  transform: translateY(-4px);
}

.app-shortcut:active,
.shortcut:active,
.desktop-icon:active,
.app-card:active,
.launcher-item:active {
  transform: translateY(2px);
  box-shadow: 0 1px 0 #dfe2e8;
}

.app-shortcut > span:last-child,
.shortcut > span:last-child,
.desktop-icon > span:last-child {
  font-size: 13px;
  font-weight: 750;
}

/* IKONY APLIKACJI */

.app-icon,
.shortcut-icon,
.icon-box,
.app-symbol {
  display: flex;
  align-items: center;
  justify-content: center;

  width: 55px;
  height: 55px;
  flex-shrink: 0;

  color: white;

  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 15px;

  background: linear-gradient(
    145deg,
    #ff6473 0%,
    #e32636 55%,
    #a70f22 100%
  );

  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.45),
    0 4px 0 #8f1020,
    0 7px 12px rgba(227, 38, 54, 0.2);

  font-size: 23px;
  font-weight: 850;
}

/* =========================================
   UNIWERSALNE KARTY I PANELE
   ========================================= */

.card,
.panel,
.widget,
.settings-card,
.info-card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 18px;
  box-shadow: var(--shadow);
}

.card h2,
.panel h2,
.widget h2,
.settings-card h2,
.info-card h2 {
  margin-top: 0;
  font-size: 17px;
  font-weight: 800;
}

.card p,
.panel p,
.widget p,
.settings-card p,
.info-card p {
  color: var(--muted);
}

/* =========================================
   OKNA APLIKACJI
   ========================================= */

#window-layer,
.window-layer,
.windows-layer {
  position: absolute;
  inset: 0;
  z-index: 10;

  pointer-events: none;
}

.window,
.app-window,
.window-panel,
.app-panel {
  position: absolute;
  overflow: hidden;

  min-width: 260px;

  background: #ffffff;
  color: var(--text);

  border: 1px solid #d8dce4;
  border-top: 3px solid var(--red);
  border-radius: 15px;

  box-shadow:
    0 22px 60px rgba(20, 25, 35, 0.18),
    0 5px 15px rgba(20, 25, 35, 0.08);

  pointer-events: auto;
}

.window-header,
.window-titlebar,
.titlebar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;

  min-height: 48px;
  padding: 8px 12px;

  background: linear-gradient(
    180deg,
    #ffffff 0%,
    #f5f6f8 100%
  );

  border-bottom: 1px solid var(--border);
  cursor: grab;
  user-select: none;
}

.window-header:active,
.window-titlebar:active,
.titlebar:active {
  cursor: grabbing;
}

.window-title,
.window-header h2,
.window-titlebar h2,
.titlebar h2 {
  margin: 0;
  font-size: 13px;
  font-weight: 800;
}

.window-controls {
  display: flex;
  align-items: center;
  gap: 5px;
}

.window-controls button,
.window-close,
.close-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  width: 30px;
  height: 30px;
  padding: 0;

  border-radius: 8px;
  box-shadow: none;

  background: transparent;
  color: var(--muted);
}

.window-controls button:hover,
.window-close:hover,
.close-button:hover {
  background: #ffe5e7;
  color: var(--red-dark);
}

.window-content,
.window-body,
.app-content {
  padding: 18px;
  overflow: auto;
  max-height: calc(100dvh - 180px);
}

/* =========================================
   POLA TEKSTOWE I NOTATKI
   ========================================= */

input,
textarea,
select {
  width: 100%;
  padding: 11px 12px;

  color: var(--text);
  background: #fbfbfc;

  border: 1px solid #d8dce4;
  border-radius: 10px;

  outline: none;

  transition:
    border-color var(--transition),
    box-shadow var(--transition),
    background var(--transition);
}

input:hover,
textarea:hover,
select:hover {
  border-color: #b8bdc8;
}

input:focus,
textarea:focus,
select:focus {
  background: #ffffff;
  border-color: var(--red);

  box-shadow: 0 0 0 3px rgba(227, 38, 54, 0.1);
}

textarea {
  min-height: 120px;
  resize: vertical;
}

label {
  display: block;
  margin-bottom: 6px;
  font-weight: 700;
}

input[type="checkbox"],
input[type="radio"] {
  width: auto;
  accent-color: var(--red);
}

/* =========================================
   DOLNY PASEK / DOCK
   ========================================= */

.taskbar,
#taskbar,
.dock,
.bottom-bar {
  position: fixed;
  left: 14px;
  right: 14px;
  bottom: 12px;
  z-index: 100;

  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 9px;

  min-height: 58px;
  padding: 8px 12px;

  background: rgba(255, 255, 255, 0.93);
  border: 1px solid rgba(210, 214, 224, 0.95);
  border-radius: 17px;

  box-shadow:
    0 10px 35px rgba(20, 25, 35, 0.13),
    inset 0 1px 0 #ffffff;

  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.taskbar button,
#taskbar button,
.dock button,
.bottom-bar button {
  flex-shrink: 0;
  padding: 9px 13px;
  border-radius: 10px;
}

.taskbar button:hover,
#taskbar button:hover,
.dock button:hover,
.bottom-bar button:hover {
  transform: translateY(-2px);
}

/* =========================================
   MENU START
   ========================================= */

#start-menu,
.start-menu,
.launcher-menu {
  position: fixed;
  left: 14px;
  bottom: 84px;
  z-index: 200;

  width: min(340px, calc(100vw - 28px));
  max-height: min(70vh, 600px);
  overflow-y: auto;

  padding: 18px;

  background: rgba(255, 255, 255, 0.97);
  border: 1px solid var(--border);
  border-top: 3px solid var(--red);
  border-radius: 17px;

  box-shadow:
    0 20px 60px rgba(20, 25, 35, 0.2),
    0 0 25px rgba(227, 38, 54, 0.06);

  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

#start-menu h2,
.start-menu h2,
.launcher-menu h2 {
  margin: 0 0 14px;
  font-size: 18px;
  font-weight: 850;
}

#start-menu button,
.start-menu button,
.launcher-menu button {
  width: 100%;
  margin-bottom: 8px;
  text-align: left;
}

/* =========================================
   POWIADOMIENIA
   ========================================= */

#toast,
.toast,
.notification,
.notification-toast {
  position: fixed;
  right: 20px;
  top: 78px;
  z-index: 1000;

  max-width: min(360px, calc(100vw - 40px));
  padding: 13px 16px;

  color: var(--text);
  background: #ffffff;

  border: 1px solid #e1e4ea;
  border-left: 4px solid var(--red);
  border-radius: 11px;

  box-shadow: 0 10px 30px rgba(20, 25, 35, 0.13);
}

/* =========================================
   SCROLLOWANIE
   ========================================= */

* {
  scrollbar-width: thin;
  scrollbar-color: #d1d5de transparent;
}

::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: #d1d5de;
  border: 2px solid transparent;
  background-clip: padding-box;
  border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
  background: #e32636;
  border: 2px solid transparent;
  background-clip: padding-box;
}

/* =========================================
   MOTYW CIEMNY
   Działa, jeśli aplikacja używa jednego z:
   data-theme="dark", .dark-theme lub .theme-dark
   ========================================= */

[data-theme="dark"],
.dark-theme,
.theme-dark {
  color-scheme: dark;

  --bg: #11141b;
  --panel: #1c2029;
  --panel-soft: #242934;
  --text: #f3f4f7;
  --muted: #a6adba;
  --border: #363c49;

  --shadow:
    0 8px 24px rgba(0, 0, 0, 0.24),
    0 2px 5px rgba(0, 0, 0, 0.15);
}

[data-theme="dark"] body,
.dark-theme body,
.theme-dark body {
  background: var(--bg);
  color: var(--text);
}

[data-theme="dark"] .topbar,
[data-theme="dark"] #topbar,
[data-theme="dark"] .taskbar,
[data-theme="dark"] #taskbar,
[data-theme="dark"] .dock,
[data-theme="dark"] #start-menu,
[data-theme="dark"] .start-menu,
.dark-theme .topbar,
.dark-theme #topbar,
.dark-theme .taskbar,
.dark-theme #taskbar,
.dark-theme .dock,
.dark-theme #start-menu,
.dark-theme .start-menu,
.theme-dark .topbar,
.theme-dark #topbar,
.theme-dark .taskbar,
.theme-dark #taskbar,
.theme-dark .dock,
.theme-dark #start-menu,
.theme-dark .start-menu {
  background: rgba(28, 32, 41, 0.96);
  border-color: var(--border);
}

[data-theme="dark"] .welcome,
[data-theme="dark"] #welcome,
[data-theme="dark"] .welcome-panel,
[data-theme="dark"] .hero,
[data-theme="dark"] .hero-card,
[data-theme="dark"] .card,
[data-theme="dark"] .panel,
[data-theme="dark"] .widget,
[data-theme="dark"] .app-shortcut,
[data-theme="dark"] .shortcut,
[data-theme="dark"] .desktop-icon,
.dark-theme .welcome,
.dark-theme #welcome,
.dark-theme .welcome-panel,
.dark-theme .hero,
.dark-theme .hero-card,
.dark-theme .card,
.dark-theme .panel,
.dark-theme .widget,
.dark-theme .app-shortcut,
.dark-theme .shortcut,
.dark-theme .desktop-icon,
.theme-dark .welcome,
.theme-dark #welcome,
.theme-dark .welcome-panel,
.theme-dark .hero,
.theme-dark .hero-card,
.theme-dark .card,
.theme-dark .panel,
.theme-dark .widget,
.theme-dark .app-shortcut,
.theme-dark .shortcut,
.theme-dark .desktop-icon {
  background: linear-gradient(
    145deg,
    #242934 0%,
    #1a1e27 100%
  );

  border-color: var(--border);
  color: var(--text);
}

[data-theme="dark"] .window,
[data-theme="dark"] .app-window,
[data-theme="dark"] .window-panel,
.dark-theme .window,
.dark-theme .app-window,
.dark-theme .window-panel,
.theme-dark .window,
.theme-dark .app-window,
.theme-dark .window-panel {
  background: #1c2029;
  color: var(--text);
  border-color: #3a404e;
  border-top-color: var(--red);
}

[data-theme="dark"] .window-header,
[data-theme="dark"] .window-titlebar,
[data-theme="dark"] .titlebar,
.dark-theme .window-header,
.dark-theme .window-titlebar,
.dark-theme .titlebar,
.theme-dark .window-header,
.theme-dark .window-titlebar,
.theme-dark .titlebar {
  background: #242934;
  border-color: var(--border);
}

[data-theme="dark"] input,
[data-theme="dark"] textarea,
[data-theme="dark"] select,
.dark-theme input,
.dark-theme textarea,
.dark-theme select,
.theme-dark input,
.theme-dark textarea,
.theme-dark select {
  background: #151820;
  color: var(--text);
  border-color: var(--border);
}

[data-theme="dark"] button,
.dark-theme button,
.theme-dark button {
  border-color: #414755;
  background: linear-gradient(
    180deg,
    #303541 0%,
    #252a35 100%
  );

  color: var(--text);

  box-shadow:
    0 3px 0 #151820,
    0 5px 10px rgba(0, 0, 0, 0.14);
}

[data-theme="dark"] button:hover,
.dark-theme button:hover,
.theme-dark button:hover {
  border-color: rgba(255, 82, 98, 0.7);
  background: linear-gradient(
    180deg,
    #3b3038 0%,
    #2d242d 100%
  );
}

[data-theme="dark"] .primary-button,
[data-theme="dark"] .btn-primary,
[data-theme="dark"] #start-button,
.dark-theme .primary-button,
.dark-theme .btn-primary,
.dark-theme #start-button,
.theme-dark .primary-button,
.theme-dark .btn-primary,
.theme-dark #start-button {
  background: linear-gradient(
    180deg,
    #ff5969 0%,
    #e32636 48%,
    #bd1528 100%
  );

  color: #ffffff;
  border-color: var(--red-dark);
}

/* =========================================
   TELEFONY I MAŁE EKRANY
   ========================================= */

.account-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  white-space: nowrap;
}

.account-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #89909b;
}

.account-indicator.is-authenticated {
  background: #27945a;
  box-shadow: 0 0 0 3px rgba(39, 148, 90, 0.14);
}

.account-dialog {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(20, 25, 35, 0.48);
  backdrop-filter: blur(5px);
}

.account-panel {
  width: min(100%, 420px);
  padding: 24px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-top: 3px solid var(--red);
  border-radius: 12px;
  box-shadow: 0 24px 70px rgba(20, 25, 35, 0.24);
}

.account-panel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}

.account-panel-header .eyebrow {
  margin: 0 0 4px;
}

.account-panel-header h2 {
  margin: 0;
  font-size: 22px;
}

.account-close {
  width: 36px;
  height: 36px;
  padding: 0;
  font-size: 23px;
  line-height: 1;
}

.account-mode {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  margin-bottom: 20px;
  padding: 4px;
  background: var(--panel-soft);
  border: 1px solid var(--border);
  border-radius: 9px;
}

.account-mode button {
  padding: 8px;
  background: transparent;
  border-color: transparent;
  box-shadow: none;
}

.account-mode button[aria-pressed="true"] {
  background: var(--panel);
  border-color: var(--border);
  box-shadow: 0 1px 4px rgba(20, 25, 35, 0.08);
}

#account-form {
  display: grid;
  gap: 9px;
}

#account-form label {
  margin-top: 5px;
  font-weight: 700;
}

#account-form input {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  color: var(--text);
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 8px;
}

#account-submit {
  min-height: 44px;
  margin-top: 12px;
}

.account-signed-in {
  padding: 14px 0 4px;
}

.account-caption,
.account-email {
  margin: 0 0 8px;
}

.account-caption,
.account-status {
  color: var(--muted);
}

.account-email {
  overflow-wrap: anywhere;
  font-weight: 700;
}

.account-signed-in button {
  margin-top: 12px;
}

.account-status {
  min-height: 21px;
  margin: 14px 0 0;
  font-size: 13px;
}

@media (max-width: 600px) {
  .account-button {
    padding: 7px 9px;
  }

  .account-panel {
    padding: 20px;
  }
}

@media (max-width: 600px) {
  body {
    font-size: 13px;
  }

  .topbar,
  #topbar,
  .system-bar,
  .status-bar {
    min-height: 54px;
    padding: 8px 12px;
    gap: 8px;
  }

  .welcome,
  #welcome,
  .welcome-panel,
  .hero,
  .hero-card {
    margin: 12px;
    padding: 18px;
  }

  .welcome h1,
  #welcome h1,
  .welcome-panel h1,
  .hero h1,
  .hero-card h1 {
    font-size: 26px;
  }

  .app-grid,
  #app-grid,
  .apps-grid,
  .shortcuts,
  .desktop-icons,
  .launcher-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 11px;
    padding: 12px;
  }

  .app-shortcut,
  .shortcut,
  .desktop-icon,
  .app-card,
  .launcher-item {
    min-height: 112px;
    padding: 13px 8px;
    gap: 9px;
    border-radius: 13px;
  }

  .app-icon,
  .shortcut-icon,
  .icon-box,
  .app-symbol {
    width: 46px;
    height: 46px;
    border-radius: 13px;
    font-size: 20px;
  }

  .taskbar,
  #taskbar,
  .dock,
  .bottom-bar {
    left: 8px;
    right: 8px;
    bottom: 8px;
    min-height: 53px;
    padding: 6px 8px;
    gap: 6px;
    border-radius: 14px;
    overflow-x: auto;
  }

  .taskbar button,
  #taskbar button,
  .dock button,
  .bottom-bar button {
    padding: 8px 10px;
    white-space: nowrap;
  }

  #start-menu,
  .start-menu,
  .launcher-menu {
    left: 8px;
    bottom: 70px;
    width: calc(100vw - 16px);
  }

  .window,
  .app-window,
  .window-panel,
  .app-panel {
    max-width: calc(100vw - 16px);
    border-radius: 12px;
  }

  .window-content,
  .window-body,
  .app-content {
    padding: 13px;
    max-height: 65dvh;
  }

  #toast,
  .toast,
  .notification,
  .notification-toast {
    top: 64px;
    right: 10px;
    max-width: calc(100vw - 20px);
  }
}

/* OGRANICZENIE ANIMACJI */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

/* =========================================
   ISOGA — POLSKI LED
   Bez niebieskiej ramki fokusu
   ========================================= */

:root {
  --isoga-led-white: #ffffff;
  --isoga-led-red: #dc143c;
}

/* Usunięcie domyślnej niebieskiej ramki */
button:focus,
button:focus-visible,
a:focus,
a:focus-visible,
[role="button"]:focus,
[role="button"]:focus-visible {
  outline: none !important;
}

/* Biało-czerwony LED po kliknięciu */
button:active,
[role="button"]:active {
  border-color: var(--isoga-led-red) !important;
  box-shadow:
    0 0 5px rgba(220, 20, 60, 0.75),
    0 0 12px rgba(220, 20, 60, 0.35),
    inset 0 0 5px rgba(255, 255, 255, 0.35) !important;
  transform: scale(0.97);
  transition:
    transform 120ms ease,
    box-shadow 120ms ease,
    border-color 120ms ease;
}

/* Subtelny biało-czerwony efekt dla zaznaczonego przycisku */
button:focus-visible {
  box-shadow:
    0 0 4px rgba(255, 255, 255, 0.8),
    0 0 9px rgba(220, 20, 60, 0.65) !important;
}

/* Animacja powrotu przycisku */
button {
  transition:
    transform 120ms ease,
    box-shadow 160ms ease,
    border-color 160ms ease;
}
