﻿/* в•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђ
   design-system.css  вЂ”  v2  (clean, no !important)
   Override layer. Loads AFTER styles.css.
   в•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђв•ђ */

/* в”Ђв”Ђ Smooth everything! в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html {
  scroll-behavior: smooth;
}

body {
  background: #eef2f7;
  transition: background 0.3s, color 0.3s;
}

/* в”Ђв”Ђ Subtle background animation в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  background:
    radial-gradient(ellipse at 15% 0%,   rgba(16,185,129,0.055) 0%, transparent 55%),
    radial-gradient(ellipse at 85% 100%, rgba(100,150,210,0.05)  0%, transparent 55%);
  animation: bgShift 30s ease-in-out infinite alternate;
}

@keyframes bgShift {
  0%   { background-position: 0% 0%, 100% 100%; }
  50%  { background-position: 30% 10%, 70% 90%; }
  100% { background-position: 10% 30%, 90% 70%; }
}

/* в”Ђв”Ђ Page transitions в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
#app > * {
  animation: fadeIn 0.25s ease-out both;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* в”Ђв”Ђ Better focus ring (accessibility) в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
:focus-visible {
  outline: 2px solid var(--c-primary, #1E4D5C);
  outline-offset: 2px;
  border-radius: 4px;
}

/* Stage chips (photo_point.js) — TASK11
   Прості значки + власний колір кожної стадії ЗАВЖДИ (не лише при виборі):
   before = синій, during = помаранчевий, after = зелений.
   Вибраний чіп заливається своїм кольором; невибрані — бліді (opacity .55).
   --c-before/--c-during/--c-after однакові в light і dark;
   --c-*-bg перевизначені для dark у блоці DARK MODE. */
.stage-chip-group {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  gap: 0.5rem;
}
.stage-chip {
  --stage-c: var(--c-text-muted);
  --stage-soft: var(--c-surface-alt);
  display: flex;
  flex: 1 1 0;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  width: auto;
  min-width: 0;
  min-height: 64px;
  padding: 0.55rem 0.4rem;
  border: 2px solid var(--stage-c);
  border-radius: var(--r-md);
  background: var(--stage-soft);
  color: var(--stage-c);
  font-family: var(--font);
  font-size: 0.82rem;
  font-weight: 600;
  text-align: center;
  cursor: pointer;
  opacity: 0.55;
  position: relative;
  overflow: hidden;
  transition: all 0.18s cubic-bezier(0.4, 0, 0.2, 1);
}
.stage-chip-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  color: var(--stage-c);
}
.stage-svg {
  width: 100%;
  height: 100%;
  display: block;
  transition: stroke 0.2s ease;
}
.stage-chip-label {
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
}

/* States */
.stage-chip:hover { opacity: 0.85; }
.stage-chip:focus-visible {
  opacity: 1;
  outline: 2px solid var(--stage-c);
  outline-offset: 2px;
  border-radius: var(--r-md);
}
.stage-chip:active { transform: scale(0.97); }

/* Вибрана стадія — яскрава заливка своїм кольором, біла іконка */
.stage-chip--active {
  opacity: 1;
  background: var(--stage-c);
  border-color: var(--stage-c);
  color: #fff;
  box-shadow: var(--sh-sm);
}
.stage-chip--active .stage-chip-icon { color: #fff; }
.stage-chip--active .stage-svg { stroke: #fff; }
.stage-chip--active .stage-chip-label { font-weight: 800; }

/* Кольори стадій */
.stage-chip[data-stage="before"] { --stage-c: var(--c-before); --stage-soft: var(--c-before-bg); }
.stage-chip[data-stage="during"] { --stage-c: var(--c-during); --stage-soft: var(--c-during-bg); }
.stage-chip[data-stage="after"]  { --stage-c: var(--c-after);  --stage-soft: var(--c-after-bg); }

.stage-chip[disabled],
.stage-chip:disabled { opacity: 0.35; cursor: not-allowed; transform: none; }

/* Tooltip styling */
.stage-tooltip {
  position: absolute;
  bottom: 120%;
  left: 50%;
  transform: translateX(-50%);
  background: var(--c-surface);
  color: var(--c-text);
  padding: 0.5rem 0.75rem;
  border-radius: var(--r-sm);
  font-size: 0.75rem;
  font-weight: 500;
  white-space: normal;
  line-height: 1.4;
  max-width: 200px;
  box-shadow: var(--sh-md);
  border: 1px solid var(--c-border);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 1000;
}

.stage-chip:hover .stage-tooltip,
.stage-chip:focus-visible .stage-tooltip {
  opacity: 1;
  transform: translateX(-50%) translateY(-4px);
}

/* Ripple effect */
.stage-chip::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.4s ease, height 0.4s ease;
  pointer-events: none;
}

.stage-chip:active::after {
  width: 200px;
  height: 200px;
  opacity: 0;
}

/* Ширші екрани — три чіпи в один ряд, іконка над текстом */
@media (min-width: 560px) {
  .stage-chip-group { flex-direction: row; flex-wrap: nowrap; gap: 0.55rem; }
  .stage-chip {
    flex: 1 1 0;
    width: auto;
    flex-direction: column;
    justify-content: center;
    text-align: center;
    gap: 0.4rem;
    min-height: 72px;
  }
  .stage-chip-icon { width: 24px; height: 24px; }
  .stage-chip-label { font-size: 0.85rem; }
}

/* в”Ђв”Ђ Theme toggle button в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
.theme-toggle {
  background: rgba(255,255,255,0.09);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 8px;
  color: #dde6f0;
  width: 34px;
  height: 34px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  transition: background 0.15s, color 0.15s, transform 0.2s;
}

.theme-toggle:hover {
  background: rgba(255,255,255,0.18);
  color: #fff;
  transform: rotate(15deg);
}

/* в”Ђв”Ђ 1. APP SHELL в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
body {
  padding: 0;
}

html body .map-obj-header,
html body .map-filter-bar,
html body .object-map,
html body .map-footer,
html body .add-point-map,
html body .add-point-map-controls,
html body .view-pane--gallery {
  margin-left: 0;
  margin-right: 0;
}

/* в”Ђв”Ђ 2. TOP BAR вЂ” dark premium SaaS header в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .top-bar {
  position: sticky;
  top: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 60px;
  padding: 0 1.5rem;
  background: linear-gradient(135deg, #102E38 0%, #163842 55%, #1E4D5C 100%);
  border-bottom: 1px solid rgba(95, 168, 179, 0.25);
  box-shadow: 0 1px 0 rgba(95, 168, 179, 0.18), 0 4px 28px rgba(0, 0, 0, 0.32);
}

/* Emerald accent stripe */
html body .top-bar::after {
  content: '';
  position: absolute;
  inset: auto 0 0 0;
  height: 2px;
  background: linear-gradient(90deg,
    transparent 0%, #5FA8B3 18%, #82C4CE 50%, #5FA8B3 82%, transparent 100%);
  opacity: 0.55;
  pointer-events: none;
}

/* в”Ђв”Ђ 3. BRAND в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .app-title {
  /* [TASK11] трохи більший і повністю білий на темній шапці */
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
}

html body .app-title::before {
  content: '';
  display: inline-flex;
  width: 24px;
  height: 24px;
  border-radius: 7px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cdefs%3E%3ClinearGradient id='l' x1='0' y1='0' x2='1' y2='1'%3E%3Cstop offset='0' stop-color='%2334d399'/%3E%3Cstop offset='.55' stop-color='%2310b981'/%3E%3Cstop offset='1' stop-color='%23047857'/%3E%3C/linearGradient%3E%3C/defs%3E%3Crect width='24' height='24' rx='7' fill='url(%23l)'/%3E%3Cpath d='M12 20.5s-5.4-5-5.4-9.2A5.4 5.4 0 0 1 12 5.9a5.4 5.4 0 0 1 5.4 5.4c0 4.2-5.4 9.2-5.4 9.2z' fill='%23fff'/%3E%3Ccircle cx='12' cy='11.1' r='2.7' fill='%2310b981'/%3E%3Ccircle cx='12' cy='11.1' r='1.2' fill='%23fff'/%3E%3C/svg%3E") center / contain no-repeat;
  box-shadow: 0 2px 8px rgba(95, 168, 179, 0.4);
  flex-shrink: 0;
}

html body .app-title:hover {
  opacity: 0.82;
}

/* в”Ђв”Ђ 4. TOP-BAR ACTIONS в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .top-bar-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

html body .top-bar-pill-btn {
  min-height: 34px;
  padding: 0.28rem 0.82rem;
  font-size: 0.78rem;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.09);
  color: #dde6f0;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 7px;
  cursor: pointer;
  font-family: inherit;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  white-space: nowrap;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}

html body .top-bar-pill-btn:hover {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.28);
  text-decoration: none;
}

/* в”Ђв”Ђ 5. PAGE в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .page {
  max-width: 780px;
  margin: 0 auto;
  padding: 2rem 1.5rem 4rem;
}

/* в”Ђв”Ђ 6. PAGE HEADER в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .page-header {
  margin-bottom: 2rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid #dde3ed;
}

html body .page-header h2 {
  font-size: 1.9rem;
  font-weight: 800;
  letter-spacing: -0.045em;
  color: #0d1a2e;
  line-height: 1.1;
}

/* в”Ђв”Ђ 7. OBJECT CARDS в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .object-card {
  background: #ffffff;
  border-radius: 14px;
  border: 1px solid #E7E2DA;
  padding: 1.3rem 1.5rem 1.3rem 1.85rem;
  box-shadow: 0 1px 2px rgba(20, 36, 46, 0.04), 0 4px 18px rgba(20, 36, 46, 0.055);
  transition: border-color 0.2s, box-shadow 0.22s, transform 0.2s;
}

html body .object-card-link:hover .object-card {
  border-color: #adb8ca;
  box-shadow: 0 4px 16px rgba(20, 36, 46, 0.13), 0 1px 4px rgba(20, 36, 46, 0.08);
  transform: translateY(-3px);
}

html body .object-card-link:active .object-card {
  transform: translateY(0);
  box-shadow: 0 1px 3px rgba(20, 36, 46, 0.06);
}

html body .object-name {
  /* [TASK11] було 1rem / 700 — назва була тьмяною на телефоні */
  font-size: 1.08rem;
  font-weight: 800;
  color: #14242E;
  letter-spacing: -0.02em;
}

/* в”Ђв”Ђ 8. ADD-OBJECT BUTTON в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .add-object-btn {
  background: linear-gradient(135deg, #1E4D5C 0%, #3A7A8A 100%);
  border-radius: 12px;
  font-size: 0.93rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  min-height: 50px;
  box-shadow: 0 2px 4px rgba(30, 77, 92, 0.3), 0 6px 20px rgba(30, 77, 92, 0.18);
  margin-bottom: 1.25rem;
  transition: transform 0.15s, box-shadow 0.15s;
}

html body .add-object-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(30, 77, 92, 0.38), 0 12px 28px rgba(30, 77, 92, 0.2);
}

html body .add-object-btn:active {
  transform: translateY(0);
}

/* в”Ђв”Ђ 9. GENERAL BUTTONS в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .btn {
  border-radius: 10px;
  font-weight: 700;
  box-shadow: 0 1px 3px rgba(30, 77, 92, 0.22), 0 3px 10px rgba(30, 77, 92, 0.14);
  transition: transform 0.12s, box-shadow 0.12s, opacity 0.12s;
}

html body .btn:hover:not(:disabled):not([disabled]) {
  opacity: 0.93;
  box-shadow: 0 2px 5px rgba(30, 77, 92, 0.3), 0 6px 18px rgba(30, 77, 92, 0.18);
}

/* в”Ђв”Ђ 10. SEARCH INPUT в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .search-input {
  background: #ffffff;
  border: 1.5px solid #DAD4C9;
  border-radius: 10px;
  box-shadow: 0 1px 3px rgba(20, 36, 46, 0.04);
  transition: border-color 0.15s, box-shadow 0.15s;
}

html body .search-input:focus {
  background: #fff;
  border-color: #3A7A8A;
  box-shadow: 0 0 0 3px rgba(95, 168, 179, 0.12), 0 1px 3px rgba(20, 36, 46, 0.04);
}

/* в”Ђв”Ђ 11. FORMS в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .form-section {
  background: #ffffff;
  border: 1px solid #E7E2DA;
  border-radius: 14px;
  padding: 1.5rem 1.5rem 0.5rem;
  box-shadow: 0 1px 3px rgba(20, 36, 46, 0.04), 0 4px 14px rgba(20, 36, 46, 0.04);
  margin-bottom: 1.25rem;
}

html body .form-group input,
html body .form-group select,
html body .form-group textarea {
  background: #F7F4EE;
  border: 1.5px solid #DAD4C9;
  border-radius: 8px;
  transition: border-color 0.15s, box-shadow 0.15s, background 0.15s;
}

html body .form-group input:focus,
html body .form-group select:focus,
html body .form-group textarea:focus {
  background: #ffffff;
  border-color: #3A7A8A;
  box-shadow: 0 0 0 3px rgba(95, 168, 179, 0.12);
  outline: none;
}

/* в”Ђв”Ђ 11b. LOGIN SCREEN вЂ” modern card в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .screen {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  gap: 0;
}

html body .screen-brand {
  text-align: center;
  margin-bottom: 0;
  padding: 2rem 2rem 0.5rem;
  max-width: 420px;
  width: 100%;
}

html body .screen-logo {
  width: 64px;
  height: 64px;
  margin: 0 auto 0.75rem;
  background: linear-gradient(135deg, #DCE9EC 0%, #B8D4D8 100%);
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #1E4D5C;
  box-shadow: 0 4px 12px rgba(95, 168, 179, 0.25);
  transition: transform 0.2s;
}

html body .screen-logo:hover {
  transform: scale(1.05);
}

html body .screen-logo svg {
  width: 32px;
  height: 32px;
}

html body .screen-brand h1 {
  font-size: 1.65rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: #14242E;
}

html body .screen-subtitle {
  font-size: 0.88rem;
  color: #5E727D;
  margin-top: 0.2rem;
}

html body #login-form {
  background: #ffffff;
  border: 1px solid #E7E2DA;
  border-radius: 16px;
  padding: 2rem;
  max-width: 420px;
  width: 100%;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04), 0 8px 32px rgba(0,0,0,0.06);
}

html body #login-form .form-group {
  margin-bottom: 1.25rem;
}

html body #login-form label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: #5E727D;
  margin-bottom: 0.35rem;
}

html body #login-form input {
  width: 100%;
  padding: 0.7rem 0.85rem;
  font-size: 0.92rem;
  background: #F7F4EE;
  border: 1.5px solid #E7E2DA;
  border-radius: 10px;
  font-family: inherit;
  transition: border-color 0.15s, box-shadow 0.15s, background 0.15s;
}

html body #login-form input:focus {
  background: #fff;
  border-color: #3A7A8A;
  box-shadow: 0 0 0 3px rgba(95, 168, 179, 0.12);
  outline: none;
}

html body #login-form .btn {
  width: 100%;
  margin-top: 0.75rem;
  padding: 0.8rem;
  font-size: 0.95rem;
}

html body .screen-links {
  text-align: center;
  margin-top: 1.25rem;
  max-width: 420px;
  width: 100%;
  font-size: 0.85rem;
}

html body .screen-links a {
  color: #1E4D5C;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.15s;
}

html body .screen-links a:hover {
  color: #163842;
  text-decoration: underline;
}

html body .screen-links-sep {
  color: #94a3b8;
  margin: 0 0.5rem;
}

/* в”Ђв”Ђ 12. TEAM MEMBER CARDS в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .team-member-card {
  background: #ffffff;
  border-radius: 14px;
  border: 1px solid #E7E2DA;
  padding: 1.1rem 1.4rem;
  box-shadow: 0 1px 3px rgba(20, 36, 46, 0.04), 0 4px 14px rgba(20, 36, 46, 0.04);
  margin-bottom: 0.75rem;
  transition: border-color 0.18s, box-shadow 0.2s, transform 0.18s;
}

html body .team-member-card:hover {
  border-color: #adb8ca;
  box-shadow: 0 4px 18px rgba(20, 36, 46, 0.12);
  transform: translateY(-2px);
}

html body .team-member-card--inactive {
  background: #F5F2EC;
  opacity: 0.85;
}

html body .team-member-card--pending {
  border-left: 3px solid var(--c-warning);
  background: #FBF6E9;
}

/* в”Ђв”Ђ 13. ADMIN CARDS в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .admin-baul-card {
  background: #ffffff;
  border-radius: 14px;
  border: 1px solid #E7E2DA;
  padding: 1.1rem 1.4rem 1.1rem 1.6rem;
  box-shadow: 0 1px 3px rgba(20, 36, 46, 0.04), 0 4px 14px rgba(20, 36, 46, 0.04);
  margin-bottom: 0.8rem;
  transition: border-color 0.18s, box-shadow 0.2s, transform 0.18s;
}

html body .admin-baul-card:hover {
  border-color: #adb8ca;
  box-shadow: 0 4px 18px rgba(20, 36, 46, 0.12);
  transform: translateY(-2px);
}

/* в”Ђв”Ђ 14. BACK LINK в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .back-link {
  background: #ffffff;
  border: 1px solid #E7E2DA;
  border-radius: 8px;
  color: #5E727D;
  box-shadow: 0 1px 2px rgba(20, 36, 46, 0.05);
  transition: background 0.15s, box-shadow 0.15s, color 0.15s;
}

html body .back-link:hover {
  background: #F7F4EE;
  box-shadow: 0 2px 8px rgba(20, 36, 46, 0.1);
  color: #14242E;
  text-decoration: none;
}

/* в”Ђв”Ђ 15. PHOTO PICKER в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .photo-preview-area {
  background: linear-gradient(135deg, #F4F1EA 0%, #EBE7DE 100%);
  border: 2px dashed #C9C2B6;
  border-radius: 12px;
  transition: border-color 0.2s, background 0.2s;
}

html body .photo-preview-area:hover {
  border-color: #3A7A8A;
  background: linear-gradient(135deg, #E9F3EC 0%, #E4EFE9 100%);
}

html body .photo-pick-btn-large {
  background: linear-gradient(135deg, #1E4D5C 0%, #3A7A8A 100%);
  border-radius: 12px;
  font-weight: 700;
  color: #fff;
  box-shadow: 0 2px 4px rgba(30, 77, 92, 0.3), 0 6px 18px rgba(30, 77, 92, 0.16);
}

/* в”Ђв”Ђ 15b. PHOTO GRID в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 0.75rem;
}

html body .photo-thumb {
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
  transition: transform 0.2s, box-shadow 0.2s;
  aspect-ratio: 1;
  object-fit: cover;
  cursor: pointer;
}

html body .photo-thumb:hover {
  transform: scale(1.03);
  box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

/* в”Ђв”Ђ 15c. LOADING SKELETON в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .skeleton {
  background: linear-gradient(90deg, #E7E2DA 25%, #F6F4EF 50%, #E7E2DA 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s ease-in-out infinite;
  border-radius: 8px;
}

@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

html body .skeleton-card {
  height: 120px;
  margin-bottom: 0.75rem;
}

html body .skeleton-text {
  height: 14px;
  width: 60%;
  margin-bottom: 0.5rem;
}

html body .skeleton-text--short {
  width: 40%;
}

html body .skeleton-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
}

/* в”Ђв”Ђ 15d. TOAST / NOTIFICATION в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .toast {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  background: #163842;
  color: #E2ECF0;
  padding: 0.75rem 1.5rem;
  border-radius: 12px;
  font-size: 0.85rem;
  font-weight: 600;
  box-shadow: 0 4px 20px rgba(0,0,0,0.25);
  z-index: 9999;
  animation: toastIn 0.3s ease-out, toastOut 0.3s ease-in 2.5s forwards;
}

@keyframes toastIn {
  from { opacity: 0; transform: translateX(-50%) translateY(20px); }
  to   { opacity: 1; transform: translateX(-50%) translateY(0); }
}

@keyframes toastOut {
  from { opacity: 1; }
  to   { opacity: 0; transform: translateX(-50%) translateY(-10px); }
}

/* в”Ђв”Ђ 16. CREDENTIALS PANEL в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .credentials-panel {
  background: linear-gradient(135deg, #E9F1F2 0%, #F4F7F5 100%);
  border: 1px solid #C9E2E6;
  border-left: 4px solid #1E4D5C;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(95, 168, 179, 0.1);
}

/* в”Ђв”Ђ 17. EMPTY STATE в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .empty-state {
  background: #ffffff;
  border: 2px dashed #d5dce8;
  border-radius: 16px;
}

/* в”Ђв”Ђ 18. MAP HEADER в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .map-obj-header {
  background: #ffffff;
  border-bottom: 1px solid #e2e8f2;
}

/* в”Ђв”Ђ 19. MAP CONTROLS в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
html body .add-point-map-controls {
  background: #ffffff;
  border-top: 1px solid #e2e8f2;
  border-bottom: 1px solid #e2e8f2;
}

/* в”Ђв”Ђ 20. MICRO-ANIMATIONS (life!) в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */

/* Card entry animation */
.object-card-link {
  animation: cardIn 0.35s ease-out both;
}

@keyframes cardIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Slow pulse on the logo icon */
html body .app-title::before {
  animation: logoPulse 4s ease-in-out infinite;
}

@keyframes logoPulse {
  0%, 100% { box-shadow: 0 2px 8px rgba(16,185,129,0.4); }
  50%      { box-shadow: 0 2px 12px rgba(16,185,129,0.6); }
}

/* в”Ђв”Ђ 21. MOBILE в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
@media (max-width: 640px) {
  html body .top-bar {
    padding-left: 1rem;
    padding-right: 1rem;
    padding-top: calc(0.6rem + env(safe-area-inset-top, 0));
    padding-bottom: 0.5rem;
    min-height: 52px;
  }

  html body .page {
    padding: 1.25rem 1rem 3rem;
  }
}

/* в”Ђв”Ђ 22. MARKER PREVIEW в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
.marker-preview-wrapper,
.marker-preview-wrapper .leaflet-div-icon,
.marker-preview-wrapper > div {
  background: none;
  border: none;
}

.marker-preview {
  transition: transform 0.15s, box-shadow 0.15s;
  cursor: pointer;
}

.marker-preview:hover {
  transform: scale(1.15);
  z-index: 1000;
}

/* Floating lock button for object map */
/* NOTE: the button IS the Leaflet control element (Leaflet adds the
   'leaflet-control' class to it), so the selector must be
   '.leaflet-control.map-lock-btn' (no space) to match. */
.leaflet-control.map-lock-btn {
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 8px;
  /* Comfortable touch target */
  min-width: 44px;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 1px 4px rgba(0,0,0,0.15);
  line-height: 1;
  margin: 10px 10px 0 0;
  transition: background 0.15s;
}

.leaflet-control.map-lock-btn:hover {
  background: #f0f0f0;
}

/* Lock state: white = locked, green = unlocked (clear visual state) */
.leaflet-control.map-lock-btn--locked {
  background: #fff;
  border-color: #ccc;
}
.leaflet-control.map-lock-btn--unlocked {
  background: #D6E4E7;
  border-color: #1E4D5C;
}
.leaflet-control.map-lock-btn--unlocked:hover {
  background: #C9E2E6;
}

/* в”Ђв”Ђ 23. DESKTOP в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
@media (min-width: 860px) {
  html body .top-bar {
    padding-left: 2rem;
    padding-right: 2rem;
  }

  html body .page {
    padding: 2.25rem 2rem 4.5rem;
  }
}

/* в”Ђв”Ђ 23b. MOBILE COLLAPSIBLE FILTER BAR в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
.filter-bar-toggle {
  display: none;
}

@media (max-width: 640px) {
  .filter-bar-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 44px;
    padding: 0.4rem 0.5rem;
    background: var(--c-surface, #fff);
    border: none;
    border-bottom: 1px solid var(--c-border, #e5e7eb);
    text-align: center;
    font-size: 1.2rem;
    cursor: pointer;
    color: var(--c-text-secondary, #6b7280);
  }

  .filter-bar-content--collapsed {
    display: none;
  }
}

/* в”Ђв”Ђ 24. DARK MODE в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
@media (prefers-color-scheme: dark) {
  html:not([data-theme="light"]) {
    --c-bg:            #121A21;
    --c-surface:       #1A242E;
    --c-surface-alt:   #202C37;
    --c-surface-2:     #0D141A;
    --c-text:          #E2ECF0;
    --c-text-secondary: #C4D4DA;
    --c-text-muted:    #8FA8B3;
    --c-border:        #263540;
    --c-border-strong: #33475A;
    --c-border-focus:  #5FA8B3;
    --c-primary:       #5FA8B3;
    --c-primary-dark:  #82C4CE;
    --c-primary-deeper: #3A7A8A;
    --c-primary-light: rgba(95,168,179,0.16);
    --c-primary-soft:  rgba(95,168,179,0.09);
    --c-primary-ring:  #82C4CE;
    --c-accent:        #68A9B0;
    --c-accent-soft:   rgba(104, 169, 176, 0.14);
    --c-danger:        #E57373;
    --c-danger-bg:     rgba(229,115,115,0.12);
    --c-danger-border: rgba(229,115,115,0.3);
    --c-warning:       #E8BE82;
    --c-warning-bg:    rgba(232,190,130,0.12);
    --c-success:       #4CAF7A;

    /* Stage colors adjusted for dark */
    --c-before-bg:    rgba(72,133,190,0.18);
    --c-before-text:  #A9CBE8;
    --c-during-bg:    rgba(214,116,38,0.18);
    --c-during-text:  #F0B27A;
    --c-after-bg:     rgba(46,125,77,0.2);
    --c-after-text:  #7FCE9B;

    /* Status colors adjusted for dark */
    --c-active-bg:    rgba(95,168,179,0.2);
    --c-active-text:   #82C4CE;
    --c-paused-bg:    rgba(232,190,130,0.18);
    --c-paused-text:   #E8BE82;
    --c-completed-bg: rgba(110,155,215,0.18);
    --c-completed-text: #A3C2E8;
  }
  html:not([data-theme="light"]) body {
    background: var(--c-bg);
    color: var(--c-text);
  }
  html:not([data-theme="light"]) body::before {
    background:
      radial-gradient(ellipse at 15% 0%,   rgba(95,168,179,0.08) 0%, transparent 55%),
      radial-gradient(ellipse at 85% 100%, rgba(100,150,210,0.05)  0%, transparent 55%);
  }
  html:not([data-theme="light"]) .top-bar,
  html:not([data-theme="light"]) .object-card,
  html:not([data-theme="light"]) .admin-baul-card,
  html:not([data-theme="light"]) .page,
  html:not([data-theme="light"]) .map-obj-header,
  html:not([data-theme="light"]) .map-filter-bar,
  html:not([data-theme="light"]) .form-group input,
  html:not([data-theme="light"]) .form-group select,
  html:not([data-theme="light"]) .form-group textarea,
  html:not([data-theme="light"]) .filter-search-input,
  html:not([data-theme="light"]) .filter-date-input,
  html:not([data-theme="light"]) .filter-sort-select {
    background: var(--c-surface);
    color: var(--c-text);
  }
  html:not([data-theme="light"]) .object-card:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.4);
  }
  html:not([data-theme="light"]) .status-badge.status-active {
    background: var(--c-active-bg);
    color: var(--c-active-text);
  }
  html:not([data-theme="light"]) .status-badge.status-paused {
    background: var(--c-paused-bg);
    color: var(--c-paused-text);
  }
  html:not([data-theme="light"]) .status-badge.status-completed {
    background: var(--c-completed-bg);
    color: var(--c-completed-text);
  }
  html:not([data-theme="light"]) body .form-group input,
  html:not([data-theme="light"]) body .form-group select,
  html:not([data-theme="light"]) body .form-group textarea {
    background: var(--c-surface-alt);
    color: var(--c-text);
    border-color: var(--c-border-strong);
  }
  html:not([data-theme="light"]) body .form-group input:hover,
  html:not([data-theme="light"]) body .form-group select:hover,
  html:not([data-theme="light"]) body .form-group textarea:hover { border-color: #4a5a6a; }
  html:not([data-theme="light"]) body .form-group input:focus,
  html:not([data-theme="light"]) body .form-group select:focus,
  html:not([data-theme="light"]) body .form-group textarea:focus {
    background: var(--c-surface-alt);
    color: var(--c-text);
    border-color: var(--c-border-focus);
    box-shadow: 0 0 0 3px rgba(95,168,179,0.3);
  }
  html:not([data-theme="light"]) .form-group input::placeholder,
  html:not([data-theme="light"]) .form-group textarea::placeholder { color: #6b7c8a; opacity: 1; font-weight: 400; }
  html:not([data-theme="light"]) input,
  html:not([data-theme="light"]) select,
  html:not([data-theme="light"]) textarea {
    background-color: var(--c-surface-alt);
    color: var(--c-text);
    border-color: var(--c-border-strong);
  }
  html:not([data-theme="light"]) input::placeholder,
  html:not([data-theme="light"]) textarea::placeholder {
    color: #6b7c8a;
  }
  
  /* Floating lock button вЂ” much better visibility */
  html:not([data-theme="light"]) .leaflet-control.map-lock-btn {
    background: var(--c-surface-alt);
    color: var(--c-text);
    border-color: var(--c-border-strong);
    box-shadow: 0 2px 8px rgba(0,0,0,0.5);
  }
  html:not([data-theme="light"]) .leaflet-control.map-lock-btn:hover {
    background: var(--c-surface-2);
  }
  html:not([data-theme="light"]) .leaflet-control.map-lock-btn--locked {
    background: var(--c-surface-alt);
    border-color: var(--c-border-strong);
  }
  html:not([data-theme="light"]) .leaflet-control.map-lock-btn--unlocked {
    background: #163842;
    border-color: var(--c-active-text);
  }
  html:not([data-theme="light"]) .leaflet-control.map-lock-btn--unlocked:hover {
    background: #1E4D5C;
  }
  html:not([data-theme="light"]) .leaflet-popup-content-wrapper {
    background: var(--c-surface);
    color: var(--c-text);
  }
  html:not([data-theme="light"]) .leaflet-popup-tip {
    background: var(--c-surface);
  }
  html:not([data-theme="light"]) .pwa-banner {
    background: var(--c-surface);
    color: var(--c-text);
  }
  
  /* в”Ђв”Ђ Additional dark mode component styles в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
  html:not([data-theme="light"]) .screen {
    background: var(--c-surface);
    border-color: var(--c-border);
  }
  html:not([data-theme="light"]) .screen-brand {
    background: linear-gradient(160deg, rgba(52,211,153,0.08) 0%, var(--c-surface) 60%, var(--c-bg) 100%);
    border-bottom-color: rgba(52,211,153,0.15);
  }
  html:not([data-theme="light"]) .screen-logo {
    background: linear-gradient(135deg, rgba(52,211,153,0.15) 0%, rgba(52,211,153,0.08) 100%);
    border-color: rgba(52,211,153,0.25);
    color: var(--c-active-text);
    box-shadow: 0 4px 12px rgba(52,211,153,0.15);
  }
  html:not([data-theme="light"]) .screen h1,
  html:not([data-theme="light"]) .screen h2,
  html:not([data-theme="light"]) .screen-heading,
  html:not([data-theme="light"]) .screen-brand h1 {
    color: var(--c-text);
  }
  html:not([data-theme="light"]) .screen-subtitle,
  html:not([data-theme="light"]) .screen-form-title,
  html:not([data-theme="light"]) .screen-desc {
    color: var(--c-text-secondary);
  }
  html:not([data-theme="light"]) .screen-links a { color: var(--c-active-text); }
  html:not([data-theme="light"]) #login-form {
    background: var(--c-surface);
    border-color: var(--c-border);
    box-shadow: 0 1px 3px rgba(0,0,0,0.15), 0 8px 32px rgba(0,0,0,0.25);
  }
  html:not([data-theme="light"]) #login-form label {
    color: var(--c-text-secondary);
  }
  html:not([data-theme="light"]) body #login-form input,
  html:not([data-theme="light"]) body #register-form input {
    background: var(--c-surface-alt);
    border-color: var(--c-border-strong);
    color: var(--c-text);
  }
  html:not([data-theme="light"]) body #login-form input:focus,
  html:not([data-theme="light"]) body #register-form input:focus {
    background: var(--c-surface-alt);
    border-color: var(--c-border-focus);
    color: var(--c-text);
    box-shadow: 0 0 0 3px rgba(52,211,153,0.18);
  }
  html:not([data-theme="light"]) .form-section {
    background: var(--c-surface);
    border-color: var(--c-border);
  }
  html:not([data-theme="light"]) .form-section-label {
    color: var(--c-text-muted);
  }
  html:not([data-theme="light"]) .empty-state-msg { color: var(--c-text-secondary); }
  html:not([data-theme="light"]) .page-header h2 { color: var(--c-text); }
  html:not([data-theme="light"]) .object-name { color: var(--c-text); }
  html:not([data-theme="light"]) .object-name { color: var(--c-text) !important; }
  html:not([data-theme="light"]) .object-card-body p:first-child { color: var(--c-text); }
  html:not([data-theme="light"]) .object-card-body p { color: var(--c-text-secondary); font-weight: 500; }
  html:not([data-theme="light"]) .shared-badge { background: rgba(59,130,246,0.2); color: #93c5fd; }
  html:not([data-theme="light"]) .filter-bar-toggle { background: var(--c-surface); border-color: var(--c-border); color: var(--c-text-secondary); }
  html:not([data-theme="light"]) .filter-bar-toggle:hover { border-color: var(--c-border-focus); color: var(--c-text); }
  html:not([data-theme="light"]) .map-filter-bar { background: var(--c-surface); border-bottom: 1px solid var(--c-border); }
  html:not([data-theme="light"]) .member-row { background: var(--c-surface); border-color: var(--c-border); }
  html:not([data-theme="light"]) .member-name { color: var(--c-text); }
  html:not([data-theme="light"]) .checkbox-label input[type="checkbox"] { accent-color: var(--c-active-text); }
  html:not([data-theme="light"]) .lang-menu {
    background: var(--c-surface);
    border-color: var(--c-border);
  }
  html:not([data-theme="light"]) .lang-menu-item { color: var(--c-text); }
  html:not([data-theme="light"]) .lang-menu-item:hover { background: var(--c-surface-alt); }
  html:not([data-theme="light"]) .lang-menu-item--active { color: var(--c-active-text); background: rgba(52,211,153,0.15); }
  html:not([data-theme="light"]) /* в”Ђв”Ђ 25. TASK7 вЂ” kill "white card on black" in dark theme в”Ђв”Ђв”Ђв”Ђв”Ђ
     The `html body .foo { background:#ffffff }
  html:not([data-theme="light"]) ` rules above (outside any
     media query) have specificity (0,
  html:not([data-theme="light"]) 1,
  html:not([data-theme="light"]) 2) and were beating the plain
     `.foo { background: var(--c-surface) }
  html:not([data-theme="light"]) ` dark rules (0,
  html:not([data-theme="light"]) 1,
  html:not([data-theme="light"]) 0),
  html:not([data-theme="light"]) leaving
     several surfaces white while their text turned light вЂ” "white on
     white". Re-assert the dark surface with matching specificity. */
  html body .team-member-card,
  html:not([data-theme="light"]) body .admin-baul-card,
  html:not([data-theme="light"]) body .form-section,
  html:not([data-theme="light"]) body .map-obj-header,
  html:not([data-theme="light"]) body .add-point-map-controls,
  html:not([data-theme="light"]) body .empty-state {
    background: var(--c-surface);
    border-color: var(--c-border);
    color: var(--c-text);
  }
  html:not([data-theme="light"]) body .team-member-card--inactive { background: var(--c-surface-alt); }
  html:not([data-theme="light"]) body .team-member-card--pending {
    background: #2A2318;
    border-left-color: #E8BE82;
  }
  html:not([data-theme="light"]) body .back-link {
    background: var(--c-surface);
    border-color: var(--c-border);
    color: var(--c-text-secondary);
  }
  html:not([data-theme="light"]) body .back-link:hover {
    background: var(--c-surface-2);
    border-color: var(--c-border-strong);
    color: var(--c-text);
  }
  html:not([data-theme="light"]) body #login-form {
    background: var(--c-surface);
    border-color: var(--c-border);
  }
  html:not([data-theme="light"]) body .screen-logo {
    background: linear-gradient(135deg, rgba(52,211,153,0.15) 0%, rgba(52,211,153,0.08) 100%);
    border: 1.5px solid rgba(52,211,153,0.25);
    color: var(--c-active-text);
  }
  html:not([data-theme="light"]) body .search-input,
  html:not([data-theme="light"]) body .search-input:focus {
    background-color: var(--c-surface-alt);
    color: var(--c-text);
    border-color: var(--c-border-strong);
  }
  html:not([data-theme="light"]) body .search-input:focus { border-color: var(--c-border-focus); }
  
  /* Personnel card badges: light 1px borders read as halos on dark cards */
  html:not([data-theme="light"]) body .team-badge-bauleiter { border-color: rgba(96,165,250,0.35); }
  html:not([data-theme="light"]) body .team-badge-polier { border-color: rgba(251,191,36,0.35); }
  html:not([data-theme="light"]) body .team-badge-admin,
  html:not([data-theme="light"]) body .team-badge-master,
  html:not([data-theme="light"]) body .team-badge-pending { border-color: transparent; }
  
  /* "Призначити на обвЂ™єкт" select on personnel cards */
  html:not([data-theme="light"]) body .admin-baul-assign-select {
    background: var(--c-surface-alt);
    color: var(--c-text);
    border-color: var(--c-border-strong);
  }
  html:not([data-theme="light"]) body .admin-baul-assign-select option {
    background: var(--c-surface);
    color: var(--c-text);
  }
}

/* Manual dark theme (html[data-theme="dark"]) — same rules, no media query */
  html[data-theme="dark"] {
    --c-bg:            #121A21;
    --c-surface:       #1A242E;
    --c-surface-alt:   #202C37;
    --c-surface-2:     #0D141A;
    --c-text:          #E2ECF0;
    --c-text-secondary: #C4D4DA;
    --c-text-muted:    #8FA8B3;
    --c-border:        #263540;
    --c-border-strong: #33475A;
    --c-border-focus:  #5FA8B3;
    --c-primary:       #5FA8B3;
    --c-primary-dark:  #82C4CE;
    --c-primary-deeper: #3A7A8A;
    --c-primary-light: rgba(95,168,179,0.16);
    --c-primary-soft:  rgba(95,168,179,0.09);
    --c-primary-ring:  #82C4CE;
    --c-accent:        #68A9B0;
    --c-accent-soft:   rgba(104, 169, 176, 0.14);
    --c-danger:        #E57373;
    --c-danger-bg:     rgba(229,115,115,0.12);
    --c-danger-border: rgba(229,115,115,0.3);
    --c-warning:       #E8BE82;
    --c-warning-bg:    rgba(232,190,130,0.12);
    --c-success:       #4CAF7A;

    /* Stage colors adjusted for dark */
    --c-before-bg:    rgba(72,133,190,0.18);
    --c-before-text:  #A9CBE8;
    --c-during-bg:    rgba(214,116,38,0.18);
    --c-during-text:  #F0B27A;
    --c-after-bg:     rgba(46,125,77,0.2);
    --c-after-text:  #7FCE9B;

    /* Status colors adjusted for dark */
    --c-active-bg:    rgba(95,168,179,0.2);
    --c-active-text:   #82C4CE;
    --c-paused-bg:    rgba(232,190,130,0.18);
    --c-paused-text:   #E8BE82;
    --c-completed-bg: rgba(110,155,215,0.18);
    --c-completed-text: #A3C2E8;
  }
  html[data-theme="dark"] body {
    background: var(--c-bg);
    color: var(--c-text);
  }
  html[data-theme="dark"] body::before {
    background:
      radial-gradient(ellipse at 15% 0%,   rgba(95,168,179,0.08) 0%, transparent 55%),
      radial-gradient(ellipse at 85% 100%, rgba(100,150,210,0.05)  0%, transparent 55%);
  }
  html[data-theme="dark"] .top-bar,
  html[data-theme="dark"] .object-card,
  html[data-theme="dark"] .admin-baul-card,
  html[data-theme="dark"] .page,
  html[data-theme="dark"] .map-obj-header,
  html[data-theme="dark"] .map-filter-bar,
  html[data-theme="dark"] .form-group input,
  html[data-theme="dark"] .form-group select,
  html[data-theme="dark"] .form-group textarea,
  html[data-theme="dark"] .filter-search-input,
  html[data-theme="dark"] .filter-date-input,
  html[data-theme="dark"] .filter-sort-select {
    background: var(--c-surface);
    color: var(--c-text);
  }
  html[data-theme="dark"] .object-card:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.4);
  }
  html[data-theme="dark"] .status-badge.status-active {
    background: var(--c-active-bg);
    color: var(--c-active-text);
  }
  html[data-theme="dark"] .status-badge.status-paused {
    background: var(--c-paused-bg);
    color: var(--c-paused-text);
  }
  html[data-theme="dark"] .status-badge.status-completed {
    background: var(--c-completed-bg);
    color: var(--c-completed-text);
  }
  html[data-theme="dark"] body .form-group input,
  html[data-theme="dark"] body .form-group select,
  html[data-theme="dark"] body .form-group textarea {
    background: var(--c-surface-alt);
    color: var(--c-text);
    border-color: var(--c-border-strong);
  }
  html[data-theme="dark"] body .form-group input:hover,
  html[data-theme="dark"] body .form-group select:hover,
  html[data-theme="dark"] body .form-group textarea:hover { border-color: #4a5a6a; }
  html[data-theme="dark"] body .form-group input:focus,
  html[data-theme="dark"] body .form-group select:focus,
  html[data-theme="dark"] body .form-group textarea:focus {
    background: var(--c-surface-alt);
    color: var(--c-text);
    border-color: var(--c-border-focus);
    box-shadow: 0 0 0 3px rgba(95,168,179,0.3);
  }
  html[data-theme="dark"] .form-group input::placeholder,
  html[data-theme="dark"] .form-group textarea::placeholder { color: #6b7c8a; opacity: 1; font-weight: 400; }
  html[data-theme="dark"] input,
  html[data-theme="dark"] select,
  html[data-theme="dark"] textarea {
    background-color: var(--c-surface-alt);
    color: var(--c-text);
    border-color: var(--c-border-strong);
  }
  html[data-theme="dark"] input::placeholder,
  html[data-theme="dark"] textarea::placeholder {
    color: #6b7c8a;
  }
  
  /* Floating lock button вЂ” much better visibility */
  html[data-theme="dark"] .leaflet-control.map-lock-btn {
    background: var(--c-surface-alt);
    color: var(--c-text);
    border-color: var(--c-border-strong);
    box-shadow: 0 2px 8px rgba(0,0,0,0.5);
  }
  html[data-theme="dark"] .leaflet-control.map-lock-btn:hover {
    background: var(--c-surface-2);
  }
  html[data-theme="dark"] .leaflet-control.map-lock-btn--locked {
    background: var(--c-surface-alt);
    border-color: var(--c-border-strong);
  }
  html[data-theme="dark"] .leaflet-control.map-lock-btn--unlocked {
    background: #163842;
    border-color: var(--c-active-text);
  }
  html[data-theme="dark"] .leaflet-control.map-lock-btn--unlocked:hover {
    background: #1E4D5C;
  }
  html[data-theme="dark"] .leaflet-popup-content-wrapper {
    background: var(--c-surface);
    color: var(--c-text);
  }
  html[data-theme="dark"] .leaflet-popup-tip {
    background: var(--c-surface);
  }
  html[data-theme="dark"] .pwa-banner {
    background: var(--c-surface);
    color: var(--c-text);
  }
  
  /* в”Ђв”Ђ Additional dark mode component styles в”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђв”Ђ */
  html[data-theme="dark"] .screen {
    background: var(--c-surface);
    border-color: var(--c-border);
  }
  html[data-theme="dark"] .screen-brand {
    background: linear-gradient(160deg, rgba(52,211,153,0.08) 0%, var(--c-surface) 60%, var(--c-bg) 100%);
    border-bottom-color: rgba(52,211,153,0.15);
  }
  html[data-theme="dark"] .screen-logo {
    background: linear-gradient(135deg, rgba(52,211,153,0.15) 0%, rgba(52,211,153,0.08) 100%);
    border-color: rgba(52,211,153,0.25);
    color: var(--c-active-text);
    box-shadow: 0 4px 12px rgba(52,211,153,0.15);
  }
  html[data-theme="dark"] .screen h1,
  html[data-theme="dark"] .screen h2,
  html[data-theme="dark"] .screen-heading,
  html[data-theme="dark"] .screen-brand h1 {
    color: var(--c-text);
  }
  html[data-theme="dark"] .screen-subtitle,
  html[data-theme="dark"] .screen-form-title,
  html[data-theme="dark"] .screen-desc {
    color: var(--c-text-secondary);
  }
  html[data-theme="dark"] .screen-links a { color: var(--c-active-text); }
  html[data-theme="dark"] #login-form {
    background: var(--c-surface);
    border-color: var(--c-border);
    box-shadow: 0 1px 3px rgba(0,0,0,0.15), 0 8px 32px rgba(0,0,0,0.25);
  }
  html[data-theme="dark"] #login-form label {
    color: var(--c-text-secondary);
  }
  html[data-theme="dark"] body #login-form input,
  html[data-theme="dark"] body #register-form input {
    background: var(--c-surface-alt);
    border-color: var(--c-border-strong);
    color: var(--c-text);
  }
  html[data-theme="dark"] body #login-form input:focus,
  html[data-theme="dark"] body #register-form input:focus {
    background: var(--c-surface-alt);
    border-color: var(--c-border-focus);
    color: var(--c-text);
    box-shadow: 0 0 0 3px rgba(52,211,153,0.18);
  }
  html[data-theme="dark"] .form-section {
    background: var(--c-surface);
    border-color: var(--c-border);
  }
  html[data-theme="dark"] .form-section-label {
    color: var(--c-text-muted);
  }
  html[data-theme="dark"] .empty-state-msg { color: var(--c-text-secondary); }
  html[data-theme="dark"] .page-header h2 { color: var(--c-text); }
  html[data-theme="dark"] .object-name { color: var(--c-text); }
  html[data-theme="dark"] .object-name { color: var(--c-text) !important; }
  html[data-theme="dark"] .object-card-body p:first-child { color: var(--c-text); }
  html[data-theme="dark"] .object-card-body p { color: var(--c-text-secondary); font-weight: 500; }
  html[data-theme="dark"] .shared-badge { background: rgba(59,130,246,0.2); color: #93c5fd; }
  html[data-theme="dark"] .filter-bar-toggle { background: var(--c-surface); border-color: var(--c-border); color: var(--c-text-secondary); }
  html[data-theme="dark"] .filter-bar-toggle:hover { border-color: var(--c-border-focus); color: var(--c-text); }
  html[data-theme="dark"] .map-filter-bar { background: var(--c-surface); border-bottom: 1px solid var(--c-border); }
  html[data-theme="dark"] .member-row { background: var(--c-surface); border-color: var(--c-border); }
  html[data-theme="dark"] .member-name { color: var(--c-text); }
  html[data-theme="dark"] .checkbox-label input[type="checkbox"] { accent-color: var(--c-active-text); }
  html[data-theme="dark"] .lang-menu {
    background: var(--c-surface);
    border-color: var(--c-border);
  }
  html[data-theme="dark"] .lang-menu-item { color: var(--c-text); }
  html[data-theme="dark"] .lang-menu-item:hover { background: var(--c-surface-alt); }
  html[data-theme="dark"] .lang-menu-item--active { color: var(--c-active-text); background: rgba(52,211,153,0.15); }
  html[data-theme="dark"] /* в”Ђв”Ђ 25. TASK7 вЂ” kill "white card on black" in dark theme в”Ђв”Ђв”Ђв”Ђв”Ђ
     The `html body .foo { background:#ffffff }
  html[data-theme="dark"] ` rules above (outside any
     media query) have specificity (0,
  html[data-theme="dark"] 1,
  html[data-theme="dark"] 2) and were beating the plain
     `.foo { background: var(--c-surface) }
  html[data-theme="dark"] ` dark rules (0,
  html[data-theme="dark"] 1,
  html[data-theme="dark"] 0),
  html[data-theme="dark"] leaving
     several surfaces white while their text turned light вЂ” "white on
     white". Re-assert the dark surface with matching specificity. */
  html body .team-member-card,
  html[data-theme="dark"] body .admin-baul-card,
  html[data-theme="dark"] body .form-section,
  html[data-theme="dark"] body .map-obj-header,
  html[data-theme="dark"] body .add-point-map-controls,
  html[data-theme="dark"] body .empty-state {
    background: var(--c-surface);
    border-color: var(--c-border);
    color: var(--c-text);
  }
  html[data-theme="dark"] body .team-member-card--inactive { background: var(--c-surface-alt); }
  html[data-theme="dark"] body .team-member-card--pending {
    background: #2A2318;
    border-left-color: #E8BE82;
  }
  html[data-theme="dark"] body .back-link {
    background: var(--c-surface);
    border-color: var(--c-border);
    color: var(--c-text-secondary);
  }
  html[data-theme="dark"] body .back-link:hover {
    background: var(--c-surface-2);
    border-color: var(--c-border-strong);
    color: var(--c-text);
  }
  html[data-theme="dark"] body #login-form {
    background: var(--c-surface);
    border-color: var(--c-border);
  }
  html[data-theme="dark"] body .screen-logo {
    background: linear-gradient(135deg, rgba(52,211,153,0.15) 0%, rgba(52,211,153,0.08) 100%);
    border: 1.5px solid rgba(52,211,153,0.25);
    color: var(--c-active-text);
  }
  html[data-theme="dark"] body .search-input,
  html[data-theme="dark"] body .search-input:focus {
    background-color: var(--c-surface-alt);
    color: var(--c-text);
    border-color: var(--c-border-strong);
  }
  html[data-theme="dark"] body .search-input:focus { border-color: var(--c-border-focus); }
  
  /* Personnel card badges: light 1px borders read as halos on dark cards */
  html[data-theme="dark"] body .team-badge-bauleiter { border-color: rgba(96,165,250,0.35); }
  html[data-theme="dark"] body .team-badge-polier { border-color: rgba(251,191,36,0.35); }
  html[data-theme="dark"] body .team-badge-admin,
  html[data-theme="dark"] body .team-badge-master,
  html[data-theme="dark"] body .team-badge-pending { border-color: transparent; }
  
  /* "Призначити на обвЂ™єкт" select on personnel cards */
  html[data-theme="dark"] body .admin-baul-assign-select {
    background: var(--c-surface-alt);
    color: var(--c-text);
    border-color: var(--c-border-strong);
  }
  html[data-theme="dark"] body .admin-baul-assign-select option {
    background: var(--c-surface);
    color: var(--c-text);
  }

.member-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 6px 10px;
  border: 1px solid var(--c-border, #e5e7eb);
  border-radius: 8px;
  background: var(--c-surface, #fff);
}

.member-name {
  font-size: 0.9em;
  color: var(--c-text, #111);
}

.member-remove-btn {
  background: none;
  border: none;
  color: #C0392B;
  font-size: 1em;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 6px;
}

.member-remove-btn:hover {
  background: rgba(239, 68, 68, 0.12);
}

/* Dark mode: password-toggle */
@media (prefers-color-scheme: dark) {
  html:not([data-theme="light"]) .password-toggle {
    color: #94a3b8;
  }
  html:not([data-theme="light"]) .password-toggle:hover {
    color: #E2ECF0;
  }
  html:not([data-theme="light"]) .password-toggle::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3C/svg%3E");
  }
  html:not([data-theme="light"]) .password-toggle.show::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%2360a5fa' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M17.94 17.94A10.07 10.07 0 0 1 12 20c-7 0-11-8-11-8a18.45 18.45 0 0 1 5.06-5.94M9.9 4.24A9.12 9.12 0 0 1 12 4c7 0 11 8 11 8a18.5 18.5 0 0 1-2.16 3.19m-6.72-1.07a3 3 0 1 1-4.24-4.24'/%3E%3Cline x1='1' y1='1' x2='23' y2='23'/%3E%3C/svg%3E");
  }
  html:not([data-theme="light"]) .password-wrap .form-group input,
  html:not([data-theme="light"]) .password-wrap .form-group textarea {
    padding-right: 3rem;
  }
}

/* Manual dark theme (html[data-theme="dark"]) — same rules, no media query */
  html[data-theme="dark"] .password-toggle {
    color: #94a3b8;
  }
  html[data-theme="dark"] .password-toggle:hover {
    color: #E2ECF0;
  }
  html[data-theme="dark"] .password-toggle::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3C/svg%3E");
  }
  html[data-theme="dark"] .password-toggle.show::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%2360a5fa' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M17.94 17.94A10.07 10.07 0 0 1 12 20c-7 0-11-8-11-8a18.45 18.45 0 0 1 5.06-5.94M9.9 4.24A9.12 9.12 0 0 1 12 4c7 0 11 8 11 8a18.5 18.5 0 0 1-2.16 3.19m-6.72-1.07a3 3 0 1 1-4.24-4.24'/%3E%3Cline x1='1' y1='1' x2='23' y2='23'/%3E%3C/svg%3E");
  }
  html[data-theme="dark"] .password-wrap .form-group input,
  html[data-theme="dark"] .password-wrap .form-group textarea {
    padding-right: 3rem;
  }

/* ── 26. FIX: .team-member-card stays white in dark mode ──────────────
   The "TASK7" comment above (both the @media prefers-color-scheme block
   and the html[data-theme="dark"] block) accidentally swallowed its own
   selector, so the compiled rule is the impossible
   "html:not([data-theme="light"]) html body .team-member-card" (and the
   data-theme="dark" equivalent) — an <html> element can never be nested
   inside another <html>, so it never matches. .team-member-card has a
   hardcoded #ffffff background (see section 12), so it was left white on
   a dark page. Re-declared here with a selector that actually matches. */
@media (prefers-color-scheme: dark) {
  html:not([data-theme="light"]) .team-member-card {
    background: var(--c-surface);
    border-color: var(--c-border);
    color: var(--c-text);
  }
}
html[data-theme="dark"] .team-member-card {
  background: var(--c-surface);
  border-color: var(--c-border);
  color: var(--c-text);
}

