/* Dům: styl „Apple TV“ (tmavé pozadí, skleněné karty, záře) přepsaný na plynulé jednotky, aby obrazovky fungovaly
   na monitoru, tabletu i telefonu. Barvy, písmo a poloměry jsou z návrhu televizních obrazovek (common.css). */
:root {
  --bg: #05070c; --pad: 96px; --gap: 24px;
  --green: #34d399; --amber: #fbbf24; --rose: #fb7185; --cyan: #38bdf8; --dim: #94a3b8;
  --t-dim: rgba(255,255,255,.62); --t-faint: rgba(255,255,255,.5);
  --ac: #e5e7eb;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: #fff; font-family: Inter, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif; -webkit-font-smoothing: antialiased; overflow: hidden; }
html, body { height: 100%; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; color: inherit; border: 0; background: none; padding: 0; margin: 0; cursor: pointer; text-align: inherit; }
button:disabled { cursor: not-allowed; }
:focus-visible { outline: 2px solid rgba(255,255,255,.9); outline-offset: 3px; }

/* Pevná plocha 1920×1080 jako na televizi: obsah se nepřeskládává, jen se celá plocha zvětší nebo zmenší podle okna (--k nastavuje app.js). */
.tv { position: absolute; left: 50%; top: 50%; width: 1920px; height: 1080px; overflow: hidden; background: var(--bg); transform: translate(-50%, -50%) scale(var(--k, 1)); }
.scroller { position: absolute; inset: 0; z-index: 1; overflow-x: hidden; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: rgba(255,255,255,.25) transparent; display: flex; flex-direction: column; }
#view { flex: 1 0 auto; display: flex; flex-direction: column; }
.screen { flex: 1 0 auto; }
.scroller.fixed #view { flex: 1 1 0; min-height: 0; }
.glow { position: absolute; width: 2112px; height: 2112px; left: -576px; top: -1190.4px; border-radius: 50%; filter: blur(60px); opacity: .55; transition: background .5s ease; pointer-events: none; z-index: 0; }
.glow.b { left: auto; top: auto; right: -960px; bottom: -1497.6px; opacity: .28; }

/* ---------- horní lišta ---------- */
.top { position: relative; z-index: 6; display: flex; align-items: center; gap: 28px; padding: 44px var(--pad) 0; min-height: 44px; font-size: 22px; font-weight: 600; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 10px; font-size: 25.92px; font-weight: 700; letter-spacing: -.2px; }
.brand svg { width: 1.15em; height: 1.15em; fill: #fff; }
.crumb { color: rgba(255,255,255,.55); font-weight: 600; margin-left: -6px; }
.top .sp { flex: 1; }
.pill { display: flex; align-items: center; gap: 10px; color: rgba(255,255,255,.72); font-weight: 500; white-space: nowrap; }
.pill i { width: 9px; height: 9px; border-radius: 50%; flex: none; }
.clock { font-weight: 600; font-variant-numeric: tabular-nums; }
.lnk { height: 40px; padding: 0 18px; border-radius: 20px; display: inline-flex; align-items: center; font-size: 16px; font-weight: 600; color: rgba(255,255,255,.86); white-space: nowrap; }
.logout { color: rgba(255,255,255,.5); font-size: .9em; padding: 4px 8px; }

.eyebrow { font-size: 18px; font-weight: 700; letter-spacing: 2.4px; text-transform: uppercase; color: var(--t-dim); }
.title { font-size: 76px; font-weight: 800; letter-spacing: -.02em; line-height: 1.04; margin-top: 12px; overflow-wrap: anywhere; }
.meta { font-size: 25.92px; color: rgba(255,255,255,.74); margin-top: 16px; line-height: 1.4; }
.sub { font-size: 23px; color: rgba(255,255,255,.66); margin-top: 10px; }
.page { position: relative; z-index: 2; padding: 0 var(--pad) 72px; }
.stack > * + * { margin-top: var(--gap); }

.g { background: rgba(255,255,255,.09); backdrop-filter: blur(30px) saturate(160%); -webkit-backdrop-filter: blur(30px) saturate(160%); box-shadow: inset 0 0 0 1px rgba(255,255,255,.11); border-radius: 22px; }
/* zaostření jako na tvOS: zvětšení, zvednutí a lesk, žádný rámeček */
.fc { position: relative; transition: transform .32s cubic-bezier(.2,.8,.2,1), box-shadow .32s ease, background .3s ease, opacity .3s ease; }
.fc::after { content: ''; position: absolute; inset: 0; border-radius: inherit; background: linear-gradient(115deg, rgba(255,255,255,.34) 0%, rgba(255,255,255,.08) 22%, rgba(255,255,255,0) 46%); opacity: 0; transition: opacity .32s ease; pointer-events: none; }
@media (hover: hover) {
  .fc:hover:not(:disabled):not(.dis) { transform: translateY(-4px) scale(1.03); box-shadow: 0 24px 44px rgba(0,0,0,.55), inset 0 0 0 1px rgba(255,255,255,.16); z-index: 3; }
  .fc:hover:not(:disabled):not(.dis)::after { opacity: 1; }
}
.fc:focus-visible { transform: translateY(-4px) scale(1.03); box-shadow: 0 24px 44px rgba(0,0,0,.55); z-index: 3; outline: none; }
.fc:focus-visible::after { opacity: 1; }

/* ---------- pozadí s obrázkem ---------- */
.bg { position: absolute; left: 0; right: 0; top: 0; height: 760px; background-size: cover; background-position: center; z-index: 0; transition: background-image .45s ease, opacity .45s ease; }
.bg.data { background-image: none !important; }
.bg::after { content: ''; position: absolute; inset: 0; background:
  linear-gradient(90deg, rgba(5,7,12,.94) 0%, rgba(5,7,12,.62) 38%, rgba(5,7,12,.08) 72%),
  linear-gradient(180deg, rgba(5,7,12,.55) 0, rgba(5,7,12,0) 22%, rgba(5,7,12,0) 34%, rgba(5,7,12,.86) 76%, #05070c 100%); }
.bg.right { left: 28%; }
.bg.right::after { background: linear-gradient(180deg, rgba(5,7,12,.78) 0, rgba(5,7,12,0) 20%), linear-gradient(90deg, #05070c 4%, rgba(5,7,12,.5) 40%, rgba(5,7,12,.12) 100%), linear-gradient(180deg, rgba(5,7,12,0) 30%, rgba(5,7,12,.92) 82%, #05070c 100%); }

/* ---------- dlaždice a čísla ---------- */
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 230px), 1fr)); gap: var(--gap); }
.tiles.c4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.tile { padding: 22px 24px; display: flex; flex-direction: column; min-height: 118px; text-align: left; }
.tile .l { font-size: 17px; font-weight: 600; color: var(--t-dim); line-height: 1.25; }
.tile .v { margin-top: auto; padding-top: 8px; font-size: 38px; font-weight: 700; letter-spacing: -.8px; line-height: 1.1; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.tile .v.lg { font-size: 25px; letter-spacing: -.3px; line-height: 1.2; }
.tile .v small { font-size: .5em; font-weight: 600; color: var(--t-dim); margin-left: 6px; letter-spacing: 0; }
.tile .s { font-size: 15px; color: var(--t-faint); margin-top: 5px; min-height: 1.2em; }
.tile.g1 { background: linear-gradient(155deg, rgba(52,211,153,.22), rgba(52,211,153,.03) 70%), rgba(255,255,255,.06); }
.tile.w1 { background: linear-gradient(155deg, rgba(251,191,36,.26), rgba(251,191,36,.04) 70%), rgba(255,255,255,.06); }
.tile.b1 { background: linear-gradient(155deg, rgba(251,113,133,.26), rgba(251,113,133,.04) 70%), rgba(255,255,255,.06); }
.tile.dimd .v { color: rgba(255,255,255,.4); }
.tile.sel { box-shadow: inset 0 0 0 2px rgba(255,255,255,.7); }
.tone-g { color: var(--green); } .tone-w { color: var(--amber); } .tone-b { color: var(--rose); }

.tabs { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.tab { height: 48px; padding: 0 20px; border-radius: 24px; display: inline-flex; align-items: center; font-size: 20px; font-weight: 600; color: rgba(255,255,255,.8); white-space: nowrap; }
.tab.on { background: rgba(255,255,255,.22); color: #fff; }
.tab.fc, .tab.fc:hover, .tab.fc:focus-visible { transform: none !important; box-shadow: inset 0 0 0 1px rgba(255,255,255,.11); }
.tab.fc::after { display: none; }
@media (hover: hover) { .tab.fc:hover { background: rgba(255,255,255,.17); color: #fff; } }
.tab.fc:focus-visible { box-shadow: 0 0 0 2px rgba(255,255,255,.9); }
.tabs .nt { margin-left: auto; font-size: 15px; line-height: 1.35; color: var(--t-faint); max-width: 620px; }
.scroll-x { overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.scroll-x::-webkit-scrollbar { display: none; }

.msg { font-size: 22px; font-weight: 600; min-height: 1.6em; display: flex; align-items: center; gap: 12px; }
.spin { width: 20px; height: 20px; border-radius: 50%; border: 3px solid rgba(255,255,255,.25); border-top-color: #fff; animation: spin .9s linear infinite; flex: none; }
@keyframes spin { to { transform: rotate(360deg); } }
.note { font-size: 14px; color: var(--t-faint); line-height: 1.45; }
.soon { padding: 44px; max-width: 720px; font-size: 24px; line-height: 1.5; color: rgba(255,255,255,.8); }
.soon b { display: block; font-size: 1.5em; margin-bottom: 8px; }

/* ---------- potvrzovací okno ---------- */
.dlg { position: absolute; inset: 0; z-index: 50; display: flex; align-items: center; justify-content: center; padding: 24px; background: rgba(5,7,12,.74); backdrop-filter: blur(40px) saturate(140%); -webkit-backdrop-filter: blur(40px) saturate(140%); animation: dlgin .3s ease; }
@keyframes dlgin { from { opacity: 0; } to { opacity: 1; } }
.dlg .box { width: min(100%, 640px); text-align: center; }
.dlg .box b { display: block; font-size: 48px; font-weight: 800; letter-spacing: -1px; line-height: 1.1; }
.dlg .box p { font-size: 24px; line-height: 1.45; color: rgba(255,255,255,.72); margin: 16px 0 32px; }
.db { display: flex; width: min(100%, 440px); height: 68px; margin: 0 auto 14px; border-radius: 22px; align-items: center; justify-content: center; font-size: 22px; font-weight: 700; }
.db.primary { background: rgba(255,255,255,.94); color: #05070c; }

/* ---------- tlačítka voleb ---------- */
.opt { min-height: 52px; padding: 8px 18px; border-radius: 18px; display: inline-flex; align-items: center; gap: 9px; font-size: 19px; font-weight: 600; white-space: nowrap; color: rgba(255,255,255,.9); }
.opt svg { width: 24px; height: 24px; fill: currentColor; flex: none; }
.opt.on { background: var(--ac); color: #06121c; box-shadow: 0 0 34px color-mix(in srgb, var(--ac) 45%, transparent); }
.opt.dis, .opt:disabled { opacity: .32; }
.opt.sq { width: 64px; padding: 0; justify-content: center; font-size: 30px; }
.btn { height: 56px; padding: 0 28px; border-radius: 18px; background: rgba(255,255,255,.92); color: #05070c; font-weight: 700; font-size: 18px; display: inline-flex; align-items: center; justify-content: center; }

/* =================== HOME =================== */
.hero { position: relative; z-index: 2; min-height: 470px; padding: 70px var(--pad) 0; }
.hero .info { max-width: min(900px, 100%); }
.big { display: flex; align-items: baseline; gap: 28px; margin-top: 18px; flex-wrap: wrap; }
.big b { font-size: 64px; font-weight: 700; letter-spacing: -1px; font-variant-numeric: tabular-nums; }
.big b small { font-size: .44em; font-weight: 600; color: var(--t-dim); margin-left: 6px; }
.hint { margin-top: 20px; font-size: 16px; color: var(--t-faint); display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.go { height: 40px; padding: 0 18px; border-radius: 20px; background: rgba(255,255,255,.92); color: #05070c; font-weight: 700; font-size: 17px; display: inline-flex; align-items: center; }
.screen.home { flex: 1 1 0; min-height: 0; display: flex; flex-direction: column; }
.screen.home .hero { flex: none; }
.rows { position: relative; z-index: 3; padding-bottom: 60px; flex: 1 1 0; min-height: 0; overflow-x: hidden; overflow-y: auto; scroll-snap-type: y proximity; scrollbar-width: none; -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 22px); mask-image: linear-gradient(180deg, transparent 0, #000 22px); }
.rows::-webkit-scrollbar { display: none; }
/* šipky řady pro myš (na dotyku se řada posouvá prstem) */
.rowwrap { position: relative; }
.rows .row { scroll-snap-align: start; scroll-margin-top: 4px; }
.rowbtn { position: absolute; top: 18px; bottom: 30px; width: 84px; z-index: 6; display: flex; align-items: center; justify-content: center; font-size: 60px; font-weight: 300; color: #fff; opacity: 0; transition: opacity .2s ease; }
.rowbtn.l { left: 0; background: linear-gradient(90deg, rgba(5,7,12,.9), rgba(5,7,12,0)); }
.rowbtn.r { right: 0; background: linear-gradient(270deg, rgba(5,7,12,.9), rgba(5,7,12,0)); }
.rowwrap:hover .rowbtn, .rowbtn:focus-visible { opacity: 1; }
.rowbtn[hidden] { display: none; }
@media (hover: none) { .rowbtn { display: none; } }
/* dotyk: výběr karty (první klepnutí), plynulý švih, žádné rozmazání za kartami během posunu */
.card.sel { transform: translateY(-6px) scale(1.06); box-shadow: 0 30px 50px rgba(0,0,0,.6), 0 0 0 2px rgba(255,255,255,.8); z-index: 4; }
.card { -webkit-touch-callout: none; -webkit-user-select: none; user-select: none; }
.track { overscroll-behavior-x: contain; -webkit-overflow-scrolling: touch; touch-action: pan-x pan-y; }
.rows { overscroll-behavior-y: contain; }
.rows.scrolling .glass .face { backdrop-filter: none; -webkit-backdrop-filter: none; background: rgba(40,46,58,.78); }
.rows.scrolling .card { transition: none; }
.row { margin-top: 30px; }
.rt { padding: 0 var(--pad); font-size: 23px; font-weight: 700; color: rgba(255,255,255,.86); }
.track { display: flex; gap: 28px; padding: 18px var(--pad) 30px; overflow-x: auto; scroll-snap-type: x proximity; scrollbar-width: none; scroll-padding: 0 var(--pad); }
.track::-webkit-scrollbar { display: none; }
.card { position: relative; flex: none; scroll-snap-align: start; border-radius: 22px; cursor: pointer; transition: transform .32s cubic-bezier(.2,.8,.2,1), box-shadow .32s ease, filter .3s ease; display: block; }
@media (hover: hover) { .card:hover, .card:focus-visible { transform: translateY(-6px) scale(1.06); box-shadow: 0 30px 50px rgba(0,0,0,.6); z-index: 4; } }
.card:focus-visible { transform: translateY(-6px) scale(1.06); outline: none; box-shadow: 0 30px 50px rgba(0,0,0,.6), 0 0 0 2px rgba(255,255,255,.8); z-index: 4; }
.card .face { position: absolute; inset: 0; border-radius: 22px; overflow: hidden; background-size: cover; background-position: center; }
.card .face::after { content: ''; position: absolute; inset: 0; background: linear-gradient(115deg, rgba(255,255,255,.3) 0%, rgba(255,255,255,.07) 22%, rgba(255,255,255,0) 46%); opacity: 0; transition: opacity .32s ease; }
.card:hover .face::after, .card:focus-visible .face::after { opacity: 1; }
.glass { width: 300px; height: 170px; }
.glass.wide { width: 405px; }
.glass .face { background: rgba(255,255,255,.09); backdrop-filter: blur(30px) saturate(160%); -webkit-backdrop-filter: blur(30px) saturate(160%); box-shadow: inset 0 0 0 1px rgba(255,255,255,.11); }
.glass .face.heat { background: linear-gradient(155deg, rgba(251,146,60,.42), rgba(251,146,60,.08) 70%), rgba(255,255,255,.05); }
.glass .face.cool { background: linear-gradient(155deg, rgba(56,189,248,.42), rgba(56,189,248,.08) 70%), rgba(255,255,255,.05); }
.glass .face.hot { background: linear-gradient(155deg, rgba(239,68,68,.45), rgba(239,68,68,.1) 70%), rgba(255,255,255,.05); }
.glass .face.cold { background: linear-gradient(155deg, rgba(56,189,248,.26), rgba(56,189,248,.05) 70%), rgba(255,255,255,.05); }
.glass .face.warn { background: linear-gradient(155deg, rgba(251,191,36,.42), rgba(251,191,36,.08) 70%), rgba(255,255,255,.05); }
.glass .face.frost { background: radial-gradient(ellipse at center, rgba(56,189,248,.4) 40%, rgba(255,255,255,.6) 100%); box-shadow: inset 0 0 26px rgba(255,255,255,.6); }
.gc { position: absolute; inset: 0; padding: 16px 18px; display: flex; flex-direction: column; min-width: 0; }
.gc .n { display: flex; align-items: center; gap: 9px; font-size: 19px; font-weight: 600; color: rgba(255,255,255,.88); }
.gc .n svg { width: 22px; height: 22px; fill: currentColor; opacity: .85; flex: none; }
.gc .v { margin-top: auto; display: flex; align-items: baseline; gap: 14px; }
.gc .v b { font-size: 44px; font-weight: 700; letter-spacing: -.8px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.gc .v b small { font-size: .46em; font-weight: 600; color: var(--t-dim); margin-left: 4px; }
.gc .v b.w { font-size: 34px; }
.gc .s { font-size: 16px; color: var(--t-dim); margin-top: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.poster { width: 336px; aspect-ratio: 16/9; }
.poster .face { background-color: #111827; }
.poster .lbl { position: absolute; left: 4px; right: 4px; top: calc(100% + 8px); font-size: 17px; font-weight: 600; color: rgba(255,255,255,.7); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.poster { margin-bottom: 34px; }
.poster .live { position: absolute; left: 12px; top: 10px; font-size: 12px; font-weight: 800; letter-spacing: 1.3px; padding: 4px 9px; border-radius: 8px; background: rgba(0,0,0,.45); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); z-index: 2; }
.poster .live i { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 7px; vertical-align: 1px; }
.poster .stamp { position: absolute; right: 10px; bottom: 8px; font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums; padding: 2px 7px; border-radius: 6px; background: rgba(0,0,0,.45); z-index: 2; }
.poster .ph, .tilecam .ph { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; text-align: center; padding: 8px; font-size: 18px; font-weight: 600; color: rgba(255,255,255,.55); background: linear-gradient(135deg, #1f2937, #0b1220); z-index: 1; }
.poster img.shot { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 1; }
.poster.dead img.shot { filter: grayscale(1) brightness(.5); }

/* =================== STRÁNKY =================== */
.pg-head { position: relative; z-index: 2; padding: 54px var(--pad) 0; min-height: 320px; }
.pg-head .title { font-size: 64px; max-width: 1000px; }
.hv { display: flex; align-items: baseline; gap: 20px; margin-top: 20px; flex-wrap: wrap; }
.hv b { font-size: 92px; font-weight: 800; letter-spacing: -.03em; line-height: 1; font-variant-numeric: tabular-nums; }
.hv b small { font-size: .42em; font-weight: 700; margin-left: 8px; opacity: .7; letter-spacing: -.5px; }
.hv > span { font-size: 23px; font-weight: 500; color: rgba(255,255,255,.7); }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 18px 0; margin: 30px 0; }
.facts .c { padding: 0 28px; border-left: 1px solid rgba(255,255,255,.14); }
.facts .c:first-child { padding-left: 0; border-left: 0; }
.facts .v { font-size: 40px; font-weight: 700; letter-spacing: -.8px; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.facts .l { font-size: 17px; font-weight: 500; color: rgba(255,255,255,.58); margin-top: 4px; }
.stp { margin-top: auto; display: flex; align-items: center; gap: 14px; }
.stp .v { margin-top: 0; padding: 0; }
.sb { width: 44px; height: 44px; border-radius: 22px; background: rgba(255,255,255,.14); font-size: 26px; font-weight: 700; display: flex; align-items: center; justify-content: center; flex: none; }
.tile.tog { cursor: pointer; }

/* =================== ENERGIE =================== */
.energy { display: grid; grid-template-columns: minmax(250px, 30%) minmax(0, 1fr); gap: var(--gap); align-items: start; }
.stage-wrap { position: relative; width: 100%; aspect-ratio: 1920 / 1080; }
.stage { position: absolute; left: 0; top: 0; width: 1920px; height: 1080px; transform-origin: 0 0; --lab: 1; }
.stage .bg-img { position: absolute; left: 0; top: 4px; width: 1920px; height: 1072px; background-size: 100% 100%; background-repeat: no-repeat; transition: filter .5s ease; }
.stage.off .bg-img { filter: grayscale(1) brightness(.6); }
.stage .fl { position: absolute; left: 0; top: 0; pointer-events: none; }
@keyframes flow { from { stroke-dashoffset: var(--a); } to { stroke-dashoffset: calc(var(--a) - var(--per)); } }
.stage .tg { position: absolute; white-space: nowrap; height: 80px; transform: scale(var(--lab)); transform-origin: 0 0; }
.stage .tg.br { height: 109px; }
.stage .tg.r { text-align: right; transform-origin: 100% 0; }
.stage .tg.b { transform-origin: 0 100%; }
.stage .tg.r.b { transform-origin: 100% 100%; }
.stage .tg.r .l, .stage .tg.r .bs { left: auto; right: 0; }
.stage .v { font-weight: 500; font-size: 38px; line-height: 1; letter-spacing: -.2px; transition: text-shadow .3s ease; text-shadow: 0 2px 12px rgba(0,0,0,.7); }
.stage .v small { font-size: 22px; font-weight: 400; margin-left: 6px; }
.stage .l { position: absolute; left: 0; top: 54px; font-weight: 300; font-size: 21px; color: #c9ced6; }
.stage .bs { position: absolute; left: 0; top: 48px; font-weight: 400; font-size: 22px; display: flex; align-items: center; gap: 10px; }
.stage .br .l { top: 84px; }
.stage .v.f { text-shadow: 0 0 26px rgba(255,255,255,.75); }
.st { width: 100%; padding: 16px 22px; display: block; margin-bottom: 14px; }
.st .n { display: flex; align-items: center; gap: 10px; font-size: 19px; font-weight: 600; color: rgba(255,255,255,.8); }
.st .n i { width: 10px; height: 10px; border-radius: 50%; }
.st .v { margin-top: 6px; font-size: 57.6px; font-weight: 700; letter-spacing: -1.4px; line-height: 1.05; font-variant-numeric: tabular-nums; }
.st .v small { font-size: .4em; font-weight: 600; color: var(--t-dim); margin-left: 6px; letter-spacing: 0; }
.st .s { font-size: 17px; font-weight: 600; margin-top: 2px; }
.st.sel { box-shadow: inset 0 0 0 2px rgba(255,255,255,.6); }
.day { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); padding: 0 8px; margin-top: var(--gap); }
.day .c { padding: 18px 20px; position: relative; }
.day .c + .c::before { content: ''; position: absolute; left: 0; top: 24px; bottom: 24px; width: 1px; background: rgba(255,255,255,.12); }
.day .l { font-size: 14px; font-weight: 600; color: rgba(255,255,255,.58); }
.day .v { font-size: 32px; font-weight: 700; letter-spacing: -.5px; margin-top: 6px; font-variant-numeric: tabular-nums; }
.day .v small { font-size: .55em; font-weight: 600; color: var(--t-dim); margin-left: 6px; }
.day .s { font-size: 13px; color: rgba(255,255,255,.45); margin-top: 2px; }
.day.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
/* přepínač pohledů v horní liště hned za drobečkem: Dům · Tok · Přehled dne · Toky dne */
.vtabs { display: flex; gap: 12px; margin-left: 4px; }
.vtabs .tab { height: 44px; padding: 0 20px; font-size: 18px; }
/* pohledy Tok, Přehled dne a Toky dne: plocha 1224 × 720 jako na televizi, zmenšená stejně jako dům (1286 = šířka domu na televizi) */
.stage-wrap .vw { position: absolute; left: 0; top: 0; width: 1224px; height: 720px; transform-origin: 0 0; }
.vw svg { position: absolute; left: 0; top: 0; width: 1224px; height: 720px; overflow: visible; }
.vw .nd { position: absolute; width: 168px; height: 168px; margin: -84px 0 0 -84px; border-radius: 50%; box-sizing: border-box; border: 4px solid; background: rgba(26,31,39,.72); text-align: center; }
.vw .nd .n { position: absolute; left: 0; right: 0; top: 30px; font-size: 21px; font-weight: 600; color: rgba(255,255,255,.62); }
.vw .nd .v { position: absolute; left: 0; right: 0; top: 62px; font-size: 38px; font-weight: 700; letter-spacing: -.6px; font-variant-numeric: tabular-nums; }
.vw .nd .u { position: absolute; left: 0; right: 0; top: 112px; font-size: 18px; font-weight: 600; color: rgba(255,255,255,.6); }
.vw .nc { position: absolute; width: 300px; margin-left: -150px; text-align: center; font-size: 19px; font-weight: 500; color: rgba(255,255,255,.62); }
.vw .dn { position: absolute; width: 400px; height: 400px; margin-left: -200px; text-align: center; }
.vw .dn .t { font-size: 24px; font-weight: 600; color: rgba(255,255,255,.7); }
.vw .ring { position: absolute; left: 100px; top: 56px; width: 200px; height: 200px; }
.vw .ring svg { position: absolute; left: 0; top: 0; width: 200px; height: 200px; transform: rotate(-90deg); }
.vw .ring .tr { fill: none; stroke: rgba(255,255,255,.1); stroke-width: 30; }
.vw .ring .ar { fill: none; stroke-width: 30; }
.vw .ring .c { position: absolute; left: 0; right: 0; top: 66px; text-align: center; }
.vw .ring .c b { display: block; font-size: 48px; font-weight: 700; letter-spacing: -1px; font-variant-numeric: tabular-nums; }
.vw .ring .c span { font-size: 19px; font-weight: 600; color: rgba(255,255,255,.6); }
.vw .lg { position: absolute; top: 290px; width: 190px; font-size: 18px; color: rgba(255,255,255,.6); text-align: left; }
.vw .lg i { display: inline-block; width: 12px; height: 12px; border-radius: 50%; margin-right: 8px; }
.vw .lg b { display: block; margin-top: 4px; font-size: 20px; font-weight: 600; color: #fff; font-variant-numeric: tabular-nums; }
.vw .kp { position: absolute; top: 520px; width: 380px; height: 120px; padding: 22px 26px; box-sizing: border-box; }
.vw .kp .l { font-size: 17px; font-weight: 600; color: rgba(255,255,255,.58); }
.vw .kp .v { font-size: 38px; font-weight: 700; letter-spacing: -.6px; margin-top: 6px; font-variant-numeric: tabular-nums; }
.vw .kp .v small { font-size: 19px; font-weight: 600; color: rgba(255,255,255,.6); margin-left: 6px; }
.vw .skh { position: absolute; top: 74px; font-size: 22px; font-weight: 600; color: rgba(255,255,255,.62); white-space: nowrap; }
.vw .skb { position: absolute; border-radius: 6px; }
.vw .skl { position: absolute; white-space: nowrap; transform: translateY(-50%); }
.vw .skl.r { transform: translate(-100%, -50%); text-align: right; }
.vw .skl b { display: block; font-size: 22px; font-weight: 600; }
.vw .skl span { font-size: 20px; color: rgba(255,255,255,.6); font-variant-numeric: tabular-nums; }
.vw .note { position: absolute; left: 0; right: 0; top: 664px; text-align: center; font-size: 17px; color: rgba(255,255,255,.5); }
.vw .none { position: absolute; left: 0; right: 0; top: 300px; text-align: center; font-size: 30px; font-weight: 600; color: rgba(255,255,255,.6); }

/* =================== KLIMATIZACE =================== */
.klima { display: grid; grid-template-columns: minmax(260px, 30%) minmax(0, 1fr); gap: 54px; }
.room { margin-top: 26px; font-size: 168px; font-weight: 800; letter-spacing: -.04em; line-height: 1; color: var(--ac); font-variant-numeric: tabular-nums; transition: color .4s ease; }
.room small { font-size: .32em; font-weight: 700; letter-spacing: -1px; margin-left: 8px; }
.roomcap { font-size: 18px; font-weight: 600; color: rgba(255,255,255,.55); margin-top: 6px; }
.host { font-size: 15px; color: rgba(255,255,255,.4); margin-top: 12px; }
.ctl .rw { margin-bottom: 18px; }
.ctl .lb { font-size: 14px; font-weight: 700; letter-spacing: 1.6px; text-transform: uppercase; color: rgba(255,255,255,.5); margin-bottom: 8px; }
.ctl .cs { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.setv { min-width: 190px; text-align: center; font-size: 46px; font-weight: 700; letter-spacing: -1px; font-variant-numeric: tabular-nums; }
.setv small { font-size: 18px; font-weight: 600; color: rgba(255,255,255,.55); margin-left: 10px; letter-spacing: 0; }
.heat { --ac: #fb923c; } .cool { --ac: #38bdf8; }
.ov { padding: 44px; border-radius: 28px; text-align: center; background: rgba(20,24,34,.72); box-shadow: inset 0 0 0 1px rgba(255,255,255,.12); margin-bottom: 22px; }
.ov b { display: block; font-size: 40px; font-weight: 800; letter-spacing: -.6px; }
.ov span { display: block; font-size: 22px; color: rgba(255,255,255,.72); margin-top: 12px; line-height: 1.45; }

/* =================== BOJLER =================== */
.bojler { display: grid; grid-template-columns: minmax(0, 1fr) minmax(220px, 420px); gap: 76.8px; align-items: center; padding-top: 50px; }
.state + .meta { margin-top: 44px; }   /* the huge word's descenders (p, y) reach below its line box: the line under it starts clear of them */
.state { font-size: 150px; font-weight: 800; letter-spacing: -.035em; line-height: 1; margin-top: 18px; color: var(--ac); transition: color .4s ease; }
.btns { display: flex; gap: 20px; margin-top: 40px; flex-wrap: wrap; }
.bt { width: min(100%, 280px); height: 84px; border-radius: 26px; display: flex; align-items: center; justify-content: center; gap: 12px; font-size: 24px; font-weight: 700; }
.bt svg { width: 28px; height: 28px; fill: currentColor; }
.bt.dis, .bt:disabled { opacity: .3; }
.tank { position: relative; width: min(100%, 360px); aspect-ratio: 420 / 620; margin: 0 auto; border-radius: 120px; overflow: hidden; background: rgba(255,255,255,.06); box-shadow: inset 0 0 0 1px rgba(255,255,255,.12), 0 0 120px color-mix(in srgb, var(--ac) 40%, transparent); transition: box-shadow .5s ease; }
.water { position: absolute; left: 0; right: 0; bottom: 0; height: 78%; background: linear-gradient(180deg, color-mix(in srgb, var(--ac) 70%, transparent), color-mix(in srgb, var(--ac) 22%, transparent)); transition: background .5s ease; }
.water::before { content: ''; position: absolute; left: -10%; right: -10%; top: -18px; height: 36px; border-radius: 50%; background: color-mix(in srgb, var(--ac) 80%, #fff 8%); opacity: .55; }
.bb { position: absolute; bottom: -14px; width: 12px; height: 12px; border-radius: 50%; background: rgba(255,235,230,.75); opacity: 0; }
.on .bb { animation: rise 4.2s ease-in infinite; }
.bb.b1 { left: 18%; } .bb.b2 { left: 36%; animation-delay: .8s !important; width: 8px; height: 8px; } .bb.b3 { left: 55%; animation-delay: 1.7s !important; } .bb.b4 { left: 72%; animation-delay: 2.6s !important; width: 8px; height: 8px; } .bb.b5 { left: 84%; animation-delay: 3.3s !important; }
@keyframes rise { 0% { transform: translateY(0); opacity: 0; } 15% { opacity: .9; } 85% { opacity: .6; } 100% { transform: translateY(-400px); opacity: 0; } }
.tank svg { position: absolute; left: 50%; top: 50%; width: 38%; height: auto; transform: translate(-50%, -50%); fill: rgba(255,255,255,.9); }
.boiler-on { --ac: #ef4444; } .boiler-cold { --ac: #38bdf8; } .boiler-none { --ac: #94a3b8; }

/* =================== KAMERY =================== */
.camgrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); margin-top: var(--gap); }
.tilecam { position: relative; aspect-ratio: 16/9; border-radius: 20px; overflow: hidden; background-color: #111827; display: block; }
.tilecam img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.tilecam .badge { position: absolute; left: 12px; top: 10px; font-size: 12px; font-weight: 800; letter-spacing: 1.3px; text-transform: uppercase; padding: 4px 9px; border-radius: 8px; background: rgba(0,0,0,.5); z-index: 2; }
.tilecam .badge i { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 7px; vertical-align: 1px; background: currentColor; }
.tilecam .nm { position: absolute; left: 12px; bottom: 10px; z-index: 2; font-size: 17px; font-weight: 700; text-shadow: 0 1px 8px rgba(0,0,0,.8); }
.tilecam.dead img { filter: grayscale(1) brightness(.5); }
.full { position: relative; margin-top: var(--gap); border-radius: 22px; overflow: hidden; background: #000; aspect-ratio: 16/9; max-height: 800px; width: 100%; }
.full img, .full .live-slot { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.full .osd { position: absolute; left: 0; right: 0; top: 0; padding: 14px 18px; display: flex; gap: 16px; align-items: center; background: linear-gradient(180deg, rgba(0,0,0,.7), transparent); z-index: 3; flex-wrap: wrap; }
.full .osd .nm { font-size: 22px; font-weight: 700; }
.full .osd .tm { font-variant-numeric: tabular-nums; color: rgba(255,255,255,.75); }
.full .err { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 24px; background: rgba(5,7,12,.82); z-index: 2; }
.full .err b { font-size: 38px; } .full .err span { margin-top: 10px; font-size: 18px; color: rgba(255,255,255,.7); max-width: 560px; }
.camnav { display: flex; gap: 10px; margin-top: 14px; flex-wrap: wrap; align-items: center; }
.camnav .note { margin-left: auto; }

/* =================== BAZÉN =================== */
.pool-hero { position: absolute; left: 0; right: 0; top: 0; height: 780px; z-index: 0; }
.pool-hero i { position: absolute; inset: 0; background-size: cover; background-position: center; transition: opacity .8s ease; }
.pool-hero::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(5,7,12,.7) 0, rgba(5,7,12,0) 16%), linear-gradient(90deg, rgba(5,7,12,.9) 0%, rgba(5,7,12,.5) 34%, rgba(5,7,12,0) 64%), linear-gradient(180deg, rgba(5,7,12,0) 42%, rgba(5,7,12,.88) 66%, #05070c 86%); }
.tile .bar { position: relative; height: 6px; border-radius: 3px; background: rgba(255,255,255,.14); margin-top: 10px; }
.tile .bar u { position: absolute; top: 0; bottom: 0; border-radius: 3px; background: rgba(52,211,153,.45); }
.tile .bar i { position: absolute; top: -4px; width: 6px; height: 14px; margin-left: -3px; border-radius: 3px; background: #fff; box-shadow: 0 0 10px rgba(255,255,255,.7); }

/* =================== SEKAČKA =================== */
.mower { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 54px; align-items: start; margin-top: 36px; }
.mw { padding: 22px 26px; display: flex; justify-content: space-between; gap: 18px; width: 100%; margin-top: 18px; }
.mw .nm b { font-size: 36px; display: block; }
.mw .chip { display: inline-flex; align-items: center; gap: 8px; margin-top: 8px; font-size: 18px; font-weight: 600; }
.mw .chip i { width: 9px; height: 9px; border-radius: 50%; }
.mw .bt2 { min-width: 120px; text-align: right; }
.mw .bt2 .l { font-size: 14px; color: var(--t-dim); } .mw .bt2 .v { font-size: 40px; font-weight: 700; font-variant-numeric: tabular-nums; }
.mw .bt2 .v small { font-size: .5em; margin-left: 3px; }
.bat { height: 6px; border-radius: 3px; background: rgba(255,255,255,.14); margin-top: 6px; overflow: hidden; } .bat i { display: block; height: 100%; border-radius: 3px; }
.cmds .lh { font-size: 28px; font-weight: 700; }
.cmds .ls { font-size: 16px; color: var(--t-dim); margin: 6px 0 16px; }
.cmd { display: block; width: 100%; padding: 16px 22px; border-radius: 18px; font-size: 21px; font-weight: 600; margin-bottom: 10px; }
.cmd.danger { color: #fecaca; box-shadow: inset 0 0 0 1px rgba(251,113,133,.5); }
.cmd.dis, .cmd:disabled { opacity: .35; }

/* =================== GRAFY =================== */
.chart-wrap { margin-top: var(--gap); position: relative; }
.chart { width: 100%; height: auto; display: block; overflow: visible; }
.chart .grid { stroke: rgba(255,255,255,.12); stroke-width: 1; }
.chart .avg { stroke: rgba(255,255,255,.3); stroke-dasharray: 6 6; }
.chart text { fill: rgba(255,255,255,.6); font-size: 20px; font-family: inherit; }
.chart text.sel { fill: #fff; font-weight: 700; }
.chart .hit { cursor: pointer; fill: transparent; }
.chart .line { fill: none; stroke: #fff; stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; }
.summary { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); margin-top: var(--gap); }
.summary .c .v { font-size: 30px; font-weight: 700; }
.summary .c .l { font-size: 14px; color: var(--t-dim); margin-top: 2px; }
.sel-box .hv b { font-size: 76px; }
.delta { font-size: 24px; font-weight: 700; margin-right: 12px; }

/* =================== PLÁN, AUTA =================== */
.plan { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px; align-items: start; margin-top: var(--gap); }
.plan .map { padding: 16px; } .plan .map img { width: 100%; height: auto; display: block; }
.cars { display: flex; gap: var(--gap); margin-top: var(--gap); overflow-x: auto; padding-bottom: 8px; }
.cc { flex: 1 0 150px; border-radius: 18px; overflow: hidden; text-align: left; opacity: .7; }
.cc.on { opacity: 1; box-shadow: 0 0 0 2px rgba(255,255,255,.7); }
.cc .ph { aspect-ratio: 16/10; background-size: cover; background-position: center; }
.cc .nm { padding: 10px 12px 0; font-weight: 700; } .cc .pl { padding: 2px 12px 12px; font-size: 13px; color: var(--t-dim); }
.car-hero { position: relative; border-radius: 22px; min-height: 420px; background-size: cover; background-position: center; margin-top: var(--gap); }
.acts { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; margin-top: 16px; }
.acts .task { color: var(--amber); font-weight: 600; max-width: 900px; }

/* =================== PŘIHLÁŠENÍ =================== */
.login-page { display: flex; align-items: center; justify-content: center; min-height: 100vh; height: auto; overflow: auto; padding: 20px; }
.login-page .glow { position: fixed; }

/* =================== FOTOVOLTAIKA =================== */
/* strana je ve stejné šabloně jako informační stránky (hlavička, hlavní údaje, záložky, dlaždice); pod předpovědí sloupce po hodinách */
.fvp { padding-top: 0; }
.fvp .tile .v.tone-g { color: var(--green); } .fvp .tile .v.tone-w { color: var(--amber); } .fvp .tile .v.tone-b { color: var(--rose); }
.fvp .tiles.dense { gap: 14px var(--gap); }
.fvp .tiles.dense .tile { min-height: 98px; padding: 13px 22px; }
.fvp .tiles.dense .tile .l { font-size: 15px; white-space: nowrap; }
.fvp .tiles.dense .tile .v { font-size: 28px; padding-top: 4px; }
.fvp .plot { position: relative; display: flex; margin-bottom: 52px; }
.fvp .slot { position: relative; flex: 1 1 0; height: 100%; min-width: 0; cursor: pointer; }
.fvp .slot .bar { position: absolute; left: 19%; width: 62%; bottom: 0; border-radius: 18px 18px 5px 5px; background: linear-gradient(180deg, #fbbf24, rgba(251,191,36,.16)); opacity: .45; transform-origin: 50% 100%; transition: height .5s cubic-bezier(.2,.8,.2,1), opacity .3s ease, transform .3s cubic-bezier(.2,.8,.2,1), box-shadow .3s ease; }
.fvp .slot .bar.now { opacity: .85; }
.fvp .slot .bar.f { opacity: 1; transform: scale(1.07, 1.02); box-shadow: 0 0 70px rgba(251,191,36,.45), 0 24px 40px rgba(0,0,0,.5); }
@media (hover: hover) { .fvp .slot:hover .bar { opacity: 1; } }
.fvp .plot::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: rgba(255,255,255,.16); pointer-events: none; }
.fvp .xl { position: absolute; left: 0; right: 0; top: calc(100% + 12px); text-align: center; font-size: 18px; font-weight: 600; color: rgba(255,255,255,.45); white-space: nowrap; }
.fvp .xl.f { color: #fff; }
.fvp .bub { position: absolute; transform: translate(-50%, -100%); padding: 9px 16px; border-radius: 16px; background: rgba(255,255,255,.94); color: #05070c; font-size: 20px; font-weight: 700; white-space: nowrap; box-shadow: 0 14px 30px rgba(0,0,0,.5); transition: left .3s cubic-bezier(.2,.8,.2,1), top .3s cubic-bezier(.2,.8,.2,1); z-index: 4; font-variant-numeric: tabular-nums; pointer-events: none; }
.fvp .bub small { font-size: 15px; font-weight: 600; color: rgba(5,7,12,.6); margin-left: 8px; }
.fv-cap { margin-top: 12px; font-size: 16px; color: rgba(255,255,255,.42); }
.fv-msg { font-size: 18px; font-weight: 600; color: var(--amber); }
.fv-msg:empty { display: none; }

/* =================== TELEFON / TABLET =================== */
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }
.opt.on:disabled { opacity: .8; }
[hidden] { display: none !important; }

/* =================== PLOCHY PRO TABLET (wide / tab / tall) ===================
   app.js vybere plochu podle poměru stran okna a nastaví data-stage, --sw, --sh a --pad. Plocha je pevná, jen se škáluje.
   wide (1920×1080) = původní vzhled, tady se jí nic nemění; tab (1440×1080, iPad na šířku) a tall (1080×1440, iPad na výšku) mají
   každá vlastní rozvržení. Všechno nové je v tomhle jednom bloku. */
.tv { width: var(--sw, 1920px); height: var(--sh, 1080px); }
html { -webkit-tap-highlight-color: transparent; }
button, a, .card, .tab, .opt { touch-action: manipulation; }
@media (hover: none) {
  .card:hover .face::after { opacity: 0; }
  .card:focus-visible { transform: none; box-shadow: none; }
}

/* ----- společné pro tab i tall ----- */
[data-stage="tab"] .top, [data-stage="tall"] .top { padding-top: 36px; gap: 20px; flex: none; }
[data-stage="tab"] .lnk, [data-stage="tall"] .lnk { height: 48px; padding: 0 22px; border-radius: 24px; font-size: 17px; }
[data-stage="tab"] .brand, [data-stage="tall"] .brand { min-height: 48px; padding-right: 8px; }   /* the only way back to Home on a tablet (no Esc key) */
[data-stage="tab"] .logout, [data-stage="tall"] .logout { min-height: 48px; padding: 0 14px; display: inline-flex; align-items: center; }
[data-stage="tab"] .title, [data-stage="tall"] .title { font-size: 60px; }
[data-stage="tab"] .pg-head .title, [data-stage="tall"] .pg-head .title { font-size: 56px; }
[data-stage="tab"] .page, [data-stage="tall"] .page { padding-bottom: 40px; }
[data-stage="tab"] .sb, [data-stage="tall"] .sb { width: 56px; height: 56px; border-radius: 28px; }
[data-stage="tab"] .glow, [data-stage="tall"] .glow { width: 1500px; height: 1500px; left: -420px; top: -820px; }
[data-stage="tab"] .glow.b, [data-stage="tall"] .glow.b { left: auto; top: auto; right: -620px; bottom: -980px; }
[data-stage="tab"] .tabs .nt, [data-stage="tall"] .tabs .nt { max-width: 100%; margin-left: 0; flex: 1 0 100%; }

/* ----- Domů: menší náhled, víc řad najednou ----- */
[data-stage="tab"] .hero { min-height: 290px; padding-top: 40px; }
[data-stage="tall"] .hero { min-height: 215px; padding-top: 34px; }
[data-stage="tab"] .hero .title { font-size: 56px; } [data-stage="tall"] .hero .title { font-size: 48px; }
[data-stage="tab"] .meta, [data-stage="tall"] .meta { font-size: 22px; margin-top: 10px; }
[data-stage="tab"] .big b { font-size: 52px; } [data-stage="tall"] .big b { font-size: 46px; }
[data-stage="tab"] .big, [data-stage="tall"] .big { margin-top: 10px; }
[data-stage="tab"] .bg { height: 540px; } [data-stage="tall"] .bg { height: 520px; }
[data-stage="tab"] .row, [data-stage="tall"] .row { margin-top: 18px; }
[data-stage="tab"] .track, [data-stage="tall"] .track { gap: 22px; padding-top: 14px; padding-bottom: 26px; }
[data-stage="tab"] .glass, [data-stage="tall"] .glass { width: 276px; height: 160px; }
[data-stage="tab"] .glass.wide, [data-stage="tall"] .glass.wide { width: 376px; }
[data-stage="tab"] .poster, [data-stage="tall"] .poster { width: 296px; }
[data-stage="tab"] .gc .v b, [data-stage="tall"] .gc .v b { font-size: 40px; }
[data-stage="tab"] .gc .v b.w, [data-stage="tall"] .gc .v b.w { font-size: 32px; }

/* ----- Klimatizace ----- */
[data-stage="tab"] .klima { grid-template-columns: 340px minmax(0, 1fr); gap: 40px; }
[data-stage="tab"] .room { font-size: 128px; margin-top: 18px; }
[data-stage="tall"] .klima { grid-template-columns: minmax(0, 1fr); gap: 14px; }
[data-stage="tall"] .room { font-size: 112px; margin-top: 8px; }
[data-stage="tab"] .ctl .rw, [data-stage="tall"] .ctl .rw { margin-bottom: 14px; }
[data-stage="tall"] .ctl .rw { margin-bottom: 14px; }
[data-stage="tall"] .ctl .cs { gap: 8px; }
[data-stage="tab"] .opt, [data-stage="tall"] .opt { min-height: 56px; }
[data-stage="tall"] .opt { font-size: 19px; padding: 8px 15px; }
[data-stage="tab"] .setv, [data-stage="tall"] .setv { min-width: 170px; }

/* ----- Bojler ----- */
[data-stage="tab"] .bojler { grid-template-columns: minmax(0, 1fr) 340px; gap: 48px; padding-top: 24px; min-height: calc(var(--sh) - 200px); }
[data-stage="tab"] .state { font-size: 120px; }
[data-stage="tall"] .bojler { grid-template-columns: minmax(0, 1fr); gap: 36px; padding-top: 20px; }
[data-stage="tall"] .state { font-size: 130px; }
[data-stage="tall"] .tank { width: min(100%, 470px); }
[data-stage="tab"] .tank { width: min(100%, 380px); }
[data-stage="tab"] .state + .meta, [data-stage="tall"] .state + .meta { margin-top: 30px; }
[data-stage="tab"] .btns, [data-stage="tall"] .btns { margin-top: 30px; }
[data-stage="tab"] .bt, [data-stage="tall"] .bt { height: 88px; }
[data-stage="tall"] .btns .bt { flex: 1 1 0; width: auto; }

/* ----- Kamery: mřížka ----- */
[data-stage="tab"] .camgrid { gap: 14px; margin-top: 14px; }
[data-stage="tab"] .page:has(> .camgrid) { padding-bottom: 16px; }
[data-stage="tab"] .page:has(> .camgrid) > .note { margin-top: 10px !important; }
[data-stage="tall"] .camgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin-top: 18px; }
[data-stage="tab"] .full, [data-stage="tall"] .full { max-height: none; }
[data-stage="tab"] .camnav .lnk, [data-stage="tall"] .camnav .lnk { height: 56px; }
[data-stage="tall"] .page:has(> .full) { display: flex; flex-direction: column; min-height: calc(var(--sh) - 100px); }
[data-stage="tall"] .page:has(> .full) .camnav { order: 3; margin-top: auto !important; padding-top: 24px; flex-wrap: nowrap; }
[data-stage="tall"] .page:has(> .full) .camnav .lnk { flex: 1 1 0; height: 96px; justify-content: center; font-size: 22px; border-radius: 28px; }
[data-stage="tall"] .page:has(> .full) > .note { order: 2; }
[data-stage="tall"] .page:has(> .full) > .full { margin-block: auto; }   /* the picture keeps its 16:9 panel (a taller one would crop it) and floats between the header and the buttons */

/* ----- Bazén ----- */
[data-stage="tab"] .pool-hero { height: 600px; } [data-stage="tall"] .pool-hero { height: 700px; }
[data-stage="tab"] .pg-head { min-height: 280px; padding-top: 40px; }
[data-stage="tall"] .pg-head { min-height: 400px; padding-top: 40px; }
[data-stage="tab"] .pg-head[style] { min-height: 400px !important; }
[data-stage="tall"] .pg-head[style] { min-height: 560px !important; }
[data-stage="tab"] .hv b { font-size: 76px; } [data-stage="tall"] .hv b { font-size: 84px; }
[data-stage="tall"] .tiles.c4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
[data-stage="tab"] .tiles.c4 .tile { min-height: 190px; }
[data-stage="tall"] .tiles.c4 .tile { min-height: 150px; }

/* ----- Sekačka ----- */
[data-stage="tab"] .mower { gap: 36px; margin-top: 28px; }
[data-stage="tall"] .mower { grid-template-columns: minmax(0, 1fr); gap: 30px; margin-top: 36px; }
[data-stage="tall"] .cmd { min-height: 104px; }
[data-stage="tall"] .cmds .lh { font-size: 34px; }
[data-stage="tall"] .cmds .ls { font-size: 19px; margin-bottom: 22px; }
[data-stage="tab"] .cmd, [data-stage="tall"] .cmd { padding: 18px 24px; }
[data-stage="tab"] .cmd { min-height: 76px; font-size: 22px; }
[data-stage="tab"] .mw { padding: 28px 30px; }
[data-stage="tab"] .mw .nm b { font-size: 42px; }
[data-stage="tall"] .cmd { font-size: 24px; padding: 26px 28px; margin-bottom: 14px; }
[data-stage="tall"] .mw { padding: 30px 32px; }
[data-stage="tall"] .mw .nm b { font-size: 46px; }
[data-stage="tall"] .mw .bt2 .v { font-size: 52px; }

/* ----- Grafy (šířku a výšku grafu bere grafy.js z plochy) ----- */
[data-stage="tab"] .tabs .tab, [data-stage="tall"] .tabs .tab { height: 48px !important; }   /* the chart chips set 40px inline; a finger needs 48 */
[data-stage="tall"] .chart-wrap { margin-top: 20px; }
[data-stage="tall"] .sel-box .hv b { font-size: 84px; }

/* ----- Energie: dům nahoře, čtyři údaje pod ním ----- */
[data-stage="tab"] .energy, [data-stage="tall"] .energy { grid-template-columns: minmax(0, 1fr); gap: 16px; }
[data-stage="tab"] .energy > div:first-child, [data-stage="tall"] .energy > div:first-child { display: contents; }
[data-stage="tab"] .energy .stage-wrap, [data-stage="tall"] .energy .stage-wrap { order: 1; }
[data-stage="tab"] .energy .stage-wrap { max-width: 1040px; margin: 0 auto; }
[data-stage="tab"] .energy > div:first-child > div:not(.eyebrow), [data-stage="tall"] .energy > div:first-child > div:not(.eyebrow) { order: 2; margin-top: 0 !important; }
[data-stage="tab"] .energy > div:first-child > div:not(.eyebrow) > div, [data-stage="tall"] .energy > div:first-child > div:not(.eyebrow) > div { display: grid; gap: 16px; }
[data-stage="tab"] .energy > div:first-child > div:not(.eyebrow) > div { grid-template-columns: repeat(4, minmax(0, 1fr)); }
[data-stage="tall"] .energy > div:first-child > div:not(.eyebrow) > div { grid-template-columns: repeat(2, minmax(0, 1fr)); }
[data-stage="tab"] .st, [data-stage="tall"] .st { margin-bottom: 0; padding: 14px 20px; min-height: 48px; }
[data-stage="tab"] .st .v { font-size: 46px; }
[data-stage="tall"] .st .v { font-size: 56px; }
[data-stage="tab"] .day { grid-template-columns: repeat(6, minmax(0, 1fr)); margin-top: 18px; }
[data-stage="tab"] .day .c { padding: 14px 14px; }
[data-stage="tab"] .day .v { font-size: 27px; }
[data-stage="tall"] .day { grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 18px; }
[data-stage="tall"] .day .c:nth-child(3n + 1)::before { display: none; }
[data-stage="tall"] .day .c { padding: 24px 22px; }
[data-stage="tab"] .day.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
[data-stage="tall"] .day.four { grid-template-columns: repeat(2, minmax(0, 1fr)); }
[data-stage="tall"] .day.four .c:nth-child(3n + 1)::before { display: block; }
[data-stage="tall"] .day.four .c:nth-child(2n + 1)::before { display: none; }
[data-stage="tall"] .energy { gap: 22px; }
[data-stage="tall"] .st { padding: 22px 26px; }
[data-stage="tall"] .day { margin-top: 22px; }

/* ----- Fotovoltaika ----- */
[data-stage="tab"] .fvp .xl, [data-stage="tall"] .fvp .xl { font-size: 15px; }
[data-stage="tall"] .fvp .bub { font-size: 17px; }

/* ----- Plán pozemku ----- */
[data-stage="tab"] .plan { gap: 32px; }
[data-stage="tall"] .plan { grid-template-columns: minmax(0, 1fr); gap: 20px; }
[data-stage="tall"] .plan .map { max-width: 600px; width: 100%; margin: 0 auto; }
[data-stage="tall"] .plan .tiles { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
[data-stage="tall"] .plan .tile { min-height: 110px; padding: 16px 18px; }

/* ----- Auta ----- */
[data-stage="tab"] .car-hero, [data-stage="tall"] .car-hero { min-height: 320px; }
[data-stage="tab"] .cc, [data-stage="tall"] .cc { flex: 1 0 170px; }
[data-stage="tab"] .cc .ph { aspect-ratio: 2 / 1; }
[data-stage="tab"] .page:has(> .cars) .tile { padding: 16px 22px; }
[data-stage="tall"] .cars { gap: 14px; margin-top: 28px; }
[data-stage="tall"] .cc .ph { aspect-ratio: 1 / 1; }
[data-stage="tall"] .page:has(> .cars) .tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
[data-stage="tall"] .page:has(> .cars) .tile { min-height: 170px; }

/* ----- Stránky (kotel, pojistky, vozy…) ----- */
[data-stage="tab"] .facts, [data-stage="tall"] .facts { margin: 22px 0; }
[data-stage="tab"] .facts .v, [data-stage="tall"] .facts .v { font-size: 34px; }
[data-stage="tab"] .facts .c, [data-stage="tall"] .facts .c { padding: 0 22px; }
[data-stage="tab"] .tiles, [data-stage="tall"] .tiles { gap: 16px; }
[data-stage="tab"] .page.stack .tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-rows: minmax(170px, auto); }
[data-stage="tall"] .page.stack .tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); grid-auto-rows: minmax(190px, auto); gap: 18px; }
/* few tiles = few rows: the rows get taller so the stage is not left empty (7 and more keep 190 or the third row would not fit) */
[data-stage="tall"] .page.stack .tiles:not(:has(> :nth-child(7))) { grid-auto-rows: minmax(270px, auto); }
[data-stage="tab"] .page.stack .tiles:not(:has(> :nth-child(5))) { grid-auto-rows: minmax(260px, auto); }
[data-stage="tab"] .page.stack .tiles.dense { grid-template-columns: repeat(5, minmax(0, 1fr)); grid-auto-rows: minmax(150px, auto); }
[data-stage="tall"] .page.stack .tiles.dense { grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-rows: minmax(190px, auto); gap: 14px; }
[data-stage="tall"] .page.stack .tiles.dense .tile .v { font-size: 36px; } [data-stage="tall"] .page.stack .tiles.dense .tile .v.lg { font-size: 24px; }
[data-stage="tall"] .page.stack .tile .v { font-size: 42px; } [data-stage="tall"] .page.stack .tile .v.lg { font-size: 28px; }
[data-stage="tall"] .page.stack .tile .l { font-size: 19px; } [data-stage="tall"] .page.stack .tile .s { font-size: 16px; }
[data-stage="tab"] .stack > * + *, [data-stage="tall"] .stack > * + * { margin-top: 18px; }

/* Zvoneček termínů v horní liště: odznak s počtem, červený při prošlém termínu, jantarový při blížícím se; bez termínů tlumený */
.bell { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 22px; color: rgba(255,255,255,.34); }
.bell svg { width: 26px; height: 26px; fill: currentColor; }
.bell[data-level="soon"] { color: var(--amber); } .bell[data-level="expired"] { color: var(--rose); }
.bell .bn { position: absolute; top: 2px; right: 0; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 10px; font-size: 13px; font-weight: 800; line-height: 20px; text-align: center; color: #05070c; background: var(--amber); }
.bell[data-level="expired"] .bn { background: var(--rose); }
[data-stage="tab"] .bell, [data-stage="tall"] .bell { width: 48px; height: 48px; }
/* úprava hodnoty */
.facts button.c { text-align: left; background: none; border: 0; color: inherit; font: inherit; cursor: pointer; }
.tile.edit { cursor: pointer; color: inherit; font: inherit; border: 0; }
.dlg .box.edit { text-align: left; }
.dlg .box.edit p { margin: 10px 0 18px; font-size: 20px; }
.ef { display: grid; gap: 14px; margin: 18px 0; }
.ef label { display: grid; gap: 6px; font-size: 18px; color: rgba(255,255,255,.72); }
.ef label.chk { display: flex; align-items: center; gap: 12px; }
.ef input[type=date], .ef input[type=text], .ef input[type=number] { height: 56px; padding: 0 16px; border-radius: 14px; border: 1px solid rgba(255,255,255,.25); background: rgba(255,255,255,.08); color: #fff; font-size: 24px; color-scheme: dark; }
.ef input[type=checkbox] { width: 26px; height: 26px; }
.ef input:disabled { opacity: .45; }
/* seznam termínů */
.trms { display: grid; gap: 10px; }
.trg { font-size: 22px; font-weight: 700; margin: 26px 0 4px; color: rgba(255,255,255,.7); }
.trm { display: grid; grid-template-columns: 1fr 190px 220px; gap: 16px; align-items: center; padding: 16px 24px; text-align: left; color: inherit; font: inherit; border: 0; cursor: pointer; }
.trm .tt { font-size: 21px; font-weight: 600; } .trm .tt small { display: block; font-size: 14px; font-weight: 500; color: var(--t-faint); }
.trm .td { font-size: 21px; font-variant-numeric: tabular-nums; } .trm .ts { font-size: 19px; font-weight: 600; text-align: right; }
@media (max-width: 700px) { .trm { grid-template-columns: 1fr; gap: 4px; } .trm .ts { text-align: left; } }
