/* KOTO IT CARE – typographic, muted palette from the logo, light and dark theme */
@font-face {
  font-family: "Inter";
  src: url("/assets/fonts/InterVariable.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root,
[data-theme="light"] {
  --brand: #2a2e71;
  --paper: #f6f6f9;
  --surface: #ffffff;
  --ink: #23253b;
  --muted: #5f6178;
  --line: #d6d7e2;
  --tone-1: #c5c7d9;   /* lavender grey */
  --tone-2: #7a7c94;   /* mid grey */
  --tone-3: #3c3f5c;   /* slate */
  --tone-4: #23253b;   /* ink */
  --on-tone-1: #23253b;
  --on-dark: #f4f4f8;
  --accent: #2a2e71;
  --dot: rgba(35, 37, 59, .35);
  color-scheme: light;
}
[data-theme="dark"] {
  --brand: #aeb3f0;
  --paper: #0f1020;
  --surface: #171830;
  --ink: #ececf4;
  --muted: #a5a7bf;
  --line: #2c2e4a;
  --tone-1: #33366a;
  --tone-2: #282a55;
  --tone-3: #1d1f40;
  --tone-4: #090a16;
  --on-tone-1: #ececf4;
  --on-dark: #ececf4;
  --accent: #aeb3f0;
  --dot: rgba(236, 236, 244, .3);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font: 17px/1.6 "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  font-feature-settings: "cv11", "ss01";
  color: var(--ink);
  background: var(--paper);
}
a { color: inherit; text-underline-offset: 4px; text-decoration-thickness: 1px; }
a:hover { color: var(--accent); }
h1, h2, h3 { margin: 0 0 .5em; font-weight: 350; letter-spacing: -.035em; line-height: 1.02; }
h1 { font-size: clamp(2.6rem, 7vw, 6rem); }
h2 { font-size: clamp(2rem, 4.6vw, 3.6rem); }
h3 { font-size: clamp(1.25rem, 2vw, 1.6rem); letter-spacing: -.02em; line-height: 1.2; }
strong { font-weight: 600; }
small { color: var(--muted); }
hr { border: 0; border-top: 1px solid var(--line); margin: 2.5rem 0; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

.wrap { width: min(1320px, 100% - 2.5rem); margin-inline: auto; }
.narrow { width: min(820px, 100% - 2.5rem); margin-inline: auto; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 1rem; top: 1rem; z-index: 100; background: var(--surface); padding: .5rem 1rem; }

/* ---------- Header ---------- */
.topbar { border-bottom: 1px solid var(--line); font-size: .85rem; color: var(--muted); }
.topbar .wrap { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .45rem 0; }
.topbar-right { white-space: nowrap; }
.topbar .bodka { margin: 0 .45em; }
.topbar a { text-decoration: none; }
.site-header { position: sticky; top: 0; z-index: 50; background: var(--paper); border-bottom: 1px solid var(--ink); }
/* Výška lišty na jednom mieste – používa ju aj menu, prilepené pásy a úvodný blok. */
:root { --header-h: 76px; }
.header-inner { display: flex; align-items: stretch; min-height: var(--header-h); }
/* Logo má nad sebou aj pod sebou vzduch (Peter, 18. 9. 2026). */
.logo { display: flex; align-items: center; gap: .45rem; padding: 15px 1.5rem 15px 0; font-weight: 700; font-size: 1.3rem; letter-spacing: .01em; text-decoration: none; color: var(--brand); }
.logo span { font-weight: 400; font-size: .72em; letter-spacing: .18em; color: var(--muted); }
.logo img { display: block; height: 46px; width: auto; }
[data-theme="light"] .logo-on-dark, [data-theme="dark"] .logo-on-light { display: none; }
/* Na širokej obrazovke logo vedľa seba a väčšie (Peter, 20. 9. 2026), na užšej pod sebou, aby sa zmestilo. */
.logo-pod, .logo-vedla { display: flex; align-items: center; }
.logo-vedla { display: none; }
/* Logo po dĺžke na mobile aj tablete (Peter, 20. 9. 2026); na širokej obrazovke veľké po dĺžke. */
@media (max-width: 1199px) {
  .logo-pod { display: none; }
  .logo-vedla { display: flex; }
  .logo-vedla img { height: 30px; width: auto; }
}
@media (max-width: 799px) {
  .logo-vedla img { width: min(250px, 62vw); height: auto; }
}
@media (min-width: 1200px) {
  .logo-pod { display: none; }
  .logo-vedla { display: flex; }
  .logo-vedla img { height: 30px; }
}
/* Text menu aj tlačidlo Kontakt zhruba na úrovni nápisu IT CARE v logu (Peter, 20. 9. 2026). */
@media (min-width: 800px) {
  .menu:not(.open) > ul > li > a, .header-cta, .menu-toggle { padding-top: 12px; }
}
.footer-name img { display: block; width: 170px; max-width: 100%; height: auto; }
.menu { display: flex; flex: 1; }
.menu > ul { display: flex; list-style: none; margin: 0; padding: 0; }
.menu > ul > li { display: flex; }
.menu a { display: flex; align-items: center; padding: 0 .9rem; text-decoration: none; font-size: .98rem; white-space: nowrap; }
.menu .active > a { text-decoration: underline; }
.has-sub { position: relative; }
.sub {
  position: absolute; top: 100%; left: 0; min-width: 300px; list-style: none; margin: 0; padding: .6rem 0;
  background: var(--paper); border: 1px solid var(--ink); border-top: 0;
  opacity: 0; visibility: hidden; transform: translateY(-4px); transition: .18s ease;
}
.has-sub:hover .sub, .has-sub:focus-within .sub { opacity: 1; visibility: visible; transform: none; }
.sub a { padding: .4rem 1.1rem; font-size: .95rem; }
.sub a:hover { background: var(--tone-1); color: var(--on-tone-1); }
.header-cta { display: flex; align-items: center; gap: .6rem; margin-left: auto; padding: 0 1.4rem; background: var(--ink); color: var(--paper); text-decoration: none; font-size: 1rem; }
.header-cta:hover { color: var(--paper); background: var(--brand); }
/* Kontakt na rovnakej úrovni ako text menu – musí byť až za skratkou padding vyššie. */
@media (min-width: 800px) { .header-cta { padding-top: 12px; } }
[data-theme="dark"] .header-cta:hover { color: var(--tone-4); }
.menu-toggle { border: 0; border-left: 1px solid var(--line); background: transparent; color: var(--ink); cursor: pointer; font: inherit; padding: 0 1rem; }
/* Prepínač svetlý/tmavý je v hornom pruhu pri kontaktoch (Peter, 20. 9. 2026). */
.theme-toggle { border: 0; background: transparent; color: var(--muted); cursor: pointer; font: inherit; font-size: 1.05rem; line-height: 1; padding: 0; margin-left: 1.4rem; vertical-align: -1px; }
.theme-toggle:hover { color: var(--ink); }
.menu-toggle { display: none; }
/* Nápis Menu na rovnakej úrovni ako položky menu – musí byť až za skratkou padding vyššie. */
@media (min-width: 800px) { .menu-toggle { padding-top: 12px; } }
[data-theme="light"] .i-moon, [data-theme="dark"] .i-sun { display: none; }

/* Tablet aj desktop majú rovnaké veľkosti; čo sa nezmestí, schová app.js do tlačidla Menu. */
.menu > ul > li.skryta, .menu > ul > li.len-v-menu { display: none; }
.menu.open > ul > li.len-v-menu { display: flex; }
.menu.open > ul > li.skryta { display: flex; }
.menu > ul > li.vpravo .sub { left: auto; right: 0; }   /* podmenu pri pravom okraji sa otvorí doľava */
.site-header.zbalene .menu-toggle { display: block; margin-left: auto; }
.site-header.zbalene .header-cta { display: none; }   /* keď pribudne Menu, Kontakt ustúpi (Peter, 20. 9. 2026) */
.menu.open {
  position: absolute; left: 0; right: 0; top: 100%; display: block; z-index: 40;
  background: var(--surface); border-bottom: 1px solid var(--ink);   /* vlastná plocha, nech nesplýva so stránkou */
  box-shadow: 0 18px 40px rgba(0, 0, 0, .3);
  max-height: calc(100vh - var(--header-h)); overflow: auto;
}
.menu.open > ul { flex-direction: column; padding: .5rem 0 1rem; margin-inline: 0; }
.menu.open > ul > li { flex-direction: column; }
.menu.open a { padding: .55rem 1.25rem; }
.menu.open .sub { position: static; opacity: 1; visibility: visible; transform: none; border: 0; background: transparent; padding: 0 0 .4rem 1rem; min-width: 0; }
/* Rozbalené menu je zarovnané doprava, podpoložky sú odsadené od pravého okraja. */
.menu.open a { justify-content: flex-end; text-align: right; padding: .55rem 1.25rem; }
.menu.open > ul > li > a { font-weight: 700; font-size: 1.12rem; padding-top: .8rem; }   /* hlavné sekcie výraznejšie ako podpoložky */
.menu.open .sub { padding: 0 0 .4rem; }
.menu.open .sub a { padding-right: 2.5rem; }
/* Na väčšej obrazovke sa otvorí pod tlačidlom Menu. */
@media (min-width: 800px) {
  .header-inner { position: relative; }
  .menu.open { left: auto; right: 0; width: min(380px, calc(100vw - 2.5rem)); border: 1px solid var(--ink); border-top: 0; }
}

/* Menu nech sa nelepí na logo (Peter, 20. 9. 2026). */
/* Menu stojí kúsok od loga a tam ostane – pri zužovaní okna ubúdajú položky sprava (Peter, 20. 9. 2026). */
@media (min-width: 800px) {
  .menu { margin-left: -1.5rem; }   /* zruší pravý odsadok loga, aby sa odstup meral od jeho konca */
  .menu > ul { margin-inline: auto; }   /* na stred voľného miesta; app.js stráži minimá po stranách */
}

/* Rozbaľovacie menu až na mobile; na tablete ostáva celé menu v riadku (Peter, 20. 9. 2026). */
@media (max-width: 799px) {
  /* Nápis Menu na úrovni nápisu IT CARE v logu, rovnako ako na väčších obrazovkách. */
  .menu-toggle { display: block; margin-left: auto; padding-top: 13px; }
  .header-cta { display: none; }
  .menu { position: absolute; left: 0; right: 0; top: 100%; display: none; background: var(--paper); border-bottom: 1px solid var(--ink); max-height: calc(100vh - var(--header-h)); overflow: auto; }
  .menu.open { display: block; }
  .menu > ul { flex-direction: column; padding: .5rem 0 1rem; }
  .menu > ul > li { flex-direction: column; }
  .menu a { padding: .55rem 1.25rem; }
  .sub { position: static; opacity: 1; visibility: visible; transform: none; border: 0; padding: 0 0 .4rem 1rem; min-width: 0; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .8rem; padding: .85rem 1.5rem;
  border: 1px solid currentColor; background: transparent; color: inherit;
  font: inherit; font-size: .98rem; text-decoration: none; cursor: pointer; transition: .2s ease;
}
.btn::after { content: "→"; transition: transform .2s ease; }
.btn:hover { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.btn:hover::after { transform: translateX(4px); }
.btn-solid { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.btn-solid:hover { background: var(--brand); border-color: var(--brand); color: #fff; }
[data-theme="dark"] .btn-solid:hover { color: var(--tone-4); }
.on-dark .btn:hover { background: var(--on-dark); color: var(--tone-4); border-color: var(--on-dark); }
.btn-small { padding: .55rem 1rem; font-size: .9rem; }
.cta { display: flex; flex-wrap: wrap; gap: .8rem; margin: 2rem 0; }

/* ---------- Graphic elements ---------- */
.dots {
  background-image: radial-gradient(var(--dot) 1.6px, transparent 1.8px);
  background-size: 18px 18px;
  -webkit-mask-image: radial-gradient(ellipse at center, #000 30%, transparent 72%);
          mask-image: radial-gradient(ellipse at center, #000 30%, transparent 72%);
}
.stripes {
  height: clamp(160px, 26vw, 320px);
  background: repeating-linear-gradient(180deg, var(--tone-4) 0 var(--s, 6px), transparent var(--s, 6px) 22px);
  animation: stripes 9s linear infinite;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 15%, #000 85%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 15%, #000 85%, transparent);
}
[data-theme="dark"] .stripes { background: repeating-linear-gradient(180deg, var(--tone-1) 0 var(--s, 6px), transparent var(--s, 6px) 22px); }
@keyframes stripes { to { background-position: 0 220px; } }
.rule { border-top: 1px solid currentColor; opacity: .35; margin: 1.5rem 0; }

/* Image slot until photos are delivered */
.media {
  position: relative; min-height: 320px; overflow: hidden;
  background: linear-gradient(135deg, var(--surface), var(--tone-1));
  display: flex; align-items: flex-end; padding: 1.25rem;
}
.media::before { content: ""; position: absolute; inset: 0; }
.media .dots { position: absolute; inset: 0; }
.media-label { position: relative; font-size: .8rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }

/* ---------- Scroll reveal ---------- */
.js .reveal { opacity: 0; transform: translateY(28px); transition: opacity .8s ease, transform .8s cubic-bezier(.2, .7, .2, 1); }
.js .reveal.is-in { opacity: 1; transform: none; }
.js .reveal-delay-1 { transition-delay: .1s; }
.js .reveal-delay-2 { transition-delay: .2s; }
.js .reveal-delay-3 { transition-delay: .3s; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .stripes { animation: none; }
}

/* ---------- Home ---------- */
.hero-home { padding: 1.25rem 0 0; }
.hero-panel {
  position: relative; min-height: min(calc(100vh - var(--header-h) - 50px), 760px); background: var(--tone-1); color: var(--on-tone-1);
  display: flex; flex-direction: column; padding: clamp(2rem, 5vw, 4rem);
  overflow: hidden;
}
.hero-panel > h1:first-of-type, .hero-panel > .crumb { margin-top: auto; }
.hero-panel .dots { position: absolute; right: -8%; top: -10%; width: 55%; height: 120%; opacity: .7; }
.hero-panel h1 { position: relative; font-size: clamp(3rem, 7.2vw, 7rem); line-height: .92; letter-spacing: -.055em; max-width: 12ch; }
.hero-panel .lead { position: relative; font-size: clamp(1.1rem, 2vw, 1.5rem); max-width: 40ch; margin: 1.5rem 0 0; }
.hero-foot { position: relative; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 1rem; margin-top: auto; padding-top: 2rem; }
.hero-home .hero-panel > h1 { margin-top: auto; }
@media (max-width: 700px) {
  .hero-panel { min-height: 0; }
  /* Horný pruh nech ostane na jednom riadku aj na mobile (Peter, 20. 9. 2026). */
  .topbar { font-size: clamp(.68rem, 3.1vw, .8rem); }
  .topbar .wrap { gap: .5rem; white-space: nowrap; }
  .topbar .theme-toggle { margin-left: .9rem; }
}
.scroll-hint { font-size: 1.15rem; }

.intro { display: grid; grid-template-columns: 1.1fr 1fr; gap: 0; }
.intro .media { min-height: 420px; }
.intro-text { padding: clamp(2rem, 5vw, 4rem); display: flex; flex-direction: column; justify-content: center; }
.intro-text p { font-size: clamp(1.15rem, 2vw, 1.45rem); line-height: 1.45; margin-top: 0; }
@media (max-width: 860px) { .intro { grid-template-columns: 1fr; } .intro .media { min-height: 260px; } }

.statement { padding: clamp(4rem, 10vw, 8rem) 0; }
.statement p.big { font-size: clamp(1.4rem, 3vw, 2.3rem); line-height: 1.3; letter-spacing: -.02em; max-width: 30ch; margin: 0 0 2.5rem; }

/* Stacked bands – each area sticks and the next one slides over it */
.stack { position: relative; }
.band { padding: clamp(3rem, 7vw, 5.5rem) 0; }
.stack .band { min-height: 86vh; }
@media (min-width: 900px) and (min-height: 700px) {
  .stack .band { position: sticky; top: var(--header-h); }
}
.band h2 { margin-bottom: 2.5rem; }
.band-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; }
@media (max-width: 860px) { .band-grid { grid-template-columns: 1fr; } }
.band p.text { max-width: 44ch; font-size: 1.05rem; }
.tone-1 { background: var(--tone-1); color: var(--on-tone-1); }
.tone-2 { background: var(--tone-2); color: var(--on-dark); }
.tone-3 { background: var(--tone-3); color: var(--on-dark); }
.tone-4 { background: var(--tone-4); color: var(--on-dark); }
.paper { background: var(--paper); }
.list-links { list-style: none; margin: 0; padding: 0; columns: 2 220px; column-gap: 2rem; }
.list-links li { break-inside: avoid; border-top: 1px solid currentColor; border-color: color-mix(in srgb, currentColor 25%, transparent); }
.list-links a { display: flex; justify-content: space-between; gap: 1rem; padding: .7rem 0; text-decoration: none; }
.list-links a::after { content: "→"; opacity: .5; transition: .2s ease; }
.list-links a:hover::after { opacity: 1; transform: translateX(4px); }
.on-dark a:hover { color: #fff; }

.features { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 0 3rem; }
.features li { border-top: 1px solid var(--line); padding: 1.3rem 0; }
.features strong { display: block; font-weight: 500; font-size: 1.2rem; letter-spacing: -.01em; margin-bottom: .3rem; }
.features span { color: var(--muted); }
.on-dark .features li { border-color: rgba(255, 255, 255, .2); }
.on-dark .features span { color: rgba(255, 255, 255, .75); }

.steps { counter-reset: s; list-style: none; margin: 0; padding: 0; }
.steps li { counter-increment: s; display: flex; gap: 1.5rem; align-items: baseline; border-top: 1px solid var(--line); padding: 1rem 0; font-size: 1.2rem; }
.steps li::before { content: counter(s, decimal-leading-zero); font-size: .85rem; color: var(--muted); min-width: 2ch; }

.partners { list-style: none; margin: 0 0 1rem; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 0 2rem; }
.partners li { border-top: 1px solid var(--line); padding: 1rem 0; }
.partners strong { display: block; font-weight: 500; font-size: 1.45rem; letter-spacing: -.01em; }
@media (min-width: 1100px) { .partners { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.partners span { color: var(--muted); font-size: .9rem; }
.brands { font-size: clamp(1.3rem, 2.6vw, 2rem); font-weight: 300; letter-spacing: -.02em; line-height: 1.6; }
.brands span { opacity: .35; margin: 0 .4rem; }
.note { color: var(--muted); font-size: .9rem; }

/* ---------- Inner pages ---------- */
.hero-page { padding: 1.25rem 0 0; }
.hero-page .hero-panel { min-height: 0; padding-block: clamp(3rem, 8vw, 6rem); }
.hero-page .hero-panel h1 { font-size: clamp(2.6rem, 7vw, 6.2rem); max-width: 16ch; }
.crumb { position: relative; font-size: .9rem; margin: 0 0 1.2rem; }
.crumb a { text-decoration: none; }
.crumb a::before { content: "← "; }

.page-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: clamp(2rem, 6vw, 6rem); padding: clamp(3rem, 6vw, 5rem) 0; }
@media (max-width: 960px) { .page-grid { grid-template-columns: 1fr; } }
.prose { max-width: 70ch; font-size: 1.05rem; }
/* Stránka s kartami sekcií využije celú šírku stĺpca; odseky ostanú čitateľne úzke. */
.prose:has(.bloky) { max-width: none; }
.prose:has(.bloky) > p { max-width: 70ch; }
.prose h2 { font-size: clamp(1.8rem, 3.4vw, 2.6rem); margin-top: 3rem; padding-top: 1.2rem; border-top: 1px solid var(--ink); }
.prose h3 { margin-top: 2.6rem; padding-top: 1rem; border-top: 1px solid var(--line); }
.prose > h2:first-child, .prose > h3:first-child { margin-top: 0; }
.prose ul, .prose ol { padding-left: 1.1rem; }
.prose li { margin: .35rem 0; }
.blok-siroky > ul > li:first-child { margin-top: 0; }   /* oba stĺpce začínajú rovnako */
.prose li::marker { color: var(--muted); }
.xlinks { display: inline-block; margin-top: .3rem; color: var(--muted); }
.xlink { color: var(--ink); }
.badge {
  display: inline-block; margin-left: .4rem; padding: .1rem .45rem; vertical-align: middle;
  border: 1px solid currentColor; font-size: .66rem; letter-spacing: .1em; text-decoration: none; color: var(--brand);
}
.badge:hover { background: var(--ink); color: var(--paper); }

.side { display: flex; flex-direction: column; gap: 1.5rem; }
.box { border-top: 1px solid var(--ink); padding-top: 1rem; }
.box p { margin: 0 0 .9rem; }
.box-title { font-size: 1.25rem; font-weight: 400; letter-spacing: -.01em; }
.box-accent { background: var(--tone-1); color: var(--on-tone-1); border: 0; padding: 1.4rem; }
.side-list { list-style: none; margin: 0; padding: 0; }
.side-list a { display: block; padding: .35rem 0; text-decoration: none; color: var(--muted); }
.side-list a:hover, .side-list .current a { color: var(--ink); }
.side-list .current a::before { content: "→ "; }
.big { font-size: 1.5rem; letter-spacing: -.02em; }

.section-list { list-style: none; margin: 0; padding: 0; }
.section-list li { border-top: 1px solid var(--ink); }
.section-list li:last-child { border-bottom: 1px solid var(--ink); }
.section-list a { display: grid; grid-template-columns: 4rem 1fr 1fr auto; gap: 1.5rem; align-items: baseline; padding: 1.6rem 0; text-decoration: none; }
.section-list .n { color: var(--muted); font-size: .9rem; }
.section-list h2 { font-size: clamp(1.5rem, 3vw, 2.3rem); margin: 0; }
.section-list p { margin: 0; color: var(--muted); }
.section-list a::after { content: "→"; font-size: 1.4rem; transition: .2s ease; }
.section-list a:hover::after { transform: translateX(6px); }
.section-list a:hover h2 { color: var(--accent); }
@media (max-width: 760px) { .section-list a { grid-template-columns: 1fr auto; } .section-list .n, .section-list p { display: none; } }

/* ---------- Form ---------- */
.form { display: grid; grid-template-columns: 1fr 1fr; gap: 1.6rem 2rem; }
.form-wide { grid-column: 1 / -1; }
@media (max-width: 640px) { .form { grid-template-columns: 1fr; } }
.form label { display: flex; flex-direction: column; gap: .4rem; font-size: .9rem; color: var(--muted); }
.form input, .form select, .form textarea {
  font: inherit; font-size: 1.05rem; color: var(--ink); background: transparent;
  border: 0; border-bottom: 1px solid var(--ink); border-radius: 0; padding: .55rem 0; width: 100%;
}
.form select option { background: var(--paper); color: var(--ink); }
.form textarea { border: 1px solid var(--ink); padding: .7rem; resize: vertical; }
.form input[type="file"] { border: 0; font-size: .9rem; }
.form input:focus, .form select:focus, .form textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 1px 0 var(--accent); }
.form [aria-invalid="true"] { border-color: #c2413b; }
.field-error { color: #c2413b; font-size: .88rem; }
[data-theme="dark"] .field-error, [data-theme="dark"] .form [aria-invalid="true"] { color: #ff8a80; border-color: #ff8a80; }
.form-note { color: var(--muted); font-size: .9rem; margin: 0; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.alert { padding: 1rem 1.25rem; margin-bottom: 1.5rem; border: 1px solid currentColor; }
.alert-ok { color: #1f7a4d; }
.alert-err { color: #c2413b; }
[data-theme="dark"] .alert-ok { color: #6fd6a2; }
[data-theme="dark"] .alert-err { color: #ff8a80; }

/* ---------- Footer ---------- */
.site-footer { background: var(--tone-4); color: var(--on-dark); padding: clamp(3rem, 7vw, 6rem) 0 2rem; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
/* Logo, konzultácia a kontakt vedľa seba, každý so svojím priestorom (Peter, 18. 9. 2026). */
.footer-top {
  display: grid; grid-template-columns: auto auto auto; justify-content: space-between; align-items: center;
  column-gap: clamp(2rem, 5vw, 5rem); row-gap: 2rem; padding-bottom: 3rem; border-bottom: 1px solid rgba(255, 255, 255, .2);
}
.footer-cta .btn { white-space: nowrap; }
@media (max-width: 1000px) {
  .footer-top { grid-template-columns: auto auto; justify-content: start; row-gap: 2.75rem; }
  .footer-contact { grid-column: 1 / -1; }
}
.footer-name { font-size: clamp(2.2rem, 5vw, 4.2rem); font-weight: 300; letter-spacing: -.04em; line-height: 1; margin: 0; }
.footer-contact a { display: block; font-size: clamp(1.25rem, 2.4vw, 1.9rem); font-weight: 300; letter-spacing: -.02em; line-height: 1.3; }
.footer-contact p { margin: 1rem 0 0; opacity: .75; }
.footer-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; padding-top: 2.5rem; font-size: .93rem; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-grid li { margin: .3rem 0; }
.f-head { font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; opacity: .6; margin: 0 0 .8rem; }
.footer-grid small, .site-footer small { color: inherit; opacity: .65; }
@media (max-width: 760px) { .footer-top, .footer-grid { grid-template-columns: 1fr; } .footer-top { row-gap: 1.75rem; } }

/* Režim plánovania fotiek (?fotky=1) – zelené rámčeky tam, kam patria fotky. */
.foto-mode {
  position: relative; z-index: 70; padding: 8px 16px; text-align: center; font-size: .9rem;
  background: #1f9d5a; color: #fff;
}
.foto-mode a { color: #fff; font-weight: 700; margin-left: .5rem; }
.foto-slot {
  display: grid; place-content: center; gap: .4rem; margin: 1.5rem 0; padding: 1.25rem; text-align: center;
  border: 2px dashed #2fbf71; border-radius: 12px; background: rgba(47, 191, 113, .14); color: var(--ink);
  aspect-ratio: 16 / 9; position: relative;
}
.foto-slot.foto-4-3 { aspect-ratio: 4 / 3; }
.foto-slot.foto-3-2 { aspect-ratio: 3 / 2; }
.foto-slot.foto-21-9 { aspect-ratio: 21 / 9; }
.foto-slot strong { font-size: 1rem; line-height: 1.35; }
.foto-slot small { color: var(--muted); font-size: .8rem; }
.foto-slot-tag {
  position: absolute; top: 10px; left: 10px; padding: 2px 10px; border-radius: 999px;
  background: #1f9d5a; color: #fff; font-size: .75rem; font-weight: 700; letter-spacing: .04em;
}
.media .foto-slot { position: absolute; inset: 12px; margin: 0; aspect-ratio: auto; }
.on-dark .foto-slot, .hero-panel .foto-slot { color: inherit; }
.on-dark .foto-slot small { color: inherit; opacity: .75; }
@media (max-width: 480px) { .foto-slot { aspect-ratio: auto; min-height: 180px; } }

/* Koľko textu – prepínač vľavo dole (oproti „Kolega je online"). */
.uroven[hidden] { display: none; }
/* Tlačidlá Text a Značka: jedna tmavá lišta, aby ich bolo vidieť na svetlom aj tmavom podklade
   (Peter, 20. 9. 2026 – predtým biele tlačidlá splývali so stránkou). Farba je rovnaká v oboch režimoch. */
.plavajuce {
  position: fixed; left: 18px; bottom: 18px; z-index: 60; display: flex; align-items: center;
  gap: 0; padding: 4px; border-radius: 999px; max-width: calc(100vw - 110px);
  background: #23253b; box-shadow: 0 10px 30px rgba(0, 0, 0, .42);
}
.plavajuce:empty { display: none; }
.uroven-ctrl { position: relative; }   /* ponuka sa otvára nad tlačidlom, na ktoré sa kliklo */
.uroven-btn {
  display: flex; align-items: center; gap: 8px; padding: 8px 15px; border-radius: 999px; cursor: pointer;
  border: 0; background: transparent; color: #f4f4f8; font: inherit; font-size: 14.5px;
}
/* Deliaca čiara je medzi tlačidlami. Zvýraznenie je zaoblené len zvonka, pri čiare ostáva rovné
   (Peter, 20. 9. 2026) – a na oboch tlačidlách rovnako. */
.uroven-ctrl + .uroven-ctrl { border-left: 1px solid rgba(255, 255, 255, .25); }
.uroven-ctrl:first-child:not(:last-child) .uroven-btn { border-radius: 999px 0 0 999px; }
.uroven-ctrl:last-child:not(:first-child) .uroven-btn { border-radius: 0 999px 999px 0; }
.uroven-btn:hover { background: rgba(255, 255, 255, .14); }
/* Po príchode na stránku lišta raz jemne poskočí, aby si ju návštevník všimol. */
@keyframes plavajuce-poskok {
  0%, 10%, 18%, 100% { transform: translateY(0); }
  5% { transform: translateY(-12px); }
  14% { transform: translateY(-5px); }
}
.plavajuce { animation: plavajuce-poskok 6s ease-in-out .2s 3; }
/* Kto má v systéme obmedzený pohyb, nedostane skákanie, ale krátke rozsvietenie okraja. */
@keyframes plavajuce-svit {
  0%, 12%, 100% { box-shadow: 0 10px 30px rgba(0, 0, 0, .42); }
  4%, 8% { box-shadow: 0 0 0 4px rgba(120, 128, 220, .55), 0 10px 30px rgba(0, 0, 0, .42); }
}
@media (prefers-reduced-motion: reduce) {
  .plavajuce { animation: plavajuce-svit 6s ease-in-out .2s 3; }
}
.uroven-btn:focus-visible { outline: 2px solid #ffffff; outline-offset: 2px; }
/* V tmavom režime svetlá lišta s tmavým písmom – tmavá by na tmavej stránke splývala (Peter, 20. 9. 2026). */
[data-theme="dark"] .plavajuce { background: #eceff8; box-shadow: 0 10px 30px rgba(0, 0, 0, .55); }
[data-theme="dark"] .uroven-btn { color: #23253b; }
[data-theme="dark"] .uroven-ctrl + .uroven-ctrl { border-left-color: rgba(35, 37, 59, .25); }
[data-theme="dark"] .uroven-btn:hover { background: rgba(35, 37, 59, .12); }
[data-theme="dark"] .uroven-btn:focus-visible { outline-color: #23253b; }
.uroven-menu {
  position: absolute; left: 0; bottom: calc(100% + 8px); min-width: 210px; max-width: calc(100vw - 24px); padding: 6px; display: grid; gap: 4px;
  border: 1px solid var(--line); border-radius: 14px; background: var(--surface); box-shadow: 0 18px 48px rgba(0, 0, 0, .35);
}
.uroven-menu[hidden] { display: none; }
.uroven-item {
  display: grid; text-align: left; gap: 2px; padding: 9px 12px; border-radius: 10px; cursor: pointer;
  border: 1px solid transparent; background: none; color: var(--ink); font: inherit;
}
.uroven-item span { font-size: 13px; color: var(--muted); }
.uroven-item:hover { background: var(--paper); }
.uroven-item[aria-checked="true"] { border-color: var(--accent); }
@media (max-width: 480px) {
  .site-footer { padding-bottom: 5.5rem; }   /* plávajúce tlačidlá nesmú zakryť posledný riadok */
  .plavajuce { left: 12px; bottom: 12px; }
  .uroven-btn { padding: 8px 12px; font-size: 13.5px; }
}

/* Fotky na stránkach (public/assets/foto, plán v content/fotky.json). */
.foto { position: relative; margin: 1.5rem 0; }
.foto img { display: block; width: 100%; height: auto; border-radius: 12px; }
.foto-produkt { padding: 1.5rem; border-radius: 12px; background: #ffffff; }   /* biely podklad – Ajax má fotky na bielom */
.foto-produkt img { width: auto; max-width: 100%; max-height: 340px; margin: 0 auto; border-radius: 0; }
.foto-obrazovka img { border: 1px solid var(--line); }
.foto figcaption { margin-top: .5rem; font-size: .75rem; color: var(--muted); }
.foto-produkt figcaption { text-align: center; color: #5f6178; }
.foto-hotova { outline: 3px solid #2fbf71; outline-offset: 4px; }
.band .foto-produkt img, .hero-panel .foto-produkt img { max-height: 220px; }
@media (max-width: 600px) { .foto-produkt { padding: 1rem; } .foto-produkt img { max-height: 190px; } }

/* Sekcie stránky ako karty v dvoch stĺpcoch (Prose::blocks), podskupiny v mriežke. */
.bloky { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem; margin: 1.75rem 0; align-items: start; grid-auto-flow: dense; }
/* Karty sa skladajú tesne pod seba, aby pod nižšou kartou nezostala diera (app.js). */
.bloky.skladane { row-gap: 0; grid-auto-rows: 1px; }
.bloky.skladane > .blok { margin-bottom: 1.25rem; }
.blok { border: 1px solid var(--line); border-radius: 14px; padding: 1.2rem 1.4rem; min-width: 0; }
.blok > h3:first-child, .prose .blok h3 { margin-top: 0; padding-top: 0; border-top: 0; }
.blok > :last-child { margin-bottom: 0; }
.blok-siroky { grid-column: 1 / -1; }
.skupiny { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: .5rem 2rem; }
.skupina > p:first-child { margin: .8rem 0 .2rem; }
.skupina ul { margin-top: 0; }
.blok .foto { margin: 0 0 1rem; }
@media (max-width: 760px) {
  .bloky { grid-template-columns: 1fr; }
  .blok { padding: 1rem 1.1rem; }
}
/* Bočný panel ide s čitateľom, keď je dosť vysoké okno (inak by sa jeho spodok nedal prečítať). */
@media (min-width: 961px) and (min-height: 900px) {
  .page-grid .side { position: sticky; top: calc(var(--header-h) + 1.5rem); align-self: start; }
}

/* Rotácia 2–3 fotiek v jednom rámčeku – len CSS, bez skriptu. */
.foto-snimky { display: grid; }
.foto-snimky img { grid-area: 1 / 1; align-self: center; justify-self: center; opacity: 0; }
.rot-2 .foto-snimky img { animation: foto-rot-2 10s infinite; }
.rot-2 .foto-snimky img:nth-child(2) { animation-delay: 5s; }
.rot-3 .foto-snimky img { animation: foto-rot-3 12s infinite; }
.rot-3 .foto-snimky img:nth-child(2) { animation-delay: 4s; }
.rot-3 .foto-snimky img:nth-child(3) { animation-delay: 8s; }
.rot-4 .foto-snimky img { animation: foto-rot-4 16s infinite; }
.rot-4 .foto-snimky img:nth-child(2) { animation-delay: 4s; }
.rot-4 .foto-snimky img:nth-child(3) { animation-delay: 8s; }
.rot-4 .foto-snimky img:nth-child(4) { animation-delay: 12s; }
.foto-snimky img:first-child { opacity: 1; }
@keyframes foto-rot-4 { 0% { opacity: 0; } 4% { opacity: 1; } 25% { opacity: 1; } 29% { opacity: 0; } 100% { opacity: 0; } }
@keyframes foto-rot-2 { 0% { opacity: 0; } 6% { opacity: 1; } 50% { opacity: 1; } 56% { opacity: 0; } 100% { opacity: 0; } }
@keyframes foto-rot-3 { 0% { opacity: 0; } 5% { opacity: 1; } 33% { opacity: 1; } 38% { opacity: 0; } 100% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) {
  .foto-snimky img { animation: none !important; }
  .foto-snimky img:not(:first-child) { display: none; }
}

/* Rad malých produktových fotiek v texte (Photos::row) – na koniec karty. */
.foto-rad { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: .6rem; margin: 1rem 0 0; }
.rad-polozka { margin: 0; display: grid; gap: .35rem; justify-items: center; text-align: center; }
.rad-polozka img { width: 100%; height: 96px; object-fit: contain; padding: .5rem; border-radius: 10px; background: #ffffff; }
.rad-polozka figcaption { font-size: .8rem; line-height: 1.25; color: var(--muted); }
.foto-rad.foto-hotova { outline-offset: 6px; }

/* Široká karta (fotky.json „siroka") – zoznam v dvoch stĺpcoch, rad fotiek cez celú šírku. */
@media (min-width: 761px) {
  .blok-siroky > ul { columns: 2; column-gap: 2.5rem; }
  .blok-siroky > ul li { break-inside: avoid; }
}
.blok-siroky .foto-rad { grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); }
/* Fotka s malým rozlíšením zdroja (napr. záber z detektora) – nenaťahovať. */
.foto-mala { max-width: 460px; }
/* Fotka ako bunka v mriežke podskupín (napr. AI Key pri „Spracovanie na mieste"). */
.skupina-foto { align-self: start; }
.skupina-text { margin: 0 0 .2rem; }
.skupina-foto .foto { margin: .8rem 0 0; }
.skupina-foto .foto-produkt { padding: 1rem; }
.skupina-foto .foto-produkt img { max-height: 160px; }

/* Značka produktov na fotkách (znacka.js) – nad prepínačom textu. */
.znacka[hidden] { display: none; }

.foto-mala.foto-produkt img { max-height: 220px; }
@media (max-width: 560px) { body:has(.chat-badge):has(.plavajuce .uroven-ctrl + .uroven-ctrl) .site-footer { padding-bottom: 9rem; } }
/* Otvorená ponuka musí byť nad tlačidlom chatu, inak by ťuknutie trafilo chat. */
.plavajuce:has(.uroven-menu:not([hidden])) { z-index: 63; }
/* Fotka výrobku v karte nesmie kartu natiahnuť do výšky. */
.blok .foto-produkt img { max-height: 240px; }
