/* hub CATALIST — только свои экраны. Общая основа (цвета двух тем, шапка, меню, поля, кнопки,
   таблицы) в catalist-base.css = копия оформления zaiko. Здесь используются только её переменные.
   Главный экран: вариант B (бенто) + полоски долей каналов из C (выбор пользователя 2026-10-06). */

.sub { color: var(--soft); font-size: 12px; font-weight: 400; }
.up { color: var(--ok); } .down { color: var(--warn); }

/* телефон: главные разделы в нижней панели (вариант B), верхнее меню прячем */
.tabbar { display: none; }
@media (max-width: 760px) {
  .bar .top-nav { display: none; }
  .tabbar { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 25; overflow-x: auto;
    background: var(--bar-bg); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
    border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom, 0px); scrollbar-width: none; }
  .tabbar::-webkit-scrollbar { display: none; }
  .tabbar a { flex: 1 0 58px; display: grid; justify-items: center; gap: 2px; padding: 8px 0 9px; font-size: 11px;
    letter-spacing: .04em; color: var(--soft); text-decoration: none; white-space: nowrap; }
  .tabbar a svg { width: 21px; height: 21px; }
  .tabbar a.on { color: var(--strong); }
  .tabbar a.on svg { color: var(--brand); }
  main { padding-bottom: calc(96px + env(safe-area-inset-bottom, 0px)); }
}

.stack { display: grid; gap: 14px; }
main > * + * { margin-top: 14px; }

.monthbar { display: flex; align-items: center; gap: 10px; }
.monthbar h1 { flex: 1; text-align: center; margin: 0; letter-spacing: .06em; }
.monthbar a, .monthbar .ph { width: 38px; height: 38px; display: grid; place-items: center; flex: none;
  border: 1px solid var(--line); border-radius: 50%; background: var(--panel); color: var(--soft); text-decoration: none; }
.monthbar .ph { visibility: hidden; }

/* бенто: главная цифра на тёмной плитке */
.hero { position: relative; overflow: hidden; display: grid; gap: 6px; padding: 20px;
  background: var(--accent-bg); color: var(--accent-fg); border-radius: var(--r-lg); box-shadow: var(--shadow);
  animation: rise .5s cubic-bezier(.2, .7, .2, 1) both; }
.hero::after { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: repeating-linear-gradient(135deg, rgba(255, 255, 255, .05) 0 1px, transparent 1px 7px); }
.hero .l { font-size: 12px; letter-spacing: .08em; opacity: .75; }
.hero .v { font-size: clamp(36px, 9vw, 52px); line-height: 1; letter-spacing: .01em; font-variant-numeric: tabular-nums; }
.hero .d { font-size: 13px; opacity: .9; font-weight: 400; }
.hero .d b { font-weight: 700; }
:root[data-theme="dark"] .hero { background: #1f1f1e; color: var(--strong); border: 1px solid var(--line); }

.bento { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.tile { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--shadow);
  padding: 14px 16px; display: grid; gap: 4px; min-width: 0; animation: rise .5s .06s cubic-bezier(.2, .7, .2, 1) both; }
.tile .l { font-size: 11px; letter-spacing: .1em; color: var(--label); }
.tile .v { font-size: 24px; line-height: 1.1; color: var(--strong); font-variant-numeric: tabular-nums; }
.tile .f { font-size: 11.5px; color: var(--soft); font-weight: 400; }
.mini { display: flex; align-items: flex-end; gap: 2px; height: 42px; }
.mini i { flex: 1; background: var(--brand); border-radius: 1px; min-height: 2px; }
.mini i.neg { background: var(--warn); }

/* каналы: доля полоской, как загрузка (из варианта C) */
.channels { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow);
  padding: 4px 18px; animation: rise .5s .12s cubic-bezier(.2, .7, .2, 1) both; }
.chrow { display: grid; grid-template-columns: minmax(70px, auto) 1fr auto; gap: 12px; align-items: center;
  padding: 12px 0; border-bottom: 1px solid var(--line); font-variant-numeric: tabular-nums; }
.chrow:last-child { border-bottom: 0; }
.chrow .n { font-size: 14px; letter-spacing: .04em; white-space: nowrap; }
.chrow .bar { height: 7px; background: var(--panel-2); border-radius: 4px; overflow: hidden; position: static;
  padding: 0; border: 0; display: block; }
.chrow .bar i { display: block; height: 100%; background: var(--brand); border-radius: 4px; }
.chrow .a { text-align: right; font-size: 15px; color: var(--strong); white-space: nowrap; }
.chrow .a small { display: block; font-size: 11px; color: var(--soft); font-weight: 400; }
.pill.kanri { background: transparent; border: 1px dashed var(--line); }

.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow);
  padding: 16px; display: grid; gap: 12px; }
.tablewrap { overflow-x: auto; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg);
  box-shadow: var(--shadow); padding: 4px 12px; }
.tablewrap th, .tablewrap td { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.tablewrap th:first-child, .tablewrap td:first-child { text-align: left; }
.tablewrap tbody tr:last-child td { border-bottom: 0; }
.warn { background: var(--warn-bg); color: var(--warn); border: 1px solid var(--warn); border-radius: var(--r-sm);
  padding: 9px 12px; font-size: 13px; font-weight: 400; }
.ok { color: var(--ok); font-size: 14px; } .err { color: var(--warn); font-size: 14px; }

/* формы: те же поля, что в zaiko (.fields), но классы hub */
label { display: grid; gap: 5px; font-size: 12px; letter-spacing: .06em; color: var(--label); }
input, select, textarea { font: inherit; font-size: 16px; font-weight: 600; padding: 11px 12px; border: 1px solid var(--line);
  background: var(--field); color: var(--text); border-radius: var(--r-sm); width: 100%; }
select { -webkit-appearance: none; appearance: none; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.btn { padding: 14px 22px; font: inherit; letter-spacing: .1em; background: var(--accent-bg); color: var(--accent-fg);
  border: 0; border-radius: var(--r-sm); cursor: pointer; }
.btn.ghost { background: transparent; color: var(--text); border: 1px solid var(--brand); padding: 9px 14px;
  letter-spacing: .04em; font-size: 13px; }
details summary { cursor: pointer; }

.login { max-width: 340px; margin: 9vh auto; display: grid; gap: 10px; }
.login .lockup { width: 100%; max-width: 260px; display: block; margin: 0 auto 20px; }
.login .btn { width: 100%; }
@media (prefers-reduced-motion: reduce) { .hero, .tile, .channels { animation: none; } }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* правки после снимков 06.10 */
@media (max-width: 760px) { .tabbar a[href="/admin/import"] { display: none; } }
.chrow { grid-template-columns: minmax(70px, 150px) 1fr auto; }
.hero .d b.up { color: #b5dc95; } .hero .d b.down { color: #f2a08c; }
