/* Výchozí vzhled nového webu (webkit). Barvy a písmo upravte tady; struktura (třídy) odpovídá templates/layout.php a enginu. */
:root {
  --blue: #1d4ed8; --blue-dark: #1e3a8a; --text: #1f2937; --muted: #64748b; --line: #e2e8f0; --bg: #ffffff; --bg-alt: #f8fafc;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-size: 16px; --radius: 6px; --logo-height: 40px; --header-height: 0px; --footer-text: #dbe4ff;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font: var(--font-size)/1.6 var(--font); color: var(--text); background: var(--bg); }
a { color: var(--blue); }
img, video { max-width: 100%; height: auto; }
.wrap { max-width: 1100px; margin: 0 auto; padding: 0 20px; }
.muted { color: var(--muted); } .small { font-size: .88rem; } .center { text-align: center; }
.btn { display: inline-block; padding: 10px 20px; border-radius: var(--radius); background: var(--blue); color: #fff; text-decoration: none; font-weight: 600; border: 0; cursor: pointer; font: inherit; }
.btn:hover { background: var(--blue-dark); }
.btn-outline { background: transparent; color: var(--blue); border: 2px solid var(--blue); }
.btn-outline:hover { background: var(--blue); color: #fff; }

/* hlavička a menu */
.site-header { border-bottom: 1px solid var(--line); background: var(--bg); position: sticky; top: 0; z-index: 50; }
.header-row { display: flex; align-items: center; gap: 24px; min-height: 64px; }
.brand { font-weight: 800; font-size: 1.25rem; color: var(--blue-dark); text-decoration: none; display: flex; align-items: center; gap: 10px; }
.brand-logo { height: var(--logo-height); width: auto; display: block; }
.header-banner { line-height: 0; }
.header-banner img { display: block; width: 100%; object-fit: cover; }
.header-banner img.fixed { height: var(--header-height); }
.main-nav { margin-left: auto; }
.main-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 4px; }
.main-nav li { position: relative; }
.main-nav a { display: block; padding: 10px 14px; color: var(--text); text-decoration: none; border-radius: var(--radius); font-weight: 500; }
.main-nav li.active > a, .main-nav a:hover { background: var(--bg-alt); color: var(--blue-dark); }
.main-nav .sub { display: none; position: absolute; top: 100%; left: 0; min-width: 220px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 8px 24px rgba(0,0,0,.08); padding: 6px; flex-direction: column; }
.main-nav li:hover > .sub, .main-nav li:focus-within > .sub { display: flex; }
.nav-toggle { display: none; margin-left: auto; width: 44px; height: 44px; border: 0; background: none; cursor: pointer; }
.nav-toggle span { display: block; height: 3px; margin: 7px 8px; background: var(--text); border-radius: 2px; }
@media (max-width: 800px) {
  .nav-toggle { display: block; }
  .main-nav { display: none; position: absolute; left: 0; right: 0; top: 64px; background: #fff; border-bottom: 1px solid var(--line); padding: 10px 20px; }
  body.nav-open .main-nav { display: block; }
  .main-nav ul { flex-direction: column; }
  .main-nav .sub { display: block; position: static; border: 0; box-shadow: none; padding-left: 14px; }
}

/* obsah */
.site-main { min-height: 50vh; padding: 24px 0 48px; }
.page-title { font-size: 2rem; line-height: 1.2; margin: 0 0 20px; color: var(--blue-dark); }
.page-content h2 { margin-top: 2em; } .page-content h3 { margin-top: 1.5em; }
.page-content .box { background: var(--bg-alt); border-left: 4px solid var(--blue); padding: 12px 18px; border-radius: 0 6px 6px 0; margin: 16px 0; }
.page-content table { border-collapse: collapse; width: 100%; margin: 16px 0; }
.page-content td, .page-content th { border: 1px solid var(--line); padding: 8px 10px; text-align: left; }
.page-content :is(p, li, div, blockquote, td, th).text-s { font-size: .88rem; }
.page-content :is(p, li, div, blockquote, td, th).text-l { font-size: 1.15rem; }
.page-content :is(p, li, div, blockquote, td, th).text-xl { font-size: 1.35rem; }
.page-content .signature { font-family: Georgia, "Times New Roman", serif; font-style: italic; font-size: 1.15rem; color: var(--blue-dark); }
.hero { padding: 24px 0 8px; } .hero h1 { font-size: 2.4rem; margin: 0 0 10px; color: var(--blue-dark); } .lead { font-size: 1.2rem; color: var(--muted); }
.notice { background: #fef3c7; border: 1px solid #fcd34d; padding: 8px 12px; border-radius: var(--radius); }
.flash { padding: 10px 0; font-weight: 600; } .flash-ok { background: #dcfce7; color: #166534; } .flash-err { background: #fee2e2; color: #991b1b; }

/* aktuality */
.news-list .news-item { border-bottom: 1px solid var(--line); padding: 16px 0; }
.news-date { font-size: .85rem; color: var(--muted); }
.news-item h3 { margin: 4px 0 8px; }
.news-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; margin: 16px 0; }
.news-card { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: calc(var(--radius) + 2px); overflow: hidden; text-decoration: none; color: inherit; background: #fff; }
.news-card:hover { box-shadow: 0 8px 24px rgba(0,0,0,.08); }
.news-card-media { position: relative; aspect-ratio: 4/3; background: var(--bg-alt); display: block; }
.news-card-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.news-card-body { padding: 14px 16px; display: flex; flex-direction: column; gap: 6px; }
.news-card-title { font-weight: 700; color: var(--blue-dark); } .news-card-text { color: var(--muted); font-size: .92rem; } .news-card-more { color: var(--blue); font-weight: 600; font-size: .9rem; }
.news-media { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; margin: 12px 0; }
.news-media.one { grid-template-columns: minmax(180px, 480px); }

/* dokumenty a odkazy, galerie */
.link-group h3 { margin: 20px 0 8px; } .link-list { list-style: none; padding: 0; margin: 0; } .link-list li { padding: 6px 0; border-bottom: 1px solid var(--line); } .link-list .note { color: var(--muted); font-size: .88rem; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; margin: 16px 0; }
.gallery-item { position: relative; display: block; aspect-ratio: 4/3; overflow: hidden; border-radius: var(--radius); background: var(--bg-alt); }
.gallery-item img, .gallery-item video { width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery-count, .gallery-caption { position: absolute; left: 8px; background: rgba(0,0,0,.6); color: #fff; font-size: .78rem; padding: 2px 8px; border-radius: 10px; }
.gallery-count { top: 8px; } .gallery-caption { bottom: 8px; right: 8px; border-radius: 4px; }
.news-card-play { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: #fff; font-size: 2rem; text-shadow: 0 2px 8px rgba(0,0,0,.6); }

/* formuláře */
.order-form { background: var(--bg-alt); border: 1px solid var(--line); border-radius: calc(var(--radius) + 2px); padding: 20px; margin: 16px 0; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 20px; }
.form-field.wide, .form-section, .form-html { grid-column: 1 / -1; }
.form-field label, .form-label { display: block; font-weight: 600; margin-bottom: 4px; font-size: .92rem; }
.form-field input, .form-field textarea, .form-field select { width: 100%; padding: 8px 10px; border: 1px solid #cbd5e1; border-radius: 5px; font: inherit; }
.form-field.has-error input, .form-field.has-error textarea { border-color: #dc2626; }
.field-error { color: #b91c1c; font-size: .85rem; } .field-note { color: var(--muted); font-size: .85rem; }
.choices { display: flex; flex-direction: column; gap: 4px; } .choice { font-weight: 400; }
.form-errors { background: #fee2e2; color: #991b1b; padding: 8px 12px; border-radius: var(--radius); margin-bottom: 12px; }
.form-success { background: #dcfce7; color: #166534; padding: 14px 18px; border-radius: var(--radius); }
.req { color: #dc2626; } .hp { position: absolute; left: -9999px; } .is-hidden { display: none !important; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } }

/* patička */
.site-footer { background: var(--blue-dark); color: var(--footer-text); padding: 32px 0 16px; font-size: .92rem; }
.site-footer a { color: #fff; } .site-footer h4 { margin: 0 0 8px; color: #fff; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 24px; }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; border-top: 1px solid rgba(255,255,255,.15); margin-top: 24px; padding-top: 12px; font-size: .85rem; }
.login-box summary { cursor: pointer; opacity: .6; list-style: none; } .login-box summary::-webkit-details-marker { display: none; }
.login-form { display: flex; gap: 6px; margin-top: 6px; } .login-form input { padding: 5px 8px; border: 1px solid rgba(255,255,255,.3); border-radius: 4px; background: rgba(255,255,255,.1); color: #fff; width: 120px; }
.login-form button { padding: 5px 10px; border: 0; border-radius: 4px; background: #fff; color: var(--blue-dark); cursor: pointer; }
