:root { --bg:#0f1115; --fg:#e6e6e6; --accent:#f5c518; }
* { box-sizing: border-box; }
body { margin:0; font-family: system-ui, sans-serif; background:var(--bg); color:var(--fg); }
.topbar { display:flex; justify-content:space-between; align-items:center;
  padding:12px 20px; border-bottom:1px solid #222; }
.brand { font-weight:700; color:var(--accent); }
.logout { color:var(--fg); text-decoration:none; opacity:.8; }
.logout:hover { opacity:1; }
main { padding:32px 20px; }
.login { max-width:420px; margin:15vh auto; text-align:center; }
.login h1 { color:var(--accent); }
.placeholder h1 { margin-top:0; }

/* Дашборд: фильтры */
.filters { display:flex; flex-wrap:wrap; gap:8px; align-items:center; margin-bottom:20px; }
.filters input[type="date"] { padding:6px 8px; }
.filters button, .dropdown summary { cursor:pointer; padding:6px 12px; border:1px solid #333;
  background:#1b1e24; color:var(--fg); border-radius:6px; }
.filters__apply { background:var(--accent); color:#111; font-weight:600; border:none; }
.dropdown { position:relative; }
.dropdown summary { list-style:none; }
.dropdown__body { position:absolute; z-index:10; margin-top:4px; min-width:240px; max-height:320px;
  overflow:auto; background:#11141a; border:1px solid #333; border-radius:8px; padding:10px; }
.dropdown__search { width:100%; margin-bottom:8px; padding:6px; }
.dropdown__item, .dropdown__all { display:block; padding:4px 2px; }
.dropdown__empty { opacity:.6; margin:4px 2px; }

/* Дашборд: сетка плиток */
.tiles-grid { display:grid; grid-template-columns:repeat(auto-fill, minmax(240px, 1fr)); gap:12px; }
.tile { padding:14px 16px; border-radius:10px; background:#1b1e24; cursor:grab; }
.tile--income { background:#16271c; }
.tile--expense { background:#2a1a1c; }
.tile.up { box-shadow: inset 3px 0 0 #2ecc71; }
.tile.down { box-shadow: inset 3px 0 0 #e74c3c; }
.tile__title { font-size:13px; opacity:.8; display:flex; justify-content:space-between; }
.tile__nodata { font-size:11px; color:#e0a800; }
.tile__amount { font-size:22px; font-weight:700; margin:6px 0; }
.tile__qty { font-size:13px; font-weight:400; opacity:.7; }
.tile__meta { font-size:12px; opacity:.75; display:flex; flex-direction:column; gap:2px; }
.tile__children { list-style:none; margin:10px 0 0; padding:8px 0 0; border-top:1px solid #333; font-size:12px; }
.tile__children li { display:flex; justify-content:space-between; padding:2px 0; }
.sortable-ghost { opacity:.4; }
.tile:not(.open) .tile__children { display:none; }
