/* ELJEDLA – paleta „Písek“: teplé krémové plochy, kávově hnědé pásy,
   olivová a okrová podle ochranného vodiče PE */
:root {
  --green-50: #eef3e6;
  --green-500: #6f9142;
  --green-600: #5e7f37;
  --green-700: #4d6a2c;
  --yellow-400: #eccd76;
  --yellow-500: #e2b94d;
  --plech-50: #fcfaf5;
  --plech-100: #f6f1e8;
  --plech-200: #f0e9dd;
  --plech-300: #e2d8c8;
  --plech-400: #cabda8;
  --plech-500: #a69782;
  --plech-600: #7c6f5e;
  --plech-700: #5e5347;
  --ink-800: #5a4c40;
  --ink-900: #4a3e34;
  --ink-950: #3d332b;
  --wire-l1: #8b6443;
  --wire-l2: #4a3e34;
  --wire-l3: #a69782;
  --wire-n: #5a7fa8;
  --font-head: "Chivo", ui-sans-serif, system-ui, sans-serif;
  --font-body: "Instrument Sans", ui-sans-serif, system-ui, sans-serif;
  --header-h: 72px;
  --pe: repeating-linear-gradient(-45deg, var(--green-500) 0 14px, var(--yellow-500) 14px 28px);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 8px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink-900);
  background: var(--plech-200);
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3, h4 { font-family: var(--font-head); line-height: 1.05; margin: 0 0 .6em; letter-spacing: -.01em; }
h2 { font-size: clamp(2.2rem, 5vw, 3.6rem); font-weight: 900; color: var(--plech-700); }
h3 { font-size: 1.45rem; font-weight: 700; }
p { margin: 0 0 1em; }

.wrap { max-width: 1320px; margin: 0 auto; padding: 0 20px; }
@media (min-width: 768px) { .wrap { padding: 0 32px; } }

.skip { position: absolute; left: -9999px; top: 8px; background: var(--ink-900); color: #fff; padding: 8px 14px; z-index: 100; }
.skip:focus { left: 8px; }

/* ---------- Tlačítka ---------- */
.btn {
  display: inline-block; padding: 14px 26px; font-family: var(--font-head); font-weight: 700;
  font-size: 1.05rem; letter-spacing: .02em; text-decoration: none; border: 2px solid transparent;
  cursor: pointer; transition: background .2s, color .2s, border-color .2s, transform .2s;
  touch-action: manipulation;
}
.btn:active { transform: translateY(1px); }
.btn-dark { background: var(--ink-900); color: var(--plech-50); }
.btn-dark:hover { background: var(--green-700); }
.btn-light { background: var(--plech-50); color: var(--ink-900); }
.btn-light:hover { background: var(--yellow-500); }
.btn-outline { border-color: var(--plech-50); color: var(--plech-50); }
.btn-outline:hover { background: var(--plech-50); color: var(--ink-900); }
.btn-accent { background: var(--yellow-500); color: var(--ink-900); }
.btn-accent:hover { background: var(--yellow-400); }

/* ---------- Hlavička ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 50; height: var(--header-h);
  background: color-mix(in srgb, var(--plech-200) 88%, transparent); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid color-mix(in srgb, var(--ink-900) 10%, transparent); transition: box-shadow .3s;
}
.site-header.scrolled { box-shadow: 0 10px 30px color-mix(in srgb, var(--ink-900) 14%, transparent); }
.header-inner { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.logo { display: inline-flex; align-items: center; text-decoration: none; flex-shrink: 0; }
.logo img { height: 50px; width: auto; }
@media (min-width: 1024px) { .logo img { height: 60px; } }
.logo-footer img { height: 72px; }

.nav { display: none; gap: 30px; font-size: .97rem; }
.nav a { text-decoration: none; color: var(--plech-700); transition: color .2s; }
.nav a:hover, .nav a.active { color: var(--ink-900); }
.nav a.active { box-shadow: inset 0 -2px 0 var(--green-500); }
.header-phone { display: none; padding: 10px 20px; font-size: 1.15rem; }
.menu-toggle { background: none; border: 0; padding: 8px; margin-right: -8px; color: var(--ink-900); cursor: pointer; }
@media (min-width: 1024px) {
  :root { --header-h: 80px; }
  .nav, .header-phone { display: flex; }
  .menu-toggle { display: none; }
}

.mobile-menu {
  position: fixed; inset: 0; z-index: 60; background: var(--ink-950); color: var(--plech-50);
  display: flex; flex-direction: column; justify-content: center; gap: 36px; padding: 32px 24px;
}
.mobile-menu[hidden] { display: none; }
.mobile-menu nav { display: flex; flex-direction: column; gap: 18px; }
.mobile-menu nav a { font-family: var(--font-head); font-size: 2rem; font-weight: 700; text-decoration: none; }
.mobile-menu .btn { align-self: flex-start; }
.menu-close { position: absolute; top: 12px; right: 16px; background: none; border: 0; color: inherit; font-size: 2.6rem; line-height: 1; cursor: pointer; }

/* ---------- Hero ---------- */
.hero { position: relative; min-height: 100svh; display: flex; align-items: flex-end; color: var(--plech-50); background: var(--ink-950); overflow: hidden; }
.hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 65% center; }
.hero-shade {
  position: absolute; inset: 0;
  background:
    linear-gradient(90deg, color-mix(in srgb, var(--ink-950) 88%, transparent) 0%, color-mix(in srgb, var(--ink-950) 55%, transparent) 55%, color-mix(in srgb, var(--ink-950) 25%, transparent) 100%),
    linear-gradient(0deg, color-mix(in srgb, var(--ink-950) 70%, transparent), transparent 50%);
}
.hero-content { position: relative; padding-top: calc(var(--header-h) + 60px); padding-bottom: 90px; width: 100%; }
.eyebrow { font-weight: 600; letter-spacing: .14em; text-transform: uppercase; font-size: .82rem; color: var(--yellow-500); }
.hero h1 { font-size: clamp(2.8rem, 8.5vw, 6.6rem); font-weight: 900; max-width: 12ch; color: #fff; }
.hero-lead { font-size: clamp(1.05rem, 1.8vw, 1.3rem); max-width: 42ch; color: var(--plech-200); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 28px; }
.pe-wire { position: absolute; left: 0; right: 0; bottom: 0; height: 14px; background: var(--pe); }
.pe-wire-thin { position: static; height: 8px; }

/* ---------- Sekce ---------- */
.section { position: relative; padding: 90px 0; }
@media (min-width: 768px) { .section { padding: 130px 0; } }
.section-alt { background: var(--plech-100); }
.section-dark { background: var(--ink-900); color: var(--plech-200); overflow: hidden; }
.section-dark h2 { color: #fff; }
.section-head { display: grid; gap: 12px 60px; margin-bottom: 56px; align-items: end; }
.section-head h2 { margin: 0; }
.section-head p { margin: 0; color: var(--plech-600); max-width: 46ch; }
@media (min-width: 900px) { .section-head { grid-template-columns: 1fr 1fr; } }

/* karty služeb – rysky v barvách vodičů */
.cards { display: grid; gap: 2px; background: var(--plech-300); border: 2px solid var(--plech-300); }
@media (min-width: 700px) { .cards { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .cards { grid-template-columns: repeat(3, 1fr); } }
.card { background: var(--plech-50); padding: 34px 30px 30px; position: relative; transition: background .25s; }
.card::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--c, var(--ink-900)); transform: scaleY(0); transform-origin: top; transition: transform .35s; }
.card:hover::before { transform: scaleY(1); }
.card:hover { background: #fff; }
.card-muted { background: var(--plech-100); }
.phase { display: inline-block; font-family: var(--font-head); font-weight: 700; font-size: .8rem; letter-spacing: .1em; padding: 3px 10px; color: #fff; background: var(--c); margin-bottom: 18px; }
.phase-l1 { --c: var(--wire-l1); }
.phase-l2 { --c: var(--wire-l2); }
.phase-l3 { --c: var(--wire-l3); }
.phase-n { --c: var(--wire-n); }
.phase-pe { background: var(--pe); color: var(--ink-900); --c: var(--green-500); }
.phase-sub { --c: var(--plech-600); }
.card:has(.phase-l1) { --c: var(--wire-l1); }
.card:has(.phase-l3) { --c: var(--wire-l3); }
.card:has(.phase-n) { --c: var(--wire-n); }
.card:has(.phase-pe) { --c: var(--green-500); }
.card ul { list-style: none; padding: 0; margin: 0; }
.card li { padding: 8px 0; border-top: 1px solid var(--plech-300); color: var(--plech-700); }

/* split layout */
.split { display: grid; gap: 48px; align-items: start; }
@media (min-width: 900px) { .split { grid-template-columns: 1fr 1fr; gap: 80px; } }
.muted-light { color: var(--plech-400); max-width: 44ch; margin-bottom: 32px; }
.hatch { position: absolute; left: 0; right: 0; bottom: 0; height: 10px; background: var(--pe); }
.checklist { list-style: none; padding: 0; margin: 0; }
.checklist li { padding: 18px 0 18px 40px; border-bottom: 1px solid rgba(255,255,255,.1); position: relative; font-size: 1.1rem; color: var(--plech-100); }
.checklist li::before { content: ""; position: absolute; left: 0; top: 24px; width: 18px; height: 10px; border-left: 3px solid var(--yellow-500); border-bottom: 3px solid var(--yellow-500); transform: rotate(-45deg); }

/* O nás */
.split-about { align-items: center; }
.about-photo { margin: 0; position: relative; }
.about-photo img { aspect-ratio: 4 / 5; object-fit: cover; width: 100%; }
.about-photo::after { content: ""; position: absolute; left: -14px; bottom: -14px; width: 45%; height: 14px; background: var(--pe); }
.lead { font-size: 1.3rem; font-weight: 600; color: var(--ink-900); }
#o-nas p { color: var(--plech-700); }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 36px 0 0; border-top: 2px solid var(--ink-900); padding-top: 22px; }
.stats dt { font-family: var(--font-head); font-weight: 900; font-size: clamp(1.4rem, 3vw, 2.1rem); color: var(--green-600); }
.stats dd { margin: 0; font-size: .92rem; color: var(--plech-600); }

/* Galerie */
.gallery { display: grid; gap: 10px; grid-template-columns: repeat(2, 1fr); }
@media (min-width: 900px) { .gallery { grid-template-columns: repeat(3, 1fr); gap: 14px; } }
@media (min-width: 1200px) { .gallery { grid-template-columns: repeat(4, 1fr); } }
.gallery a { display: block; overflow: hidden; aspect-ratio: 4 / 3; background: var(--plech-300); position: relative; }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.gallery a:hover img { transform: scale(1.05); }
.gallery a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 5px; background: var(--pe); transform: scaleX(0); transform-origin: left; transition: transform .35s; }
.gallery a:hover::after, .gallery a:focus-visible::after { transform: scaleX(1); }

.lightbox { position: fixed; inset: 0; z-index: 80; background: color-mix(in srgb, var(--ink-950) 95%, transparent); display: flex; align-items: center; justify-content: center; padding: 60px 16px; }
.lightbox[hidden] { display: none; }
.lightbox img { max-width: min(1400px, 100%); max-height: 100%; object-fit: contain; }
.lb-close, .lb-nav { position: absolute; background: none; border: 0; color: #fff; cursor: pointer; font-size: 3rem; line-height: 1; padding: 8px 14px; }
.lb-close { top: 8px; right: 12px; }
.lb-prev { left: 4px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 4px; top: 50%; transform: translateY(-50%); }
.lb-caption { position: absolute; bottom: 14px; left: 0; right: 0; text-align: center; color: var(--plech-300); margin: 0; font-size: .95rem; padding: 0 16px; }

/* Kontakt */
.split-contact { grid-template-columns: 1fr; }
@media (min-width: 1000px) { .split-contact { grid-template-columns: 1.4fr 1fr; } }
.form { display: grid; gap: 18px; margin-top: 30px; }
.field-row { display: grid; gap: 18px; }
@media (min-width: 640px) { .field-row { grid-template-columns: 1fr 1fr; } }
.form label { display: grid; gap: 6px; font-weight: 500; font-size: .95rem; }
.form input[type=text], .form input[type=tel], .form input[type=email], .form textarea {
  font: inherit; padding: 13px 14px; border: 2px solid var(--plech-400); background: var(--plech-50); color: var(--ink-900); border-radius: 0; width: 100%;
}
.form input:focus, .form textarea:focus { outline: none; border-color: var(--green-600); background: #fff; }
.form .invalid { border-color: #b3261e !important; }
.form textarea { resize: vertical; }
.chips { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.chips legend { font-weight: 500; font-size: .95rem; margin-bottom: 8px; padding: 0; }
.chips label { display: inline-block; cursor: pointer; }
.chips input { position: absolute; opacity: 0; pointer-events: none; }
.chips span { display: inline-block; padding: 8px 14px; border: 2px solid var(--plech-400); font-size: .92rem; transition: all .2s; user-select: none; }
.chips input:checked + span { background: var(--ink-900); border-color: var(--ink-900); color: #fff; }
.chips input:focus-visible + span { outline: 2px solid var(--green-600); outline-offset: 2px; }
.hp { position: absolute !important; left: -9999px; }
.consent { display: flex !important; grid-template-columns: none; gap: 10px !important; align-items: flex-start; font-weight: 400 !important; font-size: .9rem !important; color: var(--plech-700); }
.consent input { margin-top: 4px; width: 18px; height: 18px; accent-color: var(--green-600); flex-shrink: 0; }
.form .btn { justify-self: start; }
.form-status { margin: 0; font-weight: 600; min-height: 1.6em; }
.form-status.ok { color: var(--green-600); }
.form-status.err { color: #b3261e; }

.contact-card { background: var(--ink-900); color: var(--plech-200); padding: 36px 32px; display: grid; gap: 24px; border-top: 8px solid var(--green-500); }
.contact-card .label { display: block; font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; color: var(--yellow-500); font-weight: 600; margin-bottom: 4px; }
.contact-card a { color: #fff; text-decoration: none; }
.contact-card a:hover { color: var(--yellow-400); }
.contact-card .big { font-family: var(--font-head); font-weight: 900; font-size: clamp(1.4rem, 6.4vw, 2rem); white-space: nowrap; }
.contact-card p { margin: 0; }
.contact-card .maplink { display: inline-block; margin-top: 8px; color: var(--yellow-500); font-weight: 600; }
@media (min-width: 1000px) { .contact-card { position: sticky; top: calc(var(--header-h) + 24px); } }

/* Patička */
.site-footer { background: var(--ink-950); color: var(--plech-400); font-size: .95rem; }
.footer-grid { display: grid; gap: 36px; padding-top: 60px; padding-bottom: 40px; }
@media (min-width: 700px) { .footer-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr 1fr; } }
.footer-desc { margin-top: 16px; max-width: 32ch; }
.site-footer h4 { font-family: var(--font-head); color: #fff; font-size: 1rem; letter-spacing: .08em; text-transform: uppercase; margin-bottom: 12px; }
.site-footer a { text-decoration: none; color: var(--plech-300); }
.site-footer a:hover { color: var(--yellow-400); }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; border-top: 1px solid rgba(255,255,255,.08); padding-top: 20px; padding-bottom: 28px; font-size: .85rem; color: var(--plech-600); }
.todo { background: var(--yellow-500); color: var(--ink-900); padding: 0 6px; font-weight: 600; }

/* ---------- Animace ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
@keyframes draw { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.rise { animation: rise .65s cubic-bezier(.22,.61,.36,1) both; animation-delay: var(--d, 0ms); }
.draw { transform-origin: left; animation: draw .9s cubic-bezier(.65,0,.35,1) .3s both; }
.js .reveal { opacity: 0; transform: translateY(26px); transition: opacity .6s ease var(--d, 0ms), transform .6s ease var(--d, 0ms); }
.js .reveal.visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .rise, .draw { animation: none; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
}
