/* Images always stay inside their product card or gallery cell. */
.card { overflow: hidden; }
.picture { overflow: hidden; min-width: 0; }
.picture img { display: block; width: 100%; height: 100%; object-fit: contain; object-position: center; }
.gallery { min-width: 0; overflow: hidden; }
.gallery img { display: block; max-width: 100%; min-width: 0; object-fit: contain; }

/* Main navigation dropdowns for the migrated information sections. */
.navgroup { position: relative; padding: 30px 0; }
.dropdown { display: none; position: absolute; top: 65px; left: -15px; min-width: 220px; padding: 8px; border: 1px solid var(--line); background: #fff; box-shadow: 0 15px 35px #0c1b2e22; }
.dropdown a { display: block; padding: 8px 10px; white-space: nowrap; }
.dropdown a:hover { background: var(--soft); }
.navgroup:hover .dropdown, .navgroup:focus-within .dropdown { display: block; }

/* Palette taken from the current eShop-rychle theme. */
:root { --ink: #333333; --navy: #247fa4; --blue: #1790da; --gold: #40b3df; --soft: #eff9fc; --muted: #6b6b6b; --line: #d8d8d8; }
footer { border-top: 4px solid #40b3df; background: #c1eef7; color: #333; }
footer strong, footer a { color: #164f66; }
.header { gap: 20px; padding-inline: max(3vw, 20px); border-top: 4px solid #40b3df; }
.desktop-nav { gap: 18px; flex-wrap: nowrap; white-space: nowrap; }
.brand, .call { flex-shrink: 0; }
.call, .primary { color: #fff; }
.hero { background: radial-gradient(circle at 80% 10%, #c1eef744, transparent 32%), linear-gradient(125deg, #247fa4, #40b3df); }
.pagehero { background: linear-gradient(120deg, #247fa4, #40b3df); }
.pagehero p { color: #fff; }
.cta { background: #c1eef7; }
.mobile-nav { display: none; margin-left: auto; position: relative; }
.mobile-nav summary { list-style: none; cursor: pointer; padding: 10px 14px; border-radius: 4px; background: #40b3df; color: #fff; font-weight: 800; }
.mobile-nav summary::-webkit-details-marker { display: none; }
.mobile-nav-panel { position: fixed; z-index: 20; top: 112px; left: 12px; right: 12px; max-height: calc(100vh - 125px); overflow-y: auto; padding: 10px; border: 1px solid var(--line); border-radius: 5px; background: #fff; box-shadow: 0 18px 45px #1a1a1a33; }
.mobile-nav-panel strong { display: block; padding: 10px 12px 5px; color: #247fa4; font-size: 12px; text-transform: uppercase; letter-spacing: .08em; }
.mobile-nav-panel a { display: block; padding: 10px 12px; border-bottom: 1px solid var(--line); }

/* Clean presentation for articles imported from the current website. */
.contenthero { padding-top: 45px; }
.legacy-content { width: min(100% - 40px, 980px); margin: 0 auto; padding: 55px 0 90px; font-size: 17px; }
.legacy-content h2, .legacy-content h3, .legacy-content h4 { margin: 1.5em 0 .5em; line-height: 1.2; color: var(--ink); }
.legacy-content h2 { font-size: 32px; }
.legacy-content h3 { font-size: 24px; }
.legacy-content p, .legacy-content li { color: #43546a; }
.legacy-content a { color: var(--blue); text-decoration: underline; text-underline-offset: 3px; }
.legacy-content img { display: block; width: auto; height: auto; max-width: 100%; margin: 24px auto; object-fit: contain; }
.legacy-content table { display: block; width: 100%; overflow-x: auto; border-collapse: collapse; }
.legacy-content td, .legacy-content th { padding: 10px; border: 1px solid var(--line); text-align: left; }
.legacy-content blockquote { margin: 25px 0; padding: 10px 22px; border-left: 4px solid var(--gold); background: var(--soft); }
@media (max-width: 1050px) {
  .desktop-nav { display: none; }
  .mobile-nav { display: block; }
  .navgroup { padding: 0; }
  .dropdown { display: none !important; }
  .legacy-content { display: block; visibility: visible; width: min(100% - 28px, 980px); padding: 35px 0 60px; }
}
@media (max-width: 720px) {
  .header { gap: 8px; }
  .brand small { display: none; }
  .mobile-nav-panel { top: 98px; }
  .legacy-content h2 { font-size: 27px; }
  .legacy-content h3 { font-size: 21px; }
}

/* Header follows the current satelity-plzen.cz layout. */
.header { position: sticky; top: 0; z-index: 30; display: flex; justify-content: center; align-items: center; gap: 24px; width: 100%; height: 64px; padding: 0 24px; border: 0; background: #40b3df; }
.site-logo { display: block; flex: 0 0 52px; width: 52px; height: 52px; }
.site-logo img { display: block; width: 52px; height: 52px; object-fit: contain; border-radius: 11px; }
.desktop-nav { width: min(100%, 1320px); height: 64px; justify-content: space-between; align-items: center; flex-wrap: nowrap !important; gap: 15px; margin: 0; color: #333; font-size: 16px; font-weight: 650; white-space: nowrap; }
.desktop-nav > a, .desktop-nav > .navgroup { flex: 0 0 auto; white-space: nowrap; }
.navgroup { padding: 19px 0; }
.dropdown { top: 61px; }
.brandbar { display: grid; grid-template-columns: 90px minmax(0, 900px) 90px; align-items: center; justify-content: space-between; min-height: 310px; padding: 14px max(3vw, 22px); border-bottom: 1px solid var(--line); background: #40b3df; }
.brand { display: flex; align-items: center; width: 64px; height: 64px; align-self: center; }
.brand img { display: block; width: 64px; height: 64px; object-fit: contain; }
.sataimer-wide { width: 100%; padding: 18px max(2vw, 16px); border-bottom: 1px solid var(--line); background: #f5f5f5; }
.homepage-heading { padding: 24px 20px 18px; text-align: center; background: #fff; }
.homepage-heading h1 { margin: 0; color: #333; font-size: clamp(32px, 4vw, 48px); line-height: 1.15; text-transform: uppercase; }
.homepage-heading h2 { margin: 9px auto 0; color: var(--navy); font-size: clamp(21px, 2.5vw, 30px); line-height: 1.25; }
.homepage-heading p { width: min(100%, 1100px); margin: 12px auto 0; color: var(--navy); font-size: 18px; font-weight: 700; line-height: 1.55; }
.brand-sataimer { display: grid; grid-template-columns: minmax(240px, 300px) 88px 184px minmax(360px, 1fr); gap: 20px; align-items: center; width: min(100%, 1500px); margin: 0 auto; padding: 8px 12px; color: #222; }
.sataimer-title { font-size: 17px; line-height: 1.3; text-align: center; }
.media-card { display: flex; min-height: 118px; flex-direction: column; align-items: center; justify-content: flex-start; gap: 7px; }
.sataimer-appicon img { display: block; width: 82px; height: 82px; border-radius: 17px; box-shadow: 0 2px 6px #00000038; }
.sataimer-appicon span { display: grid; place-items: center; width: 82px; height: 29px; color: #222; font-size: 13px; font-weight: 800; }
.sataimer-qrs { display: flex; gap: 10px; }
.sataimer-qrs a { display: flex; flex-direction: column; align-items: center; gap: 7px; }
.sataimer-qrs .qr { display: block; width: 82px; height: 82px; padding: 3px; border-radius: 7px; background: #fff; box-shadow: 0 2px 6px #00000028; }
.sataimer-qrs .store-badge { display: block; width: 82px; height: 29px; object-fit: contain; }
.sataimer-fulltext { min-width: 0; font-size: 14px; line-height: 1.45; }
.sataimer-fulltext strong, .sataimer-fulltext b { color: #b27d00; }
@media (max-width: 1400px) {
  .header { justify-content: flex-end; height: 64px; }
  .site-logo { margin-right: auto; }
  .desktop-nav { display: none; }
  .mobile-nav { display: block; }
  .mobile-nav-panel { top: 104px; }
}
@media (max-width: 600px) {
  .header { height: 54px; padding: 0 12px; }
  .site-logo, .site-logo img { width: 44px; height: 44px; flex-basis: 44px; }
  .mobile-nav-panel { top: 94px; }
}
@media (max-width: 900px) {
  .brand-sataimer { grid-template-columns: 90px minmax(0, 1fr); grid-template-areas: "title title" "icon qrs" "text text"; gap: 12px; }
  .sataimer-title { grid-area: title; }
  .sataimer-appicon { grid-area: icon; }
  .sataimer-qrs { grid-area: qrs; justify-content: flex-start; }
  .sataimer-fulltext { grid-area: text; font-size: 13px; text-align: center; }
}

/* SatAimer promotion retained as the first homepage section. */
.sataimer-intro { display: grid; grid-template-columns: 110px minmax(0, 720px) 190px; gap: 22px; align-items: center; width: min(100% - 32px, 1080px); margin: 24px auto 8px; padding: 18px 22px; border: 1px solid #ddd; border-radius: 12px; background: #f5f5f5; box-shadow: 0 2px 8px #0000001f; }
.sataimer-icon { display: block; width: 92px; height: 92px; border-radius: 19px; box-shadow: 0 2px 6px #00000038; }
.sataimer-copy h2 { margin: 0 0 7px; font-size: 19px; line-height: 1.25; }
.sataimer-copy p { margin: 0; color: #444; font-size: 14px; line-height: 1.45; }
.sataimer-copy strong { color: #c28a00; }
.store-links { display: flex; gap: 10px; margin-top: 11px; }
.store-links img { display: block; width: auto; height: 40px; }
.sataimer-qr { display: flex; gap: 10px; justify-content: flex-end; }
.sataimer-qr img { display: block; width: 82px; height: 82px; padding: 3px; border-radius: 7px; background: #fff; }
@media (max-width: 850px) {
  .sataimer-intro { grid-template-columns: 90px 1fr; }
  .sataimer-icon { width: 78px; height: 78px; }
  .sataimer-qr { display: none; }
}
@media (max-width: 560px) {
  .sataimer-intro { grid-template-columns: 1fr; text-align: center; }
  .sataimer-visual { display: flex; justify-content: center; }
  .store-links { justify-content: center; flex-wrap: wrap; }
}

/* Homepage mirrors the original service-tile composition. */
.home-layout { display: grid; grid-template-columns: minmax(270px, 310px) minmax(390px, 520px) minmax(330px, 430px); gap: 18px 24px; align-items: start; justify-content: center; padding: 28px max(2vw, 22px) 70px; }
.home-layout .categorytree { grid-column: 1; grid-row: 1 / span 2; position: static; top: auto; max-height: none; }
.sidebar-search { display: grid; grid-template-columns: minmax(0, 1fr) auto; margin: 0; border-bottom: 1px solid var(--line); }
.sidebar-search input { min-width: 0; height: 46px; padding: 0 11px; border: 0; font: inherit; }
.sidebar-search button { padding: 0 14px; border: 0; background: #eefa03; color: #222; font-weight: 800; cursor: pointer; }
.home-main { grid-column: 2; grid-row: 1; min-width: 0; padding: 0 5px; text-align: center; }
.home-main h1 { margin: 0 0 12px; color: #333; font-size: clamp(30px, 3vw, 42px); line-height: 1.2; }
.home-lead { margin: 0 0 18px; color: #e02020; font-size: 20px; font-weight: 800; }
.service-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-rows: 145px; gap: 16px; }
.service-tiles a { display: flex; height: 145px; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: 15px; border-radius: 17px; background: #40b3df; color: #fff; font-size: 18px; font-weight: 800; text-align: center; transition: transform .15s, background .15s; }
.tile-icon { display: grid; place-items: center; width: 58px; height: 58px; border-radius: 50%; background: #ffffff2b; font-size: 34px; line-height: 1; }
.cctv-icon { width: 45px; height: 45px; }
.cctv-icon .camera-body { fill: #fff; }
.cctv-icon .camera-lens { fill: #247fa4; stroke: #fff; stroke-width: 3; }
.cctv-icon .camera-arm { fill: none; stroke: #fff; stroke-width: 5; stroke-linecap: round; stroke-linejoin: round; }
.service-tiles a:hover { transform: translateY(-3px); background: #2aaadb; }
.column-map { display: block; width: 100%; min-height: 300px; margin-top: 18px; border: 0; }
.home-layout > .sataimer-wide { grid-column: 2 / 4; grid-row: 2; height: auto; padding: 18px; border: 1px solid var(--line); border-radius: 12px; }
.home-layout .brand-sataimer { grid-template-columns: minmax(220px, 280px) 88px 184px minmax(300px, 1fr); gap: 18px; height: auto; padding: 0; }
.home-layout .sataimer-title, .home-layout .sataimer-fulltext { grid-column: auto; }
.home-layout .sataimer-qrs { display: flex; }
.home-layout .sataimer-fulltext { text-align: left; }
@media (max-width: 1200px) {
  .home-layout { grid-template-columns: minmax(270px, 310px) minmax(0, 620px); }
  .home-layout .categorytree { grid-row: 1 / span 3; }
  .contact-home { grid-column: 2; grid-row: 2; }
  .home-layout > .sataimer-wide { grid-column: 2; grid-row: 3; height: auto; min-height: 520px; }
}
@media (max-width: 800px) {
  .home-layout { grid-template-columns: 1fr; padding-inline: 18px; }
  .home-main { grid-row: 1; padding: 0; }
  .contact-home { grid-column: 1; grid-row: 2; width: min(100%, 620px); margin: 0 auto; }
  .home-layout > .sataimer-wide { grid-column: 1; grid-row: 3; width: min(100%, 620px); min-height: 0; margin: 0 auto; }
  .home-layout .categorytree { grid-column: 1; grid-row: 4; width: min(100%, 560px); margin: 0 auto; }
}
@media (max-width: 620px) {
  .home-lead { font-size: 17px; }
  .service-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .service-tiles a { width: 100%; border-radius: 13px; font-size: 16px; }
}

/* Contact table and both maps retained from the original homepage. */
.contact-home { grid-column: 3; grid-row: 1; min-width: 0; padding: 0; }
.contact-table { width: 100%; height: 467px; border-collapse: collapse; border: 1px solid #40b3df; font-size: 17px; text-align: center; }
.contact-table th, .contact-table td { padding: 11px 14px; border: 1px solid #40b3df; }
.contact-table th { background: #40b3df; color: #fff; font-size: 18px; }
.contact-table th a { color: #fff; }
.contact-warning { color: #e02020; font-weight: 800; }
.contact-maps { display: grid; grid-template-columns: 1fr; gap: 12px; margin-top: 14px; }
.contact-maps iframe { width: 100%; min-height: 300px; border: 0; }
@media (max-width: 650px) {
  .contact-maps { grid-template-columns: 1fr; }
  .contact-maps iframe { min-height: 330px; }
}

/* Historical information URLs remain useful as visible article hubs. */
.article-index { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; padding: 42px max(5vw, 24px) 75px; }
.article-card { display: flex; min-height: 190px; flex-direction: column; padding: 24px; border: 1px solid var(--line); border-top: 4px solid #40b3df; background: #fff; }
.article-card h2 { margin: 0 0 10px; font-size: 21px; line-height: 1.25; }
.article-card p { margin: 0; color: var(--muted); }
.article-card span { margin-top: auto; padding-top: 18px; color: var(--blue); font-weight: 800; }
.about-index { width: min(100% - 40px, 900px); margin: 0 auto; padding: 48px 0 80px; font-size: 18px; text-align: center; }
.about-links { display: grid; grid-template-columns: repeat(3, 1fr); gap: 15px; margin-top: 30px; }
.about-links a { padding: 20px; border-radius: 8px; background: #40b3df; color: #fff; font-weight: 800; }
@media (max-width: 850px) {
  .article-index { grid-template-columns: 1fr; }
  .about-links { grid-template-columns: 1fr; }
}

/* Final mobile override: never allow desktop grid placement to create hidden columns. */
@media (max-width: 800px) {
  html, body { width: 100%; max-width: 100%; overflow-x: hidden; }
  .home-layout { display: flex; width: 100%; flex-direction: column; gap: 22px; padding: 22px 14px 55px; }
  .home-main, .contact-home { display: contents; }
  .service-tiles, .contact-table, .column-map, .home-layout > .sataimer-wide, .home-layout .categorytree { width: 100%; max-width: 620px; margin-right: auto; margin-left: auto; }
  .service-tiles { order: 1; }
  .contact-table { order: 2; }
  .home-main > .column-map { order: 3; }
  .contact-home > .column-map { order: 4; }
  .home-layout > .sataimer-wide { order: 5; grid-column: auto; grid-row: auto; min-height: 0; padding: 14px 10px; }
  .home-layout .categorytree { order: 6; grid-column: auto; grid-row: auto; }
  .contact-table { width: 100%; height: auto; table-layout: fixed; }
  .contact-table th, .contact-table td { overflow-wrap: anywhere; }
  .column-map { width: 100%; min-height: 320px; }
  .home-layout .brand-sataimer { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px 6px; width: 100%; }
  .home-layout .sataimer-title { grid-column: 1 / -1; text-align: center; }
  .home-layout .sataimer-appicon { grid-column: auto; min-width: 0; }
  .home-layout .sataimer-qrs { display: contents; }
  .home-layout .sataimer-fulltext { grid-column: 1 / -1; width: 100%; text-align: left; }
  .home-layout .media-card { min-width: 0; width: 100%; }
  .home-layout .sataimer-appicon img, .home-layout .sataimer-qrs .qr { width: min(82px, 100%); height: auto; aspect-ratio: 1; }
  .home-layout .sataimer-appicon span, .home-layout .sataimer-qrs .store-badge { width: min(82px, 100%); }
}
