/* nowera office – appka (tokeny a sklo sú v theme.css) */

body { padding: env(safe-area-inset-top) 0 calc(76px + env(safe-area-inset-bottom)); }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 16px; }
main.wrap { padding-top: 8px; padding-bottom: 24px; }

/* ------------------------------------------------------------ navigácia */
.nav {
  position: fixed; z-index: 30; left: 0; right: 0; bottom: 0;
  padding: 6px max(8px, env(safe-area-inset-right)) calc(4px + env(safe-area-inset-bottom)) max(8px, env(safe-area-inset-left));
  border-radius: 0; box-shadow: inset 0 .5px 0 var(--sep);
}
.nav-brand, .nav-me { display: none; }
.icon-btn.active { color: var(--accent-text); background: var(--fill); }
.nav-tabs { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 2px; }
.tab {
  position: relative; display: flex; flex-direction: column; align-items: center; gap: 1px;
  padding: 4px 2px 2px; border-radius: 10px; font-size: 10.5px; font-weight: 500; color: var(--text-3); letter-spacing: 0;
  transition: color .2s var(--ease), opacity .15s var(--ease);
}
.tab svg { width: 25px; height: 25px; stroke-width: 1.7; }
.tab.tab-desk { display: none; }
@media (min-width: 900px) { .tab.tab-desk { display: flex; } .mobile-only, .top-actions .mobile-only { display: none; } }
.tab:active { opacity: .6; }
.tab.active { color: var(--accent); }
.badge {
  position: absolute; top: 2px; left: calc(50% + 6px); min-width: 18px; height: 18px; padding: 0 5px; border-radius: 99px;
  background: var(--danger); color: #fff; font-size: 11px; font-weight: 750; line-height: 18px; text-align: center;
  box-shadow: 0 0 0 2px var(--bg);
}

@media (min-width: 900px) {
  /* bočný panel ako v macOS: názvy vedľa ikon, výber je jemná sivá plocha */
  body { padding: 0 0 32px 232px; }
  .nav {
    left: 0; right: auto; top: 0; bottom: 0; width: 232px; padding: 18px 12px 14px;
    display: flex; flex-direction: column; align-items: stretch; gap: 14px; border-radius: 0;
    box-shadow: inset -.5px 0 0 var(--sep);
  }
  .nav-brand, .nav-me { display: flex; align-items: center; gap: 10px; padding: 0 8px; }
  .nav-brand::after { content: "nowera office"; font-family: var(--font-display); font-size: 15px; font-weight: 600; letter-spacing: -.01em; }
  .nav-brand .logo { width: 28px; height: 28px; border-radius: 7px; }
  .nav-tabs { display: flex; flex-direction: column; gap: 1px; flex: 1; width: 100%; }
  .tab { flex-direction: row; gap: 10px; padding: 7px 10px; border-radius: 8px; font-size: 14px; font-weight: 400; color: var(--text); }
  .tab svg { width: 19px; height: 19px; color: var(--text-2); }
  .tab.active svg { color: var(--accent); }
  .tab:hover { background: var(--fill); }
  .tab.active { background: var(--fill-2); color: var(--text); font-weight: 600; }
  .tab .badge { position: static; margin-left: auto; box-shadow: none; }
  .nav-me .avatar { width: 30px; height: 30px; font-size: 12px; }
}

/* ------------------------------------------------------------ horná lišta */
.topbar {
  position: sticky; top: 0; z-index: 20; display: flex; flex-wrap: wrap; align-items: center; gap: 10px;
  max-width: 1180px; margin: 0 auto; padding: 10px 16px 8px;
}
.brand { font-family: var(--font-display); font-size: 20px; font-weight: 750; letter-spacing: -.02em; }
.topbar > .brand { flex: none; display: inline-flex; align-items: center; gap: 8px; padding: 6px 4px; font-size: 17px; font-weight: 600; letter-spacing: -.02em; }
.topbar > .brand.chrome, .top-actions.chrome { background: transparent; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; }
.topbar > .brand .logo { width: 24px; height: 24px; border-radius: 7px; }
.top-actions { margin-left: auto; }
.brand span { color: var(--accent-text); }
.top-actions { display: flex; align-items: center; gap: 0; padding: 0; }
.top-actions .icon-btn { color: var(--accent); }
.top-actions .icon-btn { width: 44px; height: 44px; }
.offline { font-size: 12px; font-weight: 650; color: var(--warn); background: var(--warn-soft); padding: 3px 10px; border-radius: 99px; margin: 0 4px; }
.i-moon { display: none; }
:root[data-theme="dark"] .i-sun { display: none; }
:root[data-theme="dark"] .i-moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) .i-sun { display: none; }
  :root:not([data-theme]) .i-moon { display: block; }
}
@media (max-width: 899px) {
  .topbar { background: var(--glass-chrome); -webkit-backdrop-filter: blur(var(--blur)) saturate(var(--sat)); backdrop-filter: blur(var(--blur)) saturate(var(--sat)); box-shadow: inset 0 -.5px 0 var(--sep); padding-top: calc(10px + env(safe-area-inset-top)); margin-top: calc(-1 * env(safe-area-inset-top)); }
  .topbar .quick.chrome { -webkit-backdrop-filter: none; backdrop-filter: none; box-shadow: none; background: var(--fill); }
}
.quick { order: 3; flex: 1 0 100%; display: flex; align-items: center; gap: 8px; padding: 3px 3px 3px 12px; border-radius: 10px; }
.quick > svg { width: 18px; height: 18px; color: var(--text-3); flex: none; }
.quick input { flex: 1; min-width: 0; height: 36px; border: 0; background: transparent; color: var(--text); font-size: 16px; outline: none; }
.quick:focus-within { box-shadow: 0 0 0 3px var(--accent-soft); }
@media (min-width: 900px) {
  .topbar { padding: 14px 24px 10px; }
  .brand, .topbar > .brand { display: none; }
  .quick { order: 0; flex: 1 1 auto; max-width: 640px; }
  .topbar::after { content: ""; flex: 1; order: 1; }
  .top-actions { order: 2; }
  .wrap { padding: 0 24px; }
}

/* ------------------------------------------------------------ hlavička stránky */
.page-head { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px 16px; margin: 10px 0 18px; }
.page-head > div:first-child { flex: 1 1 260px; min-width: 0; }
.page-head h1 { font-family: var(--font-display); font-size: var(--fs-title); line-height: 1.12; font-weight: 700; letter-spacing: -.022em; overflow-wrap: anywhere; }
.page-head p { margin: 6px 0 0; color: var(--text-2); font-size: var(--fs-md); }
.page-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.back { display: inline-flex; gap: 4px; align-items: center; color: var(--text-2); font-size: 14px; font-weight: 600; margin-bottom: 8px; }
.back svg { width: 16px; height: 16px; }
.back:hover { color: var(--accent-text); }

/* rozloženie: hlavný stĺpec + bočný na desktope */
.grid-2 { display: grid; gap: 16px; }
.grid-2 > * { min-width: 0; }
@media (min-width: 1000px) { .grid-2 { grid-template-columns: minmax(0, 1.55fr) minmax(300px, 1fr); align-items: start; } }

/* ------------------------------------------------------------ karty */
.card { display: block; padding: 16px; border-radius: var(--r-lg); background: var(--glass); box-shadow: var(--rim), var(--shadow); }
a.card, .card.clickable { transition: box-shadow .25s var(--ease), opacity .15s var(--ease); cursor: pointer; }
a.card:hover, .card.clickable:hover { box-shadow: var(--rim), var(--shadow-lift); }
a.card:active, .card.clickable:active { opacity: .7; }
.card + .card { margin-top: 12px; }
.cards { display: grid; gap: 12px; }
.cards .card + .card { margin-top: 0; }
@media (min-width: 640px) { .cards { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); } }
.card-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.card-top strong { font-size: var(--fs-lg); font-weight: 600; letter-spacing: -.02em; overflow-wrap: anywhere; }
.card-head { display: flex; align-items: center; gap: 12px; }
.card-head > div { flex: 1; min-width: 0; }
.card-head h3 { font-size: var(--fs-lg); font-weight: 650; letter-spacing: -.01em; overflow-wrap: anywhere; }
.card-head p { margin: 1px 0 0; font-size: var(--fs-sm); color: var(--text-2); }
.card-foot { margin-top: 10px; font-size: var(--fs-sm); color: var(--text-2); overflow-wrap: anywhere; }
.card-foot .over, .over { color: var(--danger); font-weight: 650; }
.card-foot a, .detail-info a { color: var(--accent-text); font-weight: 650; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.card h2.card-title { font-size: var(--fs-lg); font-weight: 650; margin-bottom: 2px; }
.card .sub { color: var(--text-2); font-size: var(--fs-sm); margin: 0 0 12px; }
.card .link { color: var(--accent-text); font-weight: 650; font-size: 14px; }

/* ------------------------------------------------------------ skupiny a úlohy */
.summary { color: var(--text-2); font-size: 14px; margin: 2px 4px 14px; }
.summary a { color: var(--accent-text); font-weight: 650; }
.group { margin-bottom: 22px; }
.group > h2, .section-title {
  font-size: 12.5px; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; color: var(--text-2);
  margin: 0 6px 9px; display: flex; gap: 8px; align-items: baseline;
}
.section-title { margin: 22px 6px 10px; }
.group > h2.over { color: var(--danger); }
.count { font-weight: 600; opacity: .8; }

.tasks { list-style: none; margin: 0; padding: 4px 0; border-radius: var(--r-lg); background: var(--sheen), var(--glass); box-shadow: var(--rim), var(--shadow); overflow: hidden; }
.task { display: flex; gap: 12px; align-items: flex-start; padding: 11px 16px; position: relative; }
.task + .task::before { content: ""; position: absolute; top: 0; left: 52px; right: 16px; height: 1px; background: var(--sep); }
.check {
  flex: none; width: 24px; height: 24px; margin-top: 1px; border-radius: 50%; padding: 0; cursor: pointer; display: grid; place-items: center;
  background: transparent; border: 2px solid var(--text-2);
  transition: background .2s var(--ease), border-color .2s var(--ease), transform .3s var(--spring);
}
.check:hover { border-color: var(--accent-2); }
.check:active { transform: scale(.85); }
/* fajočka: SVG, ktorá sa pri odškrtnutí dokreslí */
.check .ck { width: 15px; height: 15px; stroke: var(--accent-ink); stroke-width: 3.2; stroke-dasharray: 24; stroke-dashoffset: 24; transition: stroke-dashoffset .25s var(--ease); }
.check.small .ck { width: 12px; height: 12px; }
.task.done .check, .ms.done .check, .bcard.done .check, .check.checking { background: var(--accent); border-color: var(--accent); }
.task.done .check .ck, .ms.done .check .ck, .bcard.done .check .ck { stroke-dashoffset: 0; }
.check.checking { animation: check-pop .5s var(--spring); box-shadow: 0 0 0 0 var(--accent-soft); }
.check.checking .ck { animation: check-draw .32s .12s var(--ease) forwards; }
@keyframes check-pop { 0% { transform: scale(.7); box-shadow: 0 0 0 0 rgba(125, 22, 255, .45); } 55% { transform: scale(1.18); } 100% { transform: scale(1); box-shadow: 0 0 0 12px rgba(125, 22, 255, 0); } }
@keyframes check-draw { to { stroke-dashoffset: 0; } }
/* preškrtnutie a zbalenie hotovej úlohy */
.task-title, .bcard-title, .ms-title { background: linear-gradient(currentColor, currentColor) no-repeat 0 55% / 0 1.5px; transition: background-size .35s var(--ease), color .3s var(--ease); }
.completing .task-title, .completing .bcard-title, .completing .ms-title { background-size: 100% 1.5px; color: var(--text-3); }
.task.leaving { overflow: hidden; height: 0 !important; padding-top: 0; padding-bottom: 0; opacity: 0; transition: height .3s var(--ease), padding .3s var(--ease), opacity .2s var(--ease); }
.task.leaving::before { display: none; }
.task-main { flex: 1; min-width: 0; cursor: pointer; }
.task-title { font-weight: 600; overflow-wrap: anywhere; }
.task.done .task-title { color: var(--text-3); text-decoration: line-through; }
.prio { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--danger); margin-right: 7px; vertical-align: 1px; box-shadow: 0 0 0 3px var(--danger-soft); }
.task-meta { display: flex; flex-wrap: wrap; gap: 6px 8px; align-items: center; margin-top: 5px; font-size: 13px; color: var(--text-2); }
.chip.client { background: var(--accent-soft); color: var(--accent-text); font-weight: 650; }
.chip.muted { opacity: .8; }
.chip.st-doing { background: var(--accent-soft); color: var(--accent-text); }
.chip.st-waiting { background: var(--warn-soft); color: var(--warn); }
.due { font-weight: 650; }
.due.today { color: var(--accent-text); }
.due.over { color: var(--danger); }
.who { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; font-size: 10px; font-weight: 750; color: #fff; background: var(--c, var(--accent)); }

.notice { display: flex; align-items: center; gap: 10px; margin: 0 0 16px; padding: 12px 16px; border-radius: var(--r-md); background: var(--sheen), var(--danger-soft); box-shadow: var(--rim); color: var(--danger); font-weight: 650; }

/* ------------------------------------------------------------ nástroje, filtre */
.toolbar { display: flex; gap: 10px; margin-bottom: 14px; align-items: center; flex-wrap: wrap; }
.search { flex: 1 1 220px; min-width: 0; height: 40px; padding: 0 14px; border: 0; border-radius: 10px; color: var(--text); font-size: 16px; outline: none;
  background: var(--sheen), var(--glass); box-shadow: var(--rim), var(--shadow); }
.search:focus { box-shadow: var(--rim), 0 0 0 3px var(--accent-soft); }
.filters { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 16px; }
.fchip { border: 0; border-radius: 8px; padding: 6px 12px; font-size: 14px; font-weight: 500; cursor: pointer; color: var(--text);
  background: var(--sheen), var(--glass); box-shadow: var(--rim), 0 1px 2px rgba(0, 0, 0, .05); transition: transform .3s var(--spring); display: inline-flex; align-items: center; gap: 6px; }
.fchip:active { transform: scale(.96); }
.fchip small { color: var(--text-3); font-weight: 600; }
.fchip.on { background: var(--text); color: var(--bg); }
.fchip.on small { color: inherit; opacity: .8; }
.quick-due { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 2px; }

/* ------------------------------------------------------------ detail */
.detail-head { margin-bottom: 18px; }
.detail-title { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.detail-title h2 { font-family: var(--font-display); font-size: var(--fs-title); font-weight: 750; letter-spacing: -.035em; line-height: 1.08; overflow-wrap: anywhere; }
.detail-info { margin-top: 8px; color: var(--text-2); font-size: 14.5px; white-space: pre-wrap; overflow-wrap: anywhere; }
.detail-actions { display: flex; gap: 8px; margin-top: 16px; flex-wrap: wrap; }
.info-card { display: grid; gap: 4px; font-size: 14.5px; color: var(--text-2); }
.info-card b { color: var(--text); font-weight: 650; }

details.fold { margin-top: 8px; }
details.fold > summary { cursor: pointer; color: var(--text-2); font-size: 13.5px; font-weight: 650; padding: 6px 4px; min-height: 44px; list-style: none; display: flex; align-items: center; gap: 8px; }
details.fold > summary::before { content: ""; width: 6px; height: 6px; border: solid currentColor; border-width: 0 2px 2px 0; transform: rotate(-45deg); transition: transform .25s var(--ease); }
details.fold[open] > summary::before { transform: rotate(45deg); }
details.fold > summary::-webkit-details-marker { display: none; }
details.fold[open] > summary { margin-bottom: 8px; }

/* ------------------------------------------------------------ projekty, sekcie a body */
.project { margin-bottom: 18px; }
.project + .project { margin-top: 0; }
.secs { display: grid; gap: 10px; margin-top: 14px; }
@media (min-width: 760px) { .secs { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); align-items: start; } }
.sec { border-radius: var(--r-md); padding: 12px; background: var(--fill); box-shadow: inset 0 0 0 .5px var(--sep); }
.sec-head { display: flex; align-items: center; gap: 12px; }
.sec-head > div { flex: 1; min-width: 0; }
.sec-head strong { display: block; font-size: 16px; font-weight: 650; overflow-wrap: anywhere; }
.sec-label { font-size: 12.5px; font-weight: 650; color: var(--text-2); }
.sec.st-active .sec-label, .sec.st-done .sec-label { color: var(--accent-text); }
.sec.st-blocked .sec-label { color: var(--warn); }
.attn { font-size: 12.5px; font-weight: 750; color: var(--danger); background: var(--danger-soft); padding: 2px 9px; border-radius: 99px; white-space: nowrap; }
.next-box { margin-top: 8px; font-size: 14px; color: var(--text-2); }
.next-box small { font-size: 12px; font-weight: 650; color: var(--text-2); margin-right: 4px; }
.next-box small::after { content: ':'; }
.next-box b { font-weight: 650; color: var(--text); overflow-wrap: anywhere; }
.mss { list-style: none; margin: 4px 0 10px; padding: 0; display: grid; gap: 2px; }
.ms { display: flex; align-items: center; gap: 10px; padding: 6px 2px; }
.ms-title { flex: 1; min-width: 0; cursor: pointer; overflow-wrap: anywhere; font-size: 15px; }
.ms-title:hover { color: var(--accent-text); }
.ms.done .ms-title { color: var(--text-3); text-decoration: line-through; }
.ms-meta { font-size: 12.5px; color: var(--text-2); white-space: nowrap; }
.check.small { width: 20px; height: 20px; margin: 0; }

.ms-add { display: flex; gap: 8px; margin-bottom: 10px; }
.ms-add input { flex: 1; min-width: 0; height: 40px; padding: 0 14px; border: 0; border-radius: 999px; background: var(--glass-input); color: var(--text); font-size: 15px; outline: none; box-shadow: inset 0 0 0 1px var(--field-line); }
.ms-add input:focus { box-shadow: inset 0 0 0 1.5px var(--accent-2); }
.sec-actions { margin-top: 10px; gap: 8px; }
.sec .tasks { margin-bottom: 6px; box-shadow: var(--rim); }

/* prehľad projektov na Dnes */
.plist { display: grid; gap: 2px; }
.prow { display: flex; align-items: center; gap: 12px; padding: 8px 6px; border-radius: var(--r-sm); }
.prow:hover { background: var(--fill); }
.prow > div { flex: 1; min-width: 0; }
.prow b { display: block; font-weight: 650; overflow-wrap: anywhere; }
.prow small { color: var(--text-2); font-size: 13px; }

/* dnešný prstenec */
.today-card { display: flex; align-items: center; gap: 14px; }
.today-card .legend { display: grid; gap: 10px; }
.today-card .legend div { padding-left: 10px; border-left: 3px solid var(--c); }
.today-card .legend span { display: block; font-size: 13px; color: var(--text-2); }
.today-card .legend b { font-size: 20px; font-weight: 750; letter-spacing: -.02em; }
.today-card .legend b small { font-size: 13px; color: var(--text-3); font-weight: 600; }

/* ------------------------------------------------------------ komunikácia */
a.card.req { display: block; color: inherit; position: relative; overflow: hidden; }
.req.wait-team.open::before, .req.wait-client.open::before { content: ""; position: absolute; left: 0; top: 14px; bottom: 14px; width: 4px; border-radius: 0 4px 4px 0; background: var(--danger); }
.req.wait-client.open::before { background: var(--warn); }
.req.closed { opacity: .72; }
.req-body { margin: 8px 0 0; font-size: 14.5px; white-space: pre-wrap; overflow-wrap: anywhere; color: var(--text-2); }
.clamp { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.turn-us { color: var(--danger); font-weight: 700; }
.thread { display: grid; gap: 10px; margin-bottom: 16px; }
.msg { max-width: min(88%, 640px); padding: 10px 14px; border-radius: 18px 18px 18px 6px; background: var(--sheen), var(--glass); box-shadow: var(--rim), 0 2px 10px -6px rgba(0, 0, 0, .3); }
.msg.team { justify-self: end; border-radius: 18px 18px 6px 18px; background: linear-gradient(180deg, rgba(255, 255, 255, .18), rgba(255, 255, 255, 0)), var(--accent-soft); }
.msg-head { font-size: 12px; color: var(--text-3); font-weight: 650; margin-bottom: 3px; }
.msg-body { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 15px; }
.files { display: grid; gap: 4px; margin-top: 8px; }
.file { font-size: 14px; font-weight: 650; color: var(--accent-text); overflow-wrap: anywhere; }
.file small { color: var(--text-3); font-weight: 500; }
.reply { display: grid; gap: 12px; }
.field input[type="file"] { font-size: 14px; color: var(--text-2); }

/* ------------------------------------------------------------ ponuky */
.offer-form { display: grid; gap: 14px; }
.grid-form { display: grid; gap: 12px; }
#items { display: grid; gap: 10px; }
.item { padding: 14px; border-radius: var(--r-lg); background: var(--sheen), var(--glass); box-shadow: var(--rim), var(--shadow); display: grid; gap: 8px; }
.item input[type="text"], .item textarea, .item select { width: 100%; min-height: 40px; padding: 8px 12px; font: inherit; font-size: 15px; border: 0; border-radius: var(--r-sm); background: var(--glass-input); color: var(--text); outline: none; box-shadow: inset 0 0 0 1px var(--field-line); }
.item textarea { resize: vertical; min-height: 0; }
.item input:focus, .item textarea:focus, .item select:focus { box-shadow: inset 0 0 0 1.5px var(--accent-2), 0 0 0 3px var(--accent-soft); }
.item-top { display: flex; gap: 6px; align-items: center; }
.item-top input { font-weight: 650; }
.item-btns { display: flex; }
.item-btns .icon-btn { width: 34px; height: 34px; }
.item-btns .icon-btn svg { width: 17px; height: 17px; }
.item-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; align-items: end; }
.item-grid label > span { display: block; font-size: 12px; font-weight: 650; color: var(--text-2); margin-bottom: 3px; }
.item-grid .wide { grid-column: span 3; }
.item-grid .check-row { font-size: 14px; padding-bottom: 6px; }
.item-total { font-size: 13px; color: var(--text-2); text-align: right; font-weight: 650; }
@media (max-width: 600px) { .item-grid { grid-template-columns: 1fr 1fr; } .item-grid .wide { grid-column: span 2; } }
.inline-field { font-size: 14px; color: var(--text-2); display: inline-flex; gap: 6px; align-items: center; }
.inline-field input { width: 56px; height: 34px; padding: 0 10px; border: 0; border-radius: 10px; background: var(--glass-input); color: var(--text); font-size: 15px; box-shadow: inset 0 0 0 1px var(--sep); }
.check-row.inline { align-items: center; font-size: 14px; }
.check-row.inline input { margin-top: 0; }
.totals-card { display: grid; gap: 6px; }
.totals-card > div { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.totals-card b { text-align: right; }
.totals-card small { font-weight: 500; color: var(--text-2); }
.totals-card .muted { color: var(--text-2); }
.sticky-actions { position: sticky; bottom: calc(92px + env(safe-area-inset-bottom)); z-index: 5; padding: 8px; border-radius: 999px; }
@media (min-width: 900px) { .sticky-actions { bottom: 16px; } }
.oline { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; font-size: 15px; }
.oline + .oline { border-top: 1px solid var(--sep); }
.oline small { color: var(--text-2); }
.oline.off { opacity: .5; text-decoration: line-through; }
.oline.total { font-weight: 750; }
.ok-card { margin-top: 12px; background: var(--sheen), var(--accent-soft); font-size: 14.5px; }
.ok-card a { color: var(--accent-text); font-weight: 650; }
.warn-card { margin-top: 12px; background: var(--sheen), var(--warn-soft); color: var(--warn); }
.timeline { list-style: none; padding: 0; margin: 14px 4px; display: grid; gap: 4px; font-size: 14px; color: var(--text-2); }
.timeline span { display: inline-block; min-width: 140px; color: var(--text); font-weight: 650; }
.hint.warn { color: var(--warn); }

/* ------------------------------------------------------------ nastavenia a tím (zoznam ako v iOS) */
.list { padding: 4px 0; }
.list + .list { margin-top: 14px; }
.list > h2 { font-size: var(--fs-lg); font-weight: 650; padding: 10px 16px 0; }
.list > p.sub { padding: 0 16px; margin: 2px 0 6px; }
.row { display: flex; align-items: center; gap: 12px; padding: 11px 16px; position: relative; min-height: 56px; }
.row + .row::before { content: ""; position: absolute; top: 0; left: 58px; right: 16px; height: 1px; background: var(--sep); }
.row > div { flex: 1; min-width: 0; }
.row b { display: block; font-weight: 600; overflow-wrap: anywhere; }
.row small { display: block; color: var(--text-2); font-size: 13px; overflow-wrap: anywhere; }
.row.clickable { cursor: pointer; }
.row.clickable:hover { background: var(--fill); }
.chev { width: 16px; height: 16px; color: var(--text-3); flex: none; }
.row.inactive { opacity: .55; }
.row.wrap-row { flex-wrap: wrap; }
.row.wrap-row > div { flex: 1 1 170px; }
.row.wrap-row > .seg, .row.wrap-row > .swatches { margin-left: auto; }
.swatches { display: flex; gap: 8px; flex-wrap: wrap; }
.swatch { width: 34px; height: 34px; border-radius: 50%; border: 0; cursor: pointer; padding: 0; box-shadow: var(--rim), 0 2px 6px -2px rgba(0, 0, 0, .3); transition: transform .3s var(--spring); }
.swatch.on { box-shadow: 0 0 0 2px var(--glass-solid), 0 0 0 4px var(--accent-2); }
.swatch:active { transform: scale(.9); }
.sw-aurora { background: radial-gradient(circle at 25% 25%, #7d16ff, transparent 60%), radial-gradient(circle at 80% 70%, #3b82f6, transparent 60%), #e4e1f0; }
.sw-sand { background: radial-gradient(circle at 25% 25%, #fbbf24, transparent 60%), radial-gradient(circle at 80% 70%, #f472b6, transparent 60%), #efe7dc; }
.sw-sage { background: radial-gradient(circle at 25% 25%, #4ade80, transparent 60%), radial-gradient(circle at 80% 70%, #2dd4bf, transparent 60%), #dfeadf; }
.sw-graphite { background: radial-gradient(circle at 25% 25%, #94a3b8, transparent 60%), #3f4650; }

/* ------------------------------------------------------------ prázdne stavy */
.empty { text-align: center; color: var(--text-2); padding: 32px 16px; }
.empty strong { display: block; color: var(--text); font-size: 17px; font-weight: 600; margin-bottom: 4px; }
.empty .btn { margin-top: 16px; }

/* ------------------------------------------------------------ dialóg */
dialog {
  border: 0; padding: 0; border-radius: var(--r-xl); width: min(580px, calc(100% - 24px)); max-height: calc(100dvh - 24px); color: var(--text);
  background: var(--glass-solid);
  box-shadow: var(--rim), 0 24px 60px -12px rgba(0, 0, 0, .35);
}
:root[data-reduce="1"] dialog { background: var(--glass-solid); }
dialog[open] { animation: pop .32s var(--spring); }
@keyframes pop { from { opacity: 0; transform: translateY(10px) scale(.985); } }
dialog::backdrop { background: var(--scrim); }
@media (max-width: 600px) {
  dialog { width: 100%; max-width: none; margin: auto 0 0; border-radius: 14px 14px 0 0; max-height: 92dvh; }
}
.sheet { padding: 20px 20px calc(20px + env(safe-area-inset-bottom)); display: grid; gap: 14px; }
.sheet h2 { font-family: var(--font-display); font-size: 20px; font-weight: 600; letter-spacing: -.02em; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 420px) { .row2 { grid-template-columns: 1fr; } }
.check-row { display: flex; gap: 10px; align-items: flex-start; font-size: 15px; }
.check-row input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--accent); flex: none; }
.check-row small { display: block; color: var(--text-2); }
.actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.actions .spacer { flex: 1; }
.hint { margin: 0; font-size: 13.5px; color: var(--text-2); }
.sheet textarea[readonly], .sheet input[readonly] { color: var(--text); }
.field textarea[rows] { min-height: 0; }
.tpls { display: grid; gap: 8px; }
.tpl { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: var(--r-md); cursor: pointer; background: var(--fill); transition: background .2s var(--ease), box-shadow .2s var(--ease); }
.tpl:has(input:checked) { background: var(--accent-soft); box-shadow: inset 0 0 0 1.5px var(--accent-2); }
.tpl input { margin-top: 3px; accent-color: var(--accent); }
.tpl small { display: block; color: var(--text-2); font-size: 12.5px; }

/* ------------------------------------------------------------ toast a prihlásenie */
.toast {
  position: fixed; left: 50%; transform: translateX(-50%); z-index: 60; bottom: calc(100px + env(safe-area-inset-bottom));
  max-width: min(520px, calc(100% - 28px)); padding: 12px 18px; border-radius: 999px; display: flex; gap: 14px; align-items: center;
  background: rgba(20, 24, 26, .86); color: #f2f6f6; font-size: 14.5px; font-weight: 550;
  -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); box-shadow: inset 0 1px 1px rgba(255, 255, 255, .15), 0 16px 40px -12px rgba(0, 0, 0, .5);
}
@media (min-width: 900px) { .toast { bottom: 28px; left: calc(50% + 56px); } }
.toast button { border: 0; background: transparent; color: #c9a6ff; font-weight: 750; cursor: pointer; padding: 0; }
.login { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 20px; }
.login::before { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--bg); opacity: .4; -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); }
.login-card { width: min(380px, 100%); display: grid; gap: 12px; text-align: center; justify-items: center; padding: 30px 24px; border-radius: var(--r-xl); }
.login-card > * { width: 100%; }
.login-card > .login-logo { width: 64px; height: 64px; border-radius: 15px; }
.login-card .brand { font-size: 28px; flex: none; }
.login-card p { margin: 0; color: var(--text-2); }
.login-card .input { text-align: center; height: 50px; border-radius: 999px; }
.login-card .btn { min-height: 50px; }
.login-setup { display: grid; gap: 12px; }
.error { color: var(--danger) !important; font-size: 14px; }
.info { color: var(--accent-text) !important; font-size: 14px; }
.member { margin-bottom: 0; }

/* ------------------------------------------------------------ projekty */
.proj-cards { align-items: start; }
.mini-secs { display: grid; gap: 7px; margin-top: 14px; }
.mini-sec { display: grid; grid-template-columns: minmax(90px, 38%) 1fr 40px; align-items: center; gap: 10px; font-size: 13.5px; }
.mini-sec > span { color: var(--text); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mini-sec .bar { height: 6px; }
.mini-sec small { text-align: right; color: var(--text-2); font-weight: 650; font-variant-numeric: tabular-nums; }
.mini-sec.st-done .bar > span { background: var(--ok); }
.mini-sec.st-blocked > span, .mini-sec.st-unplanned > span { color: var(--text-2); }
.proj-card .next-box { margin-top: 12px; }
.proj-foot { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; }
.proj-foot .flags { display: inline-flex; flex-wrap: wrap; gap: 6px; }
.chip.st-over { background: var(--danger-soft); color: var(--danger); }
.card-head h3 a:hover, .card-head h1 a:hover { color: var(--accent-text); }
.page-head .card-head h1 { font-size: var(--fs-title); }
.secs.secs-1 { grid-template-columns: 1fr; margin-top: 0; }
.side { display: grid; gap: 14px; align-content: start; }
.side .card + .card { margin-top: 0; }
.prow.clickable { cursor: pointer; }
.due-pill { flex: none; min-width: 52px; padding: 4px 8px; border-radius: 10px; background: var(--fill); font-size: 12.5px; font-weight: 700; text-align: center; color: var(--text-2); font-variant-numeric: tabular-nums; }
.due-pill.over { background: var(--danger-soft); color: var(--danger); }
.due-pill.today { background: var(--accent-soft); color: var(--accent-text); }
@media (max-width: 999px) { .project-grid .side { order: -1; } }

/* ------------------------------------------------------------ nástenky (To-do / In progress / Done) */
.view-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.view-toggle button { display: inline-flex; align-items: center; gap: 6px; }
.view-toggle svg { width: 16px; height: 16px; }
.board { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; align-items: start; margin-bottom: 14px; }
.col { border-radius: var(--r-lg); padding: 10px; background: var(--fill); box-shadow: inset 0 0 0 .5px var(--sep); transition: background .2s var(--ease), box-shadow .2s var(--ease); min-width: 0; }
.col > header { display: flex; align-items: center; gap: 8px; padding: 4px 6px 10px; }
.col > header strong { font-size: 15px; font-weight: 700; }
.col > header .count { font-size: 12.5px; font-weight: 700; color: var(--text-2); background: var(--glass); padding: 1px 8px; border-radius: 99px; }
.col > header .icon-btn { margin-left: auto; width: 32px; height: 32px; }
.col-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--text-3); }
.col-doing .col-dot { background: var(--accent); }
.col-done .col-dot { background: var(--ok); }
.col-body { display: grid; gap: 8px; min-height: 90px; align-content: start; }
.col-empty { margin: 0; padding: 18px 8px; text-align: center; font-size: 13px; color: var(--text-3); }
.col.over .col-empty { border: 1.5px dashed var(--accent); border-radius: var(--r-md); }
.col.over { background: var(--accent-soft); box-shadow: inset 0 0 0 1.5px var(--accent-2); }
.bcard { padding: 11px 12px 8px; border-radius: var(--r-md); background: var(--sheen), var(--glass); box-shadow: var(--rim), 0 2px 8px -4px rgba(0, 0, 0, .2); cursor: grab; transition: transform .25s var(--spring), opacity .2s var(--ease), box-shadow .2s var(--ease); }
.bcard:hover { box-shadow: var(--rim), 0 8px 20px -10px rgba(0, 0, 0, .35); }
.bcard:active { cursor: grabbing; }
.bcard.dragging { opacity: .45; transform: scale(.97) rotate(-1deg); }
.bcard.done .bcard-title { color: var(--text-3); text-decoration: line-through; }
.bcard-title { font-weight: 600; font-size: 14.5px; overflow-wrap: anywhere; cursor: pointer; }
.bcard-title:hover { color: var(--accent-text); }
.bcard .task-meta { margin-top: 6px; font-size: 12.5px; }
.bcard-foot { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-top: 8px; min-height: 30px; }
.bcard-foot .sub { font-size: 12.5px; color: var(--text-2); }
.who.none { background: var(--fill-2); color: var(--text-2); }
.move { display: inline-flex; gap: 2px; margin-left: auto; }
.move .icon-btn { width: 30px; height: 30px; }
.move .icon-btn svg { width: 16px; height: 16px; }
.pcard .card-head { gap: 10px; }
.pcard .card-head h3 { font-size: 15px; }
.pcard .card-head p { font-size: 12.5px; }
.pcard .next-box { margin-top: 8px; font-size: 13px; }
.pcard .task-meta { margin-top: 8px; }
.pstat { font-weight: 650; }
.pstat.ps-todo { color: var(--text-2); }
.pstat.ps-doing { color: var(--accent-text); }
.pstat.ps-done { color: var(--ok); }
.pstatus-seg button { min-height: 36px; padding: 6px 12px; }
@media (max-width: 899px) {
  .board { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 12px; margin: 0 -16px 14px; padding: 0 16px 6px; scrollbar-width: none; }
  .board::-webkit-scrollbar { display: none; }
  .col { flex: 0 0 84%; scroll-snap-align: start; }
}
@media (hover: none) { .bcard { cursor: default; } }

/* ------------------------------------------------------------ nástenka: fajočka na karte */
.bcard-top { display: flex; align-items: flex-start; gap: 8px; }
.bcard-top .check { margin-top: 1px; }
.bcard-top .bcard-title { flex: 1; min-width: 0; }

/* ------------------------------------------------------------ vstup na stránku */
@keyframes rise { from { opacity: 0; transform: translateY(12px) scale(.985); } }
@keyframes ring-in { from { stroke-dasharray: 0 100; } }
@keyframes bar-in { from { width: 0; } }
#view.enter { animation: fade .18s var(--ease) both; }
@keyframes fade { from { opacity: 0; } }

/* aktívna záložka: jemné „naskočenie" */
.tab.active svg { animation: tab-pop .45s var(--spring); }
@keyframes tab-pop { 0% { transform: scale(.8); } 60% { transform: scale(1.12); } 100% { transform: scale(1); } }

/* ------------------------------------------------------------ filtre úloh */
.fsel { position: relative; }
.sr { position: absolute; left: 0; top: 0; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.filters-bar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; flex: 1 1 auto; min-width: 0; }
.fsel select, .fsearch {
  height: 36px; border: 0; border-radius: 9px; font: inherit; font-size: 14px; font-weight: 500; color: var(--text); outline: none;
  background: var(--glass); box-shadow: var(--rim);
}
.fsel select { padding: 0 34px 0 14px; max-width: 220px; appearance: none; -webkit-appearance: none; cursor: pointer;
  background-image: var(--sheen), linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%);
  background-position: 0 0, calc(100% - 18px) 52%, calc(100% - 13px) 52%; background-size: 100% 100%, 5px 5px, 5px 5px; background-repeat: no-repeat; background-color: var(--glass); }
.fsearch { padding: 0 16px; min-width: 160px; flex: 1 1 180px; max-width: 280px; }
.fsel select:focus, .fsearch:focus { box-shadow: var(--rim), 0 0 0 3px var(--accent-soft); }
.view-bar .filters-bar + .view-toggle { margin-left: auto; }
@media (max-width: 899px) {
  .filters-bar { flex-wrap: nowrap; overflow-x: auto; margin: 0 -16px; padding: 2px 16px 4px; scrollbar-width: none; }
  .filters-bar::-webkit-scrollbar { display: none; }
  .fsel select { max-width: 180px; }
  .fsearch { min-width: 150px; }
}
.notice.warn-note { background: var(--sheen), var(--warn-soft); color: var(--warn); }
.prow > a { flex: 1; min-width: 0; color: inherit; }
.prow > a b { display: block; font-weight: 650; overflow-wrap: anywhere; }
.prow > a small { color: var(--text-2); font-size: 13px; }
a.chip:hover { filter: brightness(1.08); }

/* ------------------------------------------------------------ paleta ⌘K */
.palette { position: fixed; inset: 0; z-index: 90; display: flex; justify-content: center; align-items: flex-start; padding: calc(10vh + env(safe-area-inset-top)) 12px 12px;
  background: var(--scrim); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); animation: fade .2s var(--ease); }
@keyframes fade { from { opacity: 0; } }
.palette-box { width: min(640px, 100%); max-height: 72dvh; display: flex; flex-direction: column; border-radius: var(--r-xl); overflow: hidden;
  background: var(--sheen), var(--glass-chrome); -webkit-backdrop-filter: blur(calc(var(--blur) + 14px)) saturate(var(--sat)); backdrop-filter: blur(calc(var(--blur) + 14px)) saturate(var(--sat));
  box-shadow: var(--rim), 0 30px 80px -20px rgba(0, 0, 0, .55); animation: pop .35s var(--spring); }
:root[data-reduce="1"] .palette-box { background: var(--glass-solid); }
.palette-input { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--sep); }
.palette-input svg { width: 20px; height: 20px; color: var(--text-3); flex: none; }
.palette-input input { flex: 1; min-width: 0; border: 0; background: transparent; color: var(--text); font: inherit; font-size: 17px; outline: none; }
kbd { font: 600 11px/1 var(--font); color: var(--text-2); background: var(--fill); border-radius: 6px; padding: 4px 6px; }
.palette-list { overflow-y: auto; padding: 6px; }
.pal-group { padding: 10px 10px 4px; font-size: 11.5px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--text-3); }
.pal-item { display: flex; align-items: center; gap: 12px; padding: 8px 10px; border-radius: 14px; cursor: pointer; }
.pal-item.on { background: var(--accent); color: var(--accent-ink); }
.pal-item.on small { color: rgba(255, 255, 255, .8); }
.pal-item.on kbd { background: rgba(255, 255, 255, .2); color: #fff; }
.pal-ico { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; flex: none; background: var(--fill); color: var(--text-2); }
.pal-item.on .pal-ico { background: rgba(255, 255, 255, .18); color: #fff; }
.pal-ico svg { width: 16px; height: 16px; }
.pal-text { flex: 1; min-width: 0; }
.pal-text b { display: block; font-weight: 600; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pal-text small { display: block; font-size: 12.5px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pal-empty { padding: 20px; text-align: center; color: var(--text-2); margin: 0; }
@media (max-width: 600px) { .palette { padding-top: calc(12px + env(safe-area-inset-top)); } .palette-box { max-height: 80dvh; } }

/* ------------------------------------------------------------ balík 2: zvonček, schvaľovanie, projekt, kontrolný zoznam */
.icon-btn.bell { position: relative; }
.icon-btn.bell .badge { top: 3px; left: auto; right: 3px; }
.notif-pop { position: fixed; z-index: 85; top: calc(68px + env(safe-area-inset-top)); right: max(12px, calc((100vw - 1180px) / 2 + 16px)); width: min(400px, calc(100vw - 24px));
  max-height: min(70dvh, 560px); display: flex; flex-direction: column; border-radius: var(--r-lg); overflow: hidden;
  background: var(--sheen), var(--glass-solid); box-shadow: var(--rim), 0 24px 60px -20px rgba(0, 0, 0, .45); backdrop-filter: blur(24px) saturate(1.6); -webkit-backdrop-filter: blur(24px) saturate(1.6);
  animation: np-in .22s var(--ease); }
@keyframes np-in { from { opacity: 0; transform: translateY(-6px) scale(.98); } }
.np-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 16px 10px; border-bottom: 1px solid var(--separator, rgba(127, 127, 127, .18)); }
.np-head .link { background: none; border: 0; padding: 0; font: inherit; font-size: 13px; color: var(--accent-text); cursor: pointer; }
.np-list { overflow-y: auto; padding: 6px; }
.np-item { display: flex; gap: 10px; width: 100%; text-align: left; padding: 10px; border: 0; border-radius: var(--r-md); background: none; color: inherit; font: inherit; cursor: pointer; }
.np-item:hover { background: var(--fill-1, rgba(127, 127, 127, .1)); }
.np-item b { display: block; font-weight: 600; font-size: 14px; }
.np-item small { display: block; color: var(--text-2); font-size: 12.5px; margin-top: 2px; }
.np-item.unread b { font-weight: 750; }
.np-item.unread .np-ico { box-shadow: 0 0 0 2px var(--accent); }
.np-ico { flex: none; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--fill-2); font-size: 15px; }
.np-time { opacity: .75; }
.chip.cl-done { background: color-mix(in srgb, var(--ok) 15%, transparent); color: var(--ok); }
.chip.risk-watch { background: var(--warn-soft); color: var(--warn); }
.chip.risk-risk { background: var(--danger-soft); color: var(--danger); font-weight: 650; }
.risk-line { margin: 4px 0 0; font-size: 13.5px; font-weight: 600; }
.risk-line.risk-watch { color: var(--warn); }
.risk-line.risk-risk { color: var(--danger); }
.card.approval { margin: 0 0 14px; border-left: 3px solid var(--accent); }
.card.approval.ap-approved { border-left-color: var(--ok); }
.card.approval.ap-changes { border-left-color: var(--warn); }
.cl-list { display: flex; flex-direction: column; gap: 6px; }
.cl-row { display: flex; align-items: center; gap: 8px; }
.cl-row input[type=checkbox] { width: 20px; height: 20px; flex: none; accent-color: var(--accent); }
.cl-row input[type=text] { flex: 1; min-width: 0; }
.cl-row:has(input[type=checkbox]:checked) input[type=text] { text-decoration: line-through; opacity: .6; }
.cl-row .icon-btn.small { width: 32px; height: 32px; font-size: 20px; line-height: 1; }
.cl-add { display: flex; gap: 8px; margin-top: 8px; }
.cl-add input { flex: 1; min-width: 0; }
.agenda .ak { display: inline-block; width: 1.2em; opacity: .8; }

/* ------------------------------------------------------------ prehľad ponúk */
.odash { margin-bottom: 18px; }
.odash .card-top { flex-wrap: wrap; gap: 10px; }
.odash-tiles { margin: 14px 0 8px; }
.odash-tiles .tile { background: var(--fill); box-shadow: none; }
.odash .hint { margin: 2px 0 6px; }
.odash-sub { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-top: 14px; font-size: 13px; color: var(--text-2); font-weight: 600; }
.legend-mini { display: inline-flex; align-items: center; gap: 6px; font-weight: 500; }
.legend-mini i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-left: 6px; }
.odash-chart { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; align-items: end; margin-top: 10px; }
.ob { display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 0; }
.ob-bar { width: 100%; max-width: 54px; height: 110px; display: flex; flex-direction: column-reverse; justify-content: flex-start; gap: 2px; border-radius: 10px; background: var(--fill); overflow: hidden; }
.ob-bar span { display: block; width: 100%; transition: height .6s var(--ease); }
.ob-one, .legend-mini .ob-one { background: var(--accent); }
.ob-mon, .legend-mini .ob-mon { background: color-mix(in srgb, var(--accent) 45%, transparent); }
.ob b { font-size: 12.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.ob small { font-size: 12px; color: var(--text-2); }
@media (max-width: 560px) { .odash .seg { width: 100%; } .odash .seg button { flex: 1; padding-inline: 6px; } .ob b { font-size: 11px; } }
/* mobil: prepínač témy je v Nastaveniach, v hornej lište by sa so zvončekom nezmestil */
@media (max-width: 899px) { .top-actions [data-action="theme-toggle"] { display: none; } }
@media (max-width: 899px) { .top-actions .icon-btn { width: 40px; height: 40px; } .top-actions { padding: 3px; } .topbar { gap: 8px; padding-left: 12px; padding-right: 12px; } }

/* ------------------------------------------------------------ balík 3: kredit, hodiny, novinky */
.xcards { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 14px; margin-bottom: 18px; }
.xcards > * { min-width: 0; }
.xcard .card-top { gap: 10px; flex-wrap: wrap; }
.xcard .fold { margin-top: 10px; }
.xcard .notice { margin: 10px 0 0; font-size: 14px; }
.btable { width: 100%; border-collapse: collapse; margin-top: 10px; font-size: 14px; }
.btable th, .btable td { padding: 7px 6px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--sep); }
.btable thead th { font-size: 12.5px; color: var(--text-2); font-weight: 600; }
.btable td b { display: block; font-size: 16px; }
.btable td small { display: block; font-size: 12px; color: var(--warn); }
.btable .muted { color: var(--text-3); }
.hours-big { margin-top: 8px; }
.hours-big b { font-size: 28px; font-weight: 750; letter-spacing: -.03em; font-family: var(--font-display); }
.hours-big span { color: var(--text-2); font-size: 14px; }
.hbar { height: 8px; border-radius: 99px; background: var(--fill); overflow: hidden; margin: 8px 0 6px; }
.hbar span { display: block; height: 100%; background: var(--accent); border-radius: 99px; transition: width .6s var(--ease); }
.hbar.over span { background: var(--danger); }
.hint.over { color: var(--danger); font-weight: 600; }
.time-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.time-row > span { font-size: 14px; color: var(--text-2); margin-right: 4px; }
.amend-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0 0 14px; }
.radio-pill { position: relative; display: inline-flex; }
.radio-pill input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.radio-pill span { padding: 8px 14px; border-radius: 999px; font-size: 14px; font-weight: 600; color: var(--text-2); }
.radio-pill input:checked + span { background: var(--sheen), var(--glass-solid); color: var(--text); box-shadow: var(--rim); }
.radio-pill input:focus-visible + span { outline: 2px solid var(--accent-2); }
.view-bar .btn.small { margin-left: auto; }
.field .time-row input.time-custom { width: 84px; min-height: 36px; padding: 6px 10px; }

/* ------------------------------------------------------------ reporting kampaní */
.perf { margin-bottom: 18px; }
.perf .card-top { flex-wrap: wrap; gap: 10px; }
.perf-src { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.perf-src .chip { cursor: pointer; border: 0; font: inherit; font-size: 12.5px; }
.perf-status { display: flex; align-items: center; gap: 8px; margin: 12px 0 10px; font-size: 14px; flex-wrap: wrap; }
.perf-status small { color: var(--text-2); }
.dot { width: 10px; height: 10px; border-radius: 50%; flex: none; background: var(--text-3); }
.st-green .dot { background: var(--ok); } .st-yellow .dot { background: var(--warn); } .st-red .dot { background: var(--danger); } .st-low .dot { background: var(--fill-2); } .st-na .dot { background: var(--text-3); }
.pace { margin: 6px 0 10px; }
.pace-top { display: flex; justify-content: space-between; gap: 10px; font-size: 14px; color: var(--text-2); }
.pace-top b { color: var(--text); }
.pace .hbar { position: relative; overflow: visible; }
.pace .hbar i { position: absolute; top: -3px; bottom: -3px; width: 2px; background: var(--text-2); border-radius: 2px; }
.pace.over .hbar span { background: var(--danger); } .pace.under .hbar span { background: var(--warn); }
.warn-t { color: var(--warn); } .ok-t { color: var(--ok); }
.perf-tiles { margin: 12px 0 6px; }
.perf-tiles .tile { background: var(--fill); box-shadow: none; }
.perf-tiles .tile b { font-size: 21px; }
.perf-sub { margin-top: 12px; font-size: 13px; color: var(--text-2); font-weight: 600; }
.spark { display: flex; align-items: flex-end; gap: 3px; height: 54px; margin-top: 8px; }
.spark span { flex: 1; min-width: 0; background: color-mix(in srgb, var(--accent) 70%, transparent); border-radius: 3px 3px 1px 1px; }
.ctable { width: 100%; border-collapse: collapse; margin-top: 8px; font-size: 13.5px; }
.ctable th, .ctable td { text-align: left; padding: 7px 6px; border-bottom: 1px solid var(--sep); vertical-align: top; }
.ctable th { font-size: 12px; color: var(--text-2); font-weight: 600; }
.ctable td:first-child { overflow-wrap: anywhere; }
.rlist { display: flex; flex-direction: column; gap: 8px; }
.rrow { display: grid; grid-template-columns: 14px minmax(160px, 1.4fr) repeat(3, minmax(90px, 1fr)) minmax(150px, 1.3fr); gap: 12px; align-items: center; padding: 12px 16px; border-radius: var(--r-md); background: var(--sheen), var(--glass); box-shadow: var(--rim); color: inherit; text-decoration: none; }
.rrow:hover { background: var(--sheen), var(--glass-solid); }
.rname { min-width: 0; } .rname b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rname small, .rcell small { display: block; font-size: 12px; color: var(--text-2); }
.rcell b { display: block; font-size: 15px; font-weight: 700; }
.rsub { margin-left: 26px; } .rsub .rrow { background: var(--fill); box-shadow: none; padding: 9px 14px; }
@media (max-width: 899px) {
  .rrow { grid-template-columns: 1fr 1fr; gap: 10px 14px; border-left: 4px solid var(--text-3); }
  .rrow > .dot { display: none; }
  .rrow .rname, .rrow .rcell.wide { grid-column: 1 / 3; }
  .rrow.st-green { border-left-color: var(--ok); } .rrow.st-yellow { border-left-color: var(--warn); } .rrow.st-red { border-left-color: var(--danger); } .rrow.st-low { border-left-color: var(--fill-2); }
  .rsub { margin-left: 12px; }
}
.row-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-left: auto; }
.steps { margin: 0 0 14px; padding-left: 20px; font-size: 14px; line-height: 1.5; color: var(--text-2); }
.steps b { color: var(--text); }

.sheet.wide-sheet { max-width: 860px; }
.tscroll { overflow-x: auto; margin: 10px 0; }
.ctable.preset td small { display: block; color: var(--text-2); font-size: 12px; }
.ctable.preset tr.warn td { background: var(--warn-soft); }

.ai-card { margin-bottom: 16px; border-left: 3px solid var(--accent); }
.ai-card .card-top small { color: var(--text-2); }
.ai-text { white-space: pre-wrap; line-height: 1.55; margin-top: 8px; font-size: 14.5px; }
.perf-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 14px; }
.check-row.inline { padding: 0; margin-left: 4px; }
@media (max-width: 700px) {
  .ctable.preset thead { display: none; }
  .ctable.preset tr { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 12px; padding: 10px 0; border-bottom: 1px solid var(--sep); }
  .ctable.preset td { border: 0; padding: 0; }
}
.ctable.preset td:first-child b { white-space: nowrap; }

/* menu „Viac“ (mobil) */
.more-sheet { gap: 2px; }
.more-row { display: flex; align-items: center; gap: 12px; min-height: 52px; padding: 6px 4px; border-bottom: 1px solid var(--sep); color: inherit; text-decoration: none; }
.more-row:last-child { border-bottom: 0; }
.more-row b { flex: 1; font-weight: 600; font-size: 16px; }
.alert-count { background: var(--danger-soft); color: var(--danger); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.more-row .count.alert-count { min-width: 24px; padding: 2px 8px; border-radius: 99px; font-size: 13px; font-weight: 700; text-align: center; }

/* reklamné účty pri klientovi */
.plat { flex: none; width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; font-weight: 800; font-size: 14px; color: #fff; }
.plat-meta { background: #0866ff; } .plat-google { background: #34a853; } .plat-woo { background: #7f54b3; } .plat-leads { background: #ff9500; }
.ads-card .prow small + small { display: block; }
.linkbtn { background: none; border: 0; padding: 0; font: inherit; color: var(--accent-text); cursor: pointer; text-decoration: underline; text-underline-offset: 2px; }
.copyline { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.copyline code { flex: 1; min-width: 0; overflow-wrap: anywhere; font-size: 13px; padding: 8px 10px; border-radius: 8px; background: var(--fill); }

.danger-zone { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--sep); align-items: center; gap: 10px; }
.purge-list { margin: 0; padding-left: 20px; display: grid; gap: 4px; }

/* ------------------------------------------------------------ obchod (pipeline) */
@media (min-width: 900px) {
  .board.board-wide { display: flex; overflow-x: auto; gap: 12px; padding-bottom: 6px; scroll-snap-type: x proximity; }
  .board.board-wide .col { flex: 0 0 272px; scroll-snap-align: start; }
}
.board-wide .col-body { max-height: calc(100dvh - 330px); overflow-y: auto; min-height: 90px; }
@media (max-width: 899px) { .board-wide .col-body { max-height: none; } }
.col-lead .col-dot { background: var(--accent-2); }
.col-offer .col-dot { background: #8b5cf6; }
.col-delivery .col-dot { background: var(--warn); }
.col-sla .col-dot { background: #f97316; }
.col-lost .col-dot { background: var(--danger); }
.dcard .bcard-title { cursor: pointer; font-weight: 650; }
.deal-val { margin: 4px 0 2px; font-size: 15px; font-weight: 750; font-variant-numeric: tabular-nums; }
.deal-val small { font-size: 12px; font-weight: 600; color: var(--text-2); }
.deal-why { margin: 6px 0 0; font-size: 12.5px; color: var(--text-2); }
.chip.pay-unpaid { background: var(--danger-soft); color: var(--danger); }
.chip.pay-deposit { background: var(--warn-soft); color: var(--warn); }
.chip.pay-paid { background: color-mix(in srgb, var(--ok) 15%, transparent); color: var(--ok); }
.import-list { max-height: 52dvh; overflow-y: auto; }
.prow.muted { opacity: .55; }
.notice-soft { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: var(--r-md); background: var(--fill); }
.notice-soft > div { flex: 1; min-width: 0; }
.notice-soft b { display: block; }
.notice-soft small { color: var(--text-2); }

/* výkon kampaní: 7 dní a mesiac podľa typu kampaní */
.mtable-wrap { overflow-x: auto; min-width: 0; }
.mtable { width: 100%; border-collapse: collapse; font-size: 14px; margin: 6px 0 10px; font-variant-numeric: tabular-nums; }
.mtable th, .mtable td { padding: 7px 8px; border-bottom: 1px solid var(--sep); text-align: right; vertical-align: top; }
.mtable thead th { font-size: 12.5px; color: var(--text-2); font-weight: 650; }
.mtable thead th small, .mtable td small { display: block; font-size: 12px; font-weight: 500; color: var(--text-3); }
.mtable tbody th { text-align: left; font-weight: 600; color: var(--text-2); }
.mtable td b { font-size: 15.5px; }
.mtable tr:last-child th, .mtable tr:last-child td { border-bottom: 0; }
.gdot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; margin-right: 6px; background: var(--text-3); }
.gdot.st-green { background: var(--ok); }
.gdot.st-yellow { background: var(--warn); }
.gdot.st-red { background: var(--danger); }
.ctype-sel { font: inherit; font-size: 12.5px; padding: 3px 6px; border-radius: 8px; max-width: 150px; }

/* mobil: ukazovatele ako jeden zoskupený zoznam (riadok = názov vľavo, číslo vpravo) */
@media (max-width: 640px) {
  .tiles { grid-template-columns: 1fr; gap: 0; border-radius: var(--r-md); background: var(--glass); box-shadow: var(--rim); overflow: hidden; }
  .tiles > .tile { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 11px 16px; border-radius: 0; background: transparent; box-shadow: none; position: relative; }
  .tiles > .tile + .tile::before { content: ""; position: absolute; top: 0; left: 16px; right: 0; height: .5px; background: var(--sep); }
  .tiles > .tile span { font-size: 15px; color: var(--text); font-weight: 400; }
  .tiles > .tile b { margin: 0; font-size: 17px; font-weight: 600; text-align: right; }
  .tiles > .tile b small { font-size: 13px; }
}
/* typografia: tracking len na veľkých nadpisoch */
body { letter-spacing: normal; }
@media (max-width: 899px) { body { font-size: 16px; } }

/* detail klienta: reklamné účty a e-shop na celú šírku, pripojenia v mriežke */
.xcards > .ads-card { grid-column: 1 / -1; }
.ads-card .plist { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.ads-card .prow { align-items: flex-start; padding: 10px 12px; background: var(--fill); border-radius: var(--r-md); }
.ads-card .prow:hover { background: var(--fill-2); }
.ads-card .prow > .chev { align-self: center; }
@media (max-width: 1100px) { .ads-card .plist { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .ads-card .plist { grid-template-columns: 1fr; } }
/* detail klienta: boxy v jednom riadku rovnako vysoké (bez odsadenia .card + .card) */
.xcards > .card { margin-top: 0; }

/* logo klienta */
.has-logo { background: var(--logo-bg, #fff); overflow: hidden; padding: 5px; box-shadow: inset 0 0 0 .5px rgba(0, 0, 0, .08); }
.has-logo img { width: 100%; height: 100%; object-fit: contain; display: block; }
/* plná ikona: obrázok cez celú plochu, okraj vyplnený jeho farbou */
.has-logo.full { padding: 0; }
.has-logo.full img { object-fit: cover; }
.logo-color { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; background: var(--fill); cursor: pointer; }
.logo-color input { width: 22px; height: 22px; padding: 0; border: 0; background: none; cursor: pointer; }
.logo-color input::-webkit-color-swatch-wrapper { padding: 0; }
.logo-color input::-webkit-color-swatch { border: .5px solid var(--sep); border-radius: 6px; }
.logo-row { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: var(--r-md); background: var(--fill); }
.logo-row > div { flex: 1; min-width: 0; }
.logo-row b { display: block; font-weight: 600; }
.logo-row small { color: var(--text-2); font-size: 13px; }

/* ------------------------------------------------------------ Reporty: prehľad klientov (štýl n8n Daily Overview) */
.rp-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 6px; }
.rp-custom { display: flex; align-items: center; gap: 6px; }
.rp-custom input { height: 32px; border: 0; border-radius: 8px; padding: 0 8px; font: inherit; font-size: 14px; color: var(--text); background: var(--glass); box-shadow: var(--rim); }
.rp-chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 99px; font-size: 13px; font-weight: 600; background: var(--glass); box-shadow: var(--rim); }
.rp-chip i { width: 7px; height: 7px; border-radius: 50%; background: var(--text-3); }
.rp-chip.red i { background: var(--danger); } .rp-chip.yellow i { background: var(--warn); } .rp-chip.green i { background: var(--ok); }
.rp-sub { margin: 4px 0 14px; color: var(--text-2); font-size: 13.5px; }
.rp-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-bottom: 22px; }
.rp-kpi { padding: 12px 14px; border-radius: var(--r-md); background: var(--glass); box-shadow: var(--rim); min-width: 0; }
.rp-kpi > span { font-size: 13px; color: var(--text-2); }
.rp-kpi > div { display: flex; align-items: center; gap: 10px; justify-content: space-between; }
.rp-kpi b { font-size: 28px; font-weight: 700; letter-spacing: -.02em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.rp-kpi small { font-size: 12px; color: var(--text-3); }
.rp-kpi em, .chg { font-style: normal; font-weight: 600; }
.up { color: var(--ok); } .down { color: var(--danger); }
.spk { width: 110px; height: 32px; flex: 0 1 110px; min-width: 0; overflow: hidden; }
.rp-kpi b { flex: none; }
.rp-kpi { container-type: inline-size; }
@container (max-width: 215px) { .rp-kpi .spk { display: none; } }
.spk polyline { fill: none; stroke: var(--blue); stroke-width: 1.6; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.spk circle { fill: var(--blue); }
.spk.red polyline { stroke: var(--danger); } .spk.red circle { fill: var(--danger); }
.spk.teal polyline { stroke: var(--teal); } .spk.teal circle { fill: var(--teal); }
.rp-h { font-family: var(--font-display); font-size: 19px; font-weight: 600; margin: 6px 0 10px; letter-spacing: -.01em; }
.rp-h small { font-size: 13px; color: var(--text-3); font-weight: 500; margin-left: 6px; }
.att-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-bottom: 22px; }
.att { display: grid; gap: 4px; padding: 14px 16px; border-radius: var(--r-lg); background: var(--glass); box-shadow: var(--rim), inset 0 0 0 1px color-mix(in srgb, var(--danger) 30%, transparent); color: inherit; min-width: 0; }
.att.st-yellow { box-shadow: var(--rim), inset 0 0 0 1px color-mix(in srgb, var(--warn) 35%, transparent); }
.att:hover { background: var(--glass-solid); }
.att-top { display: flex; align-items: center; gap: 8px; min-width: 0; }
.att-top b { font-size: 17px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.att .dot, .orow .dot { width: 8px; height: 8px; border-radius: 50%; flex: none; background: var(--text-3); }
.st-red .dot { background: var(--danger); } .st-yellow .dot { background: var(--warn); } .st-green .dot { background: var(--ok); }
.att-note { font-size: 12.5px; font-weight: 600; color: var(--danger); background: var(--danger-soft); padding: 2px 9px; border-radius: 99px; white-space: nowrap; }
.att.st-yellow .att-note { color: var(--warn); background: var(--warn-soft); }
.att-lbl { color: var(--text-3); font-size: 12.5px; }
.att-mid { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.att-big { font-size: 36px; font-weight: 700; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.att p { margin: 0; font-size: 13px; color: var(--text-2); }
.att-foot { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: center; margin-top: 6px; }
.att-foot small { font-size: 12px; color: var(--text-3); white-space: nowrap; }
.att-foot .dm, .att-foot .dg { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 4px; background: var(--blue); }
.att-foot .dg { background: var(--teal); }
.split { display: flex; height: 5px; border-radius: 99px; background: var(--fill); overflow: hidden; min-width: 60px; }
.split i { display: block; height: 100%; }
.split .m { background: var(--blue); } .split .g { background: var(--teal); }
.og { border-radius: var(--r-lg); background: var(--glass); box-shadow: var(--rim); margin-bottom: 14px; overflow: hidden; }
.og-head, .orow { display: grid; grid-template-columns: 14px minmax(140px, 1.4fr) minmax(70px, .9fr) 90px minmax(150px, 1.6fr) 90px 110px 64px; gap: 12px; align-items: center; padding: 10px 16px; }
.og-head { font-size: 11.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--text-3); font-weight: 600; padding-block: 9px; border-bottom: .5px solid var(--sep); }
.og-head span:first-child { grid-column: 1 / 3; }
.orow { color: inherit; position: relative; }
.orow + .orow::before { content: ""; position: absolute; top: 0; left: 42px; right: 0; height: .5px; background: var(--sep); }
.orow:hover { background: var(--fill); }
.oname { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.onum, .okpi { font-variant-numeric: tabular-nums; font-weight: 600; text-align: right; }
.ores { font-size: 13.5px; color: var(--text-2); min-width: 0; }
.ores small { display: block; font-size: 12px; color: var(--text-3); }
.orow .chg { justify-self: end; font-size: 12.5px; padding: 2px 8px; border-radius: 99px; background: var(--fill); }
.orow .chg.up { background: rgba(52, 199, 89, .14); } .orow .chg.down { background: var(--danger-soft); }
.rp-foot { margin-top: 8px; }
@media (max-width: 1100px) {
  .rp-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .og-head span:nth-child(2), .orow .split, .og-head span:nth-child(6), .orow .spk { display: none; }
  .og-head, .orow { grid-template-columns: 14px minmax(120px, 1.4fr) 80px minmax(130px, 1.6fr) 80px 60px; }
}
@media (max-width: 760px) {
  .att-grid { grid-template-columns: 1fr; }
  .og-head { display: none; }
  .orow { grid-template-columns: 14px minmax(0, 1fr) auto; grid-template-areas: "d n k" ". r c"; row-gap: 2px; }
  .orow .dot { grid-area: d; } .orow .oname { grid-area: n; } .orow .okpi { grid-area: k; }
  .orow .ores { grid-area: r; } .orow .chg { grid-area: c; } .orow .onum { display: none; }
}
